Shoot: Difference between revisions

From EDukeWiki
Jump to navigation Jump to search
No edit summary
Jblade (talk | contribs)
mNo edit summary
 
(4 intermediate revisions by 2 users not shown)
Line 1: Line 1:
shoot <tilenum>
'''shoot''' <[[tile number]]><br>
'''shootvar''' <[[tile number]]><br>
'''eshoot''' <[[tile number]]><br>
'''eshootvar''' <[[tile number]]><br>
'''zshoot''' <[[zvel]]> <[[tile number]]><br>
'''zshootvar''' <[[zvel]]> <[[tile number]]><br>
'''ezshoot''' <[[zvel]]> <[[tile number]]><br>
'''ezshootvar''' <[[zvel]]> <[[tile number]]>


Causes the current [[actor]] to fire the projectile <tilenum>.
Causes the current [[actor]] to fire the projectile <[[tile number]]>.
 
Commands with an "e" prefix set the [[gamevar]] [[RETURN]] to the spawned projectile's [[sprite id]].
 
Commands with a "z" prefix shoot the projectile with a z-velocity of <[[zvel]]>.  Values for <[[zvel]]> can be calculated using the [[ldist]] command.  These functions are useful for causing an [[actor]] to aim vertically at objects other than the player.  They are also important to control the vertical aim of hitscan projectiles.  In hitscan projectiles, the value works similar to sloped [[sector]]s (4096 [[build units]] = 45�).
 
{{varsuffix}}


[[Category:Duke3D 1.3/1.5 commands]]
[[Category:Duke3D 1.3/1.5 commands]]
[[Category:Projectile manipulation]]
[[Category:Projectile manipulation]]

Latest revision as of 23:36, 7 August 2019

shoot <tile number>
shootvar <tile number>
eshoot <tile number>
eshootvar <tile number>
zshoot <zvel> <tile number>
zshootvar <zvel> <tile number>
ezshoot <zvel> <tile number>
ezshootvar <zvel> <tile number>

Causes the current actor to fire the projectile <tile number>.

Commands with an "e" prefix set the gamevar RETURN to the spawned projectile's sprite id.

Commands with a "z" prefix shoot the projectile with a z-velocity of <zvel>. Values for <zvel> can be calculated using the ldist command. These functions are useful for causing an actor to aim vertically at objects other than the player. They are also important to control the vertical aim of hitscan projectiles. In hitscan projectiles, the value works similar to sloped sectors (4096 build units = 45�).

Commands with an additional "var" suffix take gamevars rather than constants or defined labels for their inputs. As an alternate short form, "varvar" can be dropped from these commands; for example ife serves an an alias for ifvarvare.