Fires projectiles at creeper, bots and digitalis in range. Used by several player units.
Arguments
turbo (bool)
If true, weapon's fire rate is increased tremendously
fire_range (int)
Maximum distance in map pixels at which weapon will aim and fire at targets
manual_mode (bool)
If true, cannon aims toward cursor and fires when left mouse button is clicked; if false, cannon aims and fires automatically
fire_offset (Vector2)
rotate_speed (float)
Maximum turn rate of cannon in degrees per frame (in manual mode cannon rotates instantly to face cursor regardless of rotate_speed)
fire_cost (float)
Ammo consumed from parent unit per shot fired
fire_delay (int)
Time between shots in game frames
shot_speed (int)
Movement speed of fired shots in map pixels per frame
max_age (int)
Time in game frames from firing until projectile despawns (a value of 0 gives projectiles unlimited lifetime)
shot_damage_count (int)
Maximum number of creeper pixels damaged per shot
shot_damage_distance (int)
Maximum damage radius of shots in map pixels
shot_damage (int)
Damage to each pixel of creeper (negative values damage creeper, positive values damage anticreeper; however, there is no way to target anticreeper)per shot, in millionths (i.e. -1000000 reduces creeper depth by 1.0 in each affected pixel)
shot_digitalis_damage (int)
Damage to each pixel of living digitalis per shot (damage is always inflicted in a 5×5 pixel square centered on the point of impact, regardless of shot_damage_count or shot_damage_distance)
hit_colliders (int)
hit_collider_damage (float)
ixe/controller/cannon.txt · Last modified: 2025/02/14 14:57 by 127.0.0.1