Results 1 to 12 of 12

Thread: Anybody know a script to fix crossbows in sieges?

  1. #1

    Default Anybody know a script to fix crossbows in sieges?

    Specifically to make their trajectories the same as Archers so they are always able to fire in siege offense and defense if in range.

    Thanks in advance for any suggestions.

  2. #2
    Nemesis2345's Avatar Semisalis
    Join Date
    May 2013
    Location
    Constanta, Romania
    Posts
    462

    Default Re: Anybody know a script to fix crossbows in sieges?

    There have been many tries, all failing. They simply cant shoot because of the wall ramparts blocking their vision or because there are other allied troops in front of them. Crossbows are really bad because they dont have the flexibilty of the bow. If you want my advice, u can place them on the walls with guard mode on, and when an enemy scales the walls, have some troops keeping them busy while u shoot them from behind with crossbows, it is really easy to destroy enemies with this. On the other note, there was a guy saying that he could remove the arrow wall collision, so they would shoot straight, but the projectiles will simply bug out because they will basically pass through walls. Sorry.

  3. #3

    Default Re: Anybody know a script to fix crossbows in sieges?

    There is a way, although you'll need to do a lot of experimenting to get it right, and it will still have unintended consequences. The two files you need are EDU (for reference) and descr_projectile.txt in mod's data directory.

    Let me explain. The reason why crossbowmen do not fire is because they have no clear line of fire (not sight). Their projectile speed and allowed angles of fire mean that most of the crossbowmen do not have line of fire unobstructed by rampart. So you need to manipulate these values.
    First, look in EDU to see which projectiles do the desired units use. You can see it in edu in their primary weapon section, looking like this (bolded part):
    stat_pri 10, 2, steel_crossbow_bolt3, 160, 20, missile, melee_blade, piercing, none, 0, 1
    Now, open descr_projectile.txt. Look up the desired projectile. The two lines important for us are:
    max_angle
    velocity

    Now, it's just manipulating the values to your desire. Increasing the angle allows the crossbowmen to shoot using high trajectory, so they can cover the blind zones through this. However, such shooting is far less effective as bolts come down at steep angle and much wider dispersion, due to longer trajectory. Decreasing the velocity means the bolts will travel slower, thus having more pronounced arcing over same distance...essentially bringing the trajectory closer to bow. Some experimenting should yield the result you desire.
    However, there are significant consequences. First is the possibility of crash. The velocity directly translates into maximum range. If a unit has longer range specified in EDU than is maximum range of its projectile, game will crash at startup.
    Second, all units using that projectile will be affected.
    Third, this will affect their behavior in general, not just on the walls. They'll be able to arc the bolts better over the friendlies as you decrease velocity, but their accuracy will suffer from increasing the impact angle and wider dispersion from longer trajectory.

  4. #4

    Default Re: Anybody know a script to fix crossbows in sieges?

    It is actually a very easy fix, you only need to edit the velocity value.


    Go to descr_projectile.txt and just edit the velocity value for every bolt projectile type.

    For example,

    projectile steel_crossbow_bolt

    damage 0
    radius 0.075
    mass 0.14
    accuracy_vs_units 0.065
    min_angle -80
    max_angle 70
    velocity 21 55 => this value right here
    display aimed
    effect_only


    Change it to;

    velocity 20 80


    Do this for all bolt types in the file.

    Issue solved;

    http://i.imgur.com/TmpOA6y.jpg

  5. #5
    Roma_Victrix's Avatar Call me Ishmael
    Join Date
    Sep 2010
    Location
    Virginia, USA
    Posts
    15,248

    Default Re: Anybody know a script to fix crossbows in sieges?

    Quote Originally Posted by Mamlaz View Post
    It is actually a very easy fix, you only need to edit the velocity value.


    Go to descr_projectile.txt and just edit the velocity value for every bolt projectile type.

    For example,

    projectile steel_crossbow_bolt

    damage 0
    radius 0.075
    mass 0.14
    accuracy_vs_units 0.065
    min_angle -80
    max_angle 70
    velocity 21 55 => this value right here
    display aimed
    effect_only


    Change it to;

    velocity 20 80


    Do this for all bolt types in the file.

    Issue solved;

    http://i.imgur.com/TmpOA6y.jpg
    Thanks for the insights! I can't believe after all these years there are still things worth learning about in regards to this mod. Fantastic.

  6. #6

    Default Re: Anybody know a script to fix crossbows in sieges?

    Yeah, there are loads of simple line edits that can still tweak the game bit by bit.

    For instance, one dude actually replaced the op cannon towers with musket towers, with sound and everything, it was pretty neat.

    Shame I can't find the post anymore, it was a long time ago, not sure if it was even on this forum.

  7. #7

    Default Re: Anybody know a script to fix crossbows in sieges?

    Mamlaz, you're the man! You can't imagine my unbridled joy now that I can finally use crossbowmen on the walls after all these years.

    Much thanks!

  8. #8

    Default Re: Anybody know a script to fix crossbows in sieges?

    Hm... I wanted to know before changing those values: Does this change have any effect to the crossbowmen performance in other battles, such as open field? And how?

    Thanks!

  9. #9

    Default Re: Anybody know a script to fix crossbows in sieges?

    I second this question.

  10. #10

    Default Re: Anybody know a script to fix crossbows in sieges?

    Pretty much what I wrote in my first post. Lower velocity means that that the bolt will have to travel slightly longer distance and will descend in steeper angle, reducing the hit rate somewhat, but the effect will not be really significant, unless you put velocity on absurdly low value. It will also allow them to shoot over larger obstacles.

  11. #11

    Default Re: Anybody know a script to fix crossbows in sieges?

    I only use x-bows as a first volley against charging infantry/cavalry then retreat them behind my own infantry defenders.
    After that, I just have them target enemies that aren't actively engaged with my troops.

    Their angle of fire hits their own men otherwise. Same deal with later age gunpowder units.
    Bowmen can arch their fire better, even if they do a little less damage.
    Honest and truly, I AM Robin Hood!

  12. #12

    Default Re: Anybody know a script to fix crossbows in sieges?

    Mamlaz, you're a genius thanks! Been looking for a solution for this for a long time. This arrow animation looks like a bows trajectory but it does allow crossbows to be fired from and at walls.

    Finally no more useless crossbowmen! I shall boot up a Venice campaign now.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •