C# Class GameEntities.Gun

Inheritance: Weapon
Datei anzeigen Open project: DarrenHassan/GDM4242-GroupD Class Usage Examples

Private Properties

Property Type Description
Client_ReceiveCreateBulletEvent void
Client_ReceiveFireEvent void
Client_ReceiveNoAmmoEvent void
Client_ReceiveReloadEvent void
Client_ReceiveUpdateBulletCount void
OnFire void
OnReload void
Server_SendCreateBulletEventToAllClients void
Server_SendFireEventToAllClients void
Server_SendNoAmmoEventToAllClients void
Server_SendReloadEventToAllClients void
Server_SendUpdateBulletCountToClients void

Public Methods

Method Description
AddBullets ( BulletType bulletType, int count ) : void
GetAdvanceAttackTargetPosition ( bool alternative, MapObject obj, bool useGravity, Vec3 &pos ) : bool
GetFirePosition ( bool alternative ) : Vec3
GetFireRotation ( bool alternative ) : Quat
TryFire ( bool alternative ) : bool
TryReload ( ) : void

Protected Methods

Method Description
CreateBullet ( Mode mode ) : void
Fire ( Mode mode ) : void
OnLoad ( TextBlock block ) : bool
OnPostCreate ( bool loaded ) : void

Overridden from Engine.EntitySystem.Entity.OnPostCreate(Boolean).

OnPreCreate ( ) : void
OnSave ( TextBlock block ) : void
OnTick ( ) : void

Overridden from Engine.EntitySystem.Entity.OnTick().

Server_OnClientConnectedBeforePostCreate ( RemoteEntityWorld remoteEntityWorld ) : void

Private Methods

Method Description
Client_ReceiveCreateBulletEvent ( RemoteEntityWorld sender, ReceiveDataReader reader ) : void
Client_ReceiveFireEvent ( RemoteEntityWorld sender, ReceiveDataReader reader ) : void
Client_ReceiveNoAmmoEvent ( RemoteEntityWorld sender, ReceiveDataReader reader ) : void
Client_ReceiveReloadEvent ( RemoteEntityWorld sender, ReceiveDataReader reader ) : void
Client_ReceiveUpdateBulletCount ( RemoteEntityWorld sender, ReceiveDataReader reader ) : void
OnFire ( GunType typeMode ) : void
OnReload ( ) : void
Server_SendCreateBulletEventToAllClients ( Mode mode ) : void
Server_SendFireEventToAllClients ( bool alternative ) : void
Server_SendNoAmmoEventToAllClients ( ) : void
Server_SendReloadEventToAllClients ( ) : void
Server_SendUpdateBulletCountToClients ( IList remoteEntityWorlds ) : void

Method Details

AddBullets() public method

public AddBullets ( BulletType bulletType, int count ) : void
bulletType BulletType
count int
return void

CreateBullet() protected method

protected CreateBullet ( Mode mode ) : void
mode Mode
return void

Fire() protected method

protected Fire ( Mode mode ) : void
mode Mode
return void

GetAdvanceAttackTargetPosition() public method

public GetAdvanceAttackTargetPosition ( bool alternative, MapObject obj, bool useGravity, Vec3 &pos ) : bool
alternative bool
obj MapObject
useGravity bool
pos Vec3
return bool

GetFirePosition() public method

public GetFirePosition ( bool alternative ) : Vec3
alternative bool
return Vec3

GetFireRotation() public method

public GetFireRotation ( bool alternative ) : Quat
alternative bool
return Quat

OnLoad() protected method

protected OnLoad ( TextBlock block ) : bool
block TextBlock
return bool

OnPostCreate() protected method

Overridden from Engine.EntitySystem.Entity.OnPostCreate(Boolean).
protected OnPostCreate ( bool loaded ) : void
loaded bool
return void

OnPreCreate() protected method

protected OnPreCreate ( ) : void
return void

OnSave() protected method

protected OnSave ( TextBlock block ) : void
block TextBlock
return void

OnTick() protected method

Overridden from Engine.EntitySystem.Entity.OnTick().
protected OnTick ( ) : void
return void

Server_OnClientConnectedBeforePostCreate() protected method

protected Server_OnClientConnectedBeforePostCreate ( RemoteEntityWorld remoteEntityWorld ) : void
remoteEntityWorld RemoteEntityWorld
return void

TryFire() public method

public TryFire ( bool alternative ) : bool
alternative bool
return bool

TryReload() public method

public TryReload ( ) : void
return void