LuaAPI.wiki
changeset 408 e9b65daecbcf
parent 407 36537eaf680c
child 410 c0367902bea7
equal deleted inserted replaced
407:36537eaf680c 408:e9b65daecbcf
   635 
   635 
   636 <code lang="lua">
   636 <code lang="lua">
   637   AddAmmo(CurrentHedgehog, amBazooka, 1) -- give the CurrentHedgehog a bazooka
   637   AddAmmo(CurrentHedgehog, amBazooka, 1) -- give the CurrentHedgehog a bazooka
   638   SetWeapon(amBazooka) -- select the Bazooka.</code>
   638   SetWeapon(amBazooka) -- select the Bazooka.</code>
   639 </blockquote>
   639 </blockquote>
       
   640 
       
   641 ==== <tt>!SetNextWeapon()</tt> (0.9.21) ====
       
   642 This function makes the current hedgehog switch to the next weapon in list of available weapons. It can be used for example in trainings to pre-select a weapon.
       
   643 
       
   644 
   640 === <tt>!SetHogHat(gearUid, hat)</tt> ===
   645 === <tt>!SetHogHat(gearUid, hat)</tt> ===
   641 
   646 
   642 <blockquote>Sets the hat of the specified hedgehog gear
   647 <blockquote>Sets the hat of the specified hedgehog gear
   643 </blockquote>
   648 </blockquote>
   644 === <tt>!SetGearTarget(gearUid, x, y) (0.9.16)</tt> ===
   649 === <tt>!SetGearTarget(gearUid, x, y) (0.9.16)</tt> ===
   755 
   760 
   756 ==== <tt>!GetCurAmmoType()</tt> (0.9.16) ====
   761 ==== <tt>!GetCurAmmoType()</tt> (0.9.16) ====
   757 
   762 
   758 <blockquote>Returns the currently selected [AmmoTypes Ammo Type].
   763 <blockquote>Returns the currently selected [AmmoTypes Ammo Type].
   759 </blockquote>
   764 </blockquote>
   760 
       
   761 ==== <tt>SetWeapon(ammoType)</tt> (0.9.21) ====
       
   762 This function sets the weapon of the current hedgehog to the specified [AmmoTypes Ammo Type].
       
   763 
       
   764 ==== <tt>SetNextWeapon()</tt> (0.9.21) ====
       
   765 This function makes the current hedgehog switch to the next weapon in the weapon list. It can be used for example in trainings to pre-select a weapon.
       
   766 
   765 
   767 ==== <tt>!SwitchHog(gearUid)</tt> (0.9.16) ====
   766 ==== <tt>!SwitchHog(gearUid)</tt> (0.9.16) ====
   768 
   767 
   769 <blockquote>This function will switch to the hedgehog with the specified Uid.</blockquote>
   768 <blockquote>This function will switch to the hedgehog with the specified Uid.</blockquote>
   770 
   769