Minimum distance possible for artillery pieces?
Moderator: Moderators
Re: Minimum distance possible for artillery pieces?
Well perhaps - but there was no tag to control it. 
- Evil4Zerggin
- Posts: 557
- Joined: 16 May 2007, 06:34
Re: Minimum distance possible for artillery pieces?
I thought AimWeaponX was called every slow update regardless of reload time?yuritch wrote:If you want to check for minimum range, do it in the AimWeaponX script for the arty weapon, use get TARGET_ID to find out which unit it targets, and then use get UNIT_XZ on that unit and the firing unit to calculate the distance. That's probably best kept on long-reload weapons only as all those calls can in theory slow the game down if used on a fast reload spammable units.
Re: Minimum distance possible for artillery pieces?
I'm not really sure, such tricks usually work for my arty units (not for min range checking though), but those have long reload times. Haven't tried with fast-reload weapons.
