createweapon
The createweapon command is used to spawn a normal that can be picked up.



"then(createweapon, x position, y position)"


Argument Function
x position The x position, relative to the object, where the weapon will be created.
y position The y position, relative to the object, where the weapon will be created.



And example of the createweapon command used in a script is as follows...




The following script has a 1 in 5 chance to spawn a weapon on a block when it is created.


if(create)
if(compare,rand(1,5),=,1)
{
then(createweapon,16,16)
}