Pum/Functions/pumPowerup Create

From Multi Theft Auto: Wiki
Revision as of 20:57, 23 January 2012 by Winky- (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
Dialog-information.png This article is (partially) outdated and the information may no longer apply.

This function creates and spawns a new powerup.

If the powerup is created, it triggers the public event, pumEvent_PowerupCreated on both the client and server.

Syntax

Click to collapse [-]
Server
mixed pumPowerup Create( int object_id, string powerup_class, float x, float y, float z, int respawnTime, int animation_mode, [mixed extra_data] )

Required Arguments

  • object_id, : The name of the powerup class to destroy
  • powerup_class: The internal name for the newly created powerup
  • x: The X position of the powerup
  • y: The Y position of the powerup
  • z: The Z position of the powerup
  • respawnTime: Time in ms to respawn (when making use of this feature)
  • animation_mode: 0 = Static, 1 = Spinning

Optional Arguments

  • extra_data: Optional data to link to this this powerup

Example

Click to collapse [-]
Server

-todo description-

- todo example -

See Also

PowerupManager functions

Powerup functions

PowerupHelper functions