Gotweapon: Difference between revisions

From EDukeWiki
Jump to navigation Jump to search
Example
No edit summary
Line 1: Line 1:
This is an array of values which specify whether the [[player]] has a certain weapon.
This is an array of values which specify whether the [[player]] has a certain weapon.
This is deprecated when it comes to HANDBOMB_WEAPON or TRIPBOMB_WEAPON.


  onevent EVENT_RESETWEAPONS
  onevent EVENT_RESETWEAPONS
Line 9: Line 11:
             ifvare LEVEL 0 // remove the player's pistol if they spawned in single player on E1L1
             ifvare LEVEL 0 // remove the player's pistol if they spawned in single player on E1L1
             {
             {
                 setplayer[THISACTOR].'''gotweapon''' ONE ZERO
                 setplayer[THISACTOR].'''gotweapon''' PISTOL_WEAPON ZERO
                 setplayer[THISACTOR].ammo_amount ONE ZERO
                 setplayer[THISACTOR].ammo_amount PISTOL_WEAPON ZERO
             }
             }
         }
         }

Revision as of 00:47, 9 September 2009

This is an array of values which specify whether the player has a certain weapon.

This is deprecated when it comes to HANDBOMB_WEAPON or TRIPBOMB_WEAPON.

onevent EVENT_RESETWEAPONS
{
    ifvare MULTIMODE 1
    {
        ifvare VOLUME 0
        {
            ifvare LEVEL 0 // remove the player's pistol if they spawned in single player on E1L1
            {
                setplayer[THISACTOR].gotweapon PISTOL_WEAPON ZERO
                setplayer[THISACTOR].ammo_amount PISTOL_WEAPON ZERO
            }
        }
    }
}
endevent