2017-09-27 19:26:32 -07:00
|
|
|
// Copyright © 2017 Project Golan, all rights reserved.
|
2017-10-04 17:14:46 -07:00
|
|
|
// See COPYING for more information.
|
2017-09-27 19:26:32 -07:00
|
|
|
#ifndef g_player_h
|
|
|
|
#define g_player_h
|
|
|
|
|
|
|
|
#include "g_object.h"
|
|
|
|
|
2017-09-29 04:50:36 -07:00
|
|
|
#define G_Player_max 2
|
2017-09-27 19:26:32 -07:00
|
|
|
#define G_Player_propMem(t, name) G_Entity_propMem(G_Player_##name, t, name)
|
|
|
|
|
|
|
|
// Types ---------------------------------------------------------------------|
|
|
|
|
|
|
|
|
enum
|
|
|
|
{
|
|
|
|
G_Player_ammo,
|
2017-09-29 04:50:36 -07:00
|
|
|
G_Player_lives,
|
2017-10-04 02:07:02 -07:00
|
|
|
G_Player_lvx,
|
2017-09-29 04:50:36 -07:00
|
|
|
G_Player_nextfire,
|
2017-09-27 19:26:32 -07:00
|
|
|
G_Player_propC
|
|
|
|
};
|
|
|
|
|
|
|
|
#define G_Player_props() G_Entity_props() \
|
2017-10-04 02:07:02 -07:00
|
|
|
G_Player_propMem(unsigned, ammo) \
|
|
|
|
G_Player_propMem(unsigned, lives) \
|
|
|
|
G_Player_propMem(DGE_Accum, lvx) \
|
|
|
|
G_Player_propMem(unsigned, nextfire)
|
2017-10-04 20:19:27 -07:00
|
|
|
typedef struct G_player
|
2017-09-27 19:26:32 -07:00
|
|
|
{
|
|
|
|
int id;
|
|
|
|
|
|
|
|
G_Player_props()
|
2017-10-04 20:19:27 -07:00
|
|
|
} G_player;
|
2017-09-27 19:26:32 -07:00
|
|
|
|
|
|
|
// Extern Objects ------------------------------------------------------------|
|
|
|
|
|
2017-10-04 20:19:27 -07:00
|
|
|
extern int G_Player_Count;
|
2017-09-27 19:26:32 -07:00
|
|
|
|
|
|
|
// Extern Functions ----------------------------------------------------------|
|
|
|
|
|
2017-10-04 20:19:27 -07:00
|
|
|
DGE_Callback void G_Player_Think(G_enttype const *ty, unsigned id);
|
2017-09-27 19:26:32 -07:00
|
|
|
|
|
|
|
#endif
|