C# Class PlayerDrop, PaperCowboys

This is a dropped object in the scene that appears at random after an enemy dies. This can be a hat, bandanna, ammo or a weapon. Drops are NOT synchronized objects. They exist solely on the player's instance they were instantiated in, and no other player will see it. Objects with the PlayerDrop component are created by GameDirector.RPCGiveDrop which is invoked by the master client.
Inheritance: MonoBehaviour
Afficher le fichier Open project: Gamieon/PaperCowboys Class Usage Examples

Méthodes publiques

Свойство Type Description
iconRenderer Renderer
iconTransform Transform
itemDrop ItemDrop,
playerCharacter PlayerCharacter,
sndDropPickup UnityEngine.AudioClip

Méthodes publiques

Méthode Description
FixedUpdate ( ) : void
GiveAmmoDropToPlayer ( ) : void

Called by GiveDropToPlayer to give ammo to the player

GiveCowboyHatToPlayer ( ) : void

Called by GiveDropToPlayer to give a hat to the player

GiveDropToPlayer ( ) : void

Called when the player runs into the drop

GiveMouthpieceToPlayer ( ) : void

Called by GiveDropToPlayer to give a mouthpiece (bandana) to the player

GiveWeaponDropToPlayer ( WeaponDirector, weapon, int defaultAmmo ) : void

Called by GiveDropToPlayer to give a weapon to the player

SelfDestruct ( ) : void

Called when the drop has been on the ground so long that it must be removed automatically. We can't just leave these in the scene forever.

Start ( ) : void

Method Details

FixedUpdate() public méthode

public FixedUpdate ( ) : void
Résultat void

GiveAmmoDropToPlayer() public méthode

Called by GiveDropToPlayer to give ammo to the player
public GiveAmmoDropToPlayer ( ) : void
Résultat void

GiveCowboyHatToPlayer() public méthode

Called by GiveDropToPlayer to give a hat to the player
public GiveCowboyHatToPlayer ( ) : void
Résultat void

GiveDropToPlayer() public méthode

Called when the player runs into the drop
public GiveDropToPlayer ( ) : void
Résultat void

GiveMouthpieceToPlayer() public méthode

Called by GiveDropToPlayer to give a mouthpiece (bandana) to the player
public GiveMouthpieceToPlayer ( ) : void
Résultat void

GiveWeaponDropToPlayer() public méthode

Called by GiveDropToPlayer to give a weapon to the player
public GiveWeaponDropToPlayer ( WeaponDirector, weapon, int defaultAmmo ) : void
weapon WeaponDirector, /// Weapon. ///
defaultAmmo int /// Default ammo. ///
Résultat void

SelfDestruct() public méthode

Called when the drop has been on the ground so long that it must be removed automatically. We can't just leave these in the scene forever.
public SelfDestruct ( ) : void
Résultat void

Start() public méthode

public Start ( ) : void
Résultat void

Property Details

iconRenderer public_oe property

The icon renderer.
public Renderer iconRenderer
Résultat Renderer

iconTransform public_oe property

The icon transform.
public Transform iconTransform
Résultat Transform

itemDrop public_oe property

The item that is being offered to the player.
public ItemDrop, itemDrop
Résultat ItemDrop,

playerCharacter public_oe property

The player character receiving the drop
public PlayerCharacter, playerCharacter
Résultat PlayerCharacter,

sndDropPickup public_oe property

The sound of the drop pickup.
public AudioClip,UnityEngine sndDropPickup
Résultat UnityEngine.AudioClip