LuaAPI: Move SetWeapon and SetNextWeapon
authorWuzzy
Sat, 24 Feb 2018 11:30:33 +0000
changeset 1245 355898ec2631
parent 1244 fb89844d7b78
child 1246 0f08b9671715
LuaAPI: Move SetWeapon and SetNextWeapon
LuaAPI.wiki
--- a/LuaAPI.wiki	Sat Feb 24 11:27:37 2018 +0000
+++ b/LuaAPI.wiki	Sat Feb 24 11:30:33 2018 +0000
@@ -882,20 +882,6 @@
 === <tt>!SetHogTeamName(gearUid, name)</tt> ===
 Sets the team name of the specified gear. The gear can be a hedgehog or grave.
 
-=== <tt>!SetWeapon(ammoType)</tt> ===
-Sets the selected weapon of `CurrentHedgehog` to one of the [AmmoTypes Ammo Type].
-
-Example:
-
-<code language="lua">
-  AddAmmo(CurrentHedgehog, amBazooka, 1) -- give the CurrentHedgehog a bazooka
-  SetWeapon(amBazooka) -- select the Bazooka.</code>
-
-
-=== <tt>!SetNextWeapon()</tt> ===
-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.
-
-
 === <tt>!SetHogHat(gearUid, hat)</tt> ===
 Sets the hat of the specified hedgehog gear.
 
@@ -1158,6 +1144,18 @@
 ==== <tt>!SwitchHog(gearUid)</tt> ====
 This function will switch to the hedgehog with the specifiedd `gearUid`.
 
+=== <tt>!SetWeapon(ammoType)</tt> ===
+Sets the selected weapon of `CurrentHedgehog` to one of the [AmmoTypes Ammo Type].
+
+Example:
+
+<code language="lua">
+  AddAmmo(CurrentHedgehog, amBazooka, 1) -- give the CurrentHedgehog a bazooka
+  SetWeapon(amBazooka) -- select the Bazooka.</code>
+
+=== <tt>!SetNextWeapon()</tt> ===
+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.
+
 ==== <tt>!SetInputMask(mask)</tt> ====
 Masks specified player input. This means that Hedgewars ignores certain player inputs, such as walking or jumping.