5 PROPERTY(float, g_pickup_ammo_anyway);
10 ATTRIB(Ammo, m_pickupevalfunc, float(entity player, entity item), ammo_pickupevalfunc);
11 ATTRIB(Ammo, m_respawntime, float(), GET(g_pickup_respawntime_ammo));
12 ATTRIB(Ammo, m_respawntimejitter, float(), GET(g_pickup_respawntimejitter_ammo));
13 ATTRIB(Ammo, m_pickupanyway, float(), GET(g_pickup_ammo_anyway));
18 #include <common/t_items.qh>
22 MODEL(Bullets_ITEM, Item_Model("a_bullets.mdl"));
26 PROPERTY(int, g_pickup_nails);
27 void ammo_bullets_init(entity item)
30 item.ammo_nails = g_pickup_nails;
33 REGISTER_ITEM(Bullets, Ammo) {
35 this.m_model = MDL_Bullets_ITEM;
37 this.m_name = "bullets";
38 this.m_icon = "ammo_bullets";
40 this.m_botvalue = 1500;
41 this.m_itemid = IT_NAILS;
42 this.m_iteminit = ammo_bullets_init;
47 MODEL(Cells_ITEM, Item_Model("a_cells.md3"));
51 PROPERTY(int, g_pickup_cells);
52 void ammo_cells_init(entity item)
55 item.ammo_cells = g_pickup_cells;
58 REGISTER_ITEM(Cells, Ammo) {
60 this.m_model = MDL_Cells_ITEM;
62 this.m_name = "cells";
63 this.m_icon = "ammo_cells";
65 this.m_botvalue = 1500;
66 this.m_itemid = IT_CELLS;
67 this.m_iteminit = ammo_cells_init;
72 MODEL(Plasma_ITEM, Item_Model("a_cells.md3"));
76 PROPERTY(int, g_pickup_plasma);
77 void ammo_plasma_init(entity item)
80 item.ammo_plasma = g_pickup_plasma;
83 REGISTER_ITEM(Plasma, Ammo) {
85 this.m_model = MDL_Plasma_ITEM;
87 this.m_name = "plasma";
88 this.m_icon = "ammo_plasma";
90 this.m_botvalue = 1500;
91 this.m_itemid = IT_PLASMA;
92 this.m_iteminit = ammo_plasma_init;
97 MODEL(Rockets_ITEM, Item_Model("a_rockets.md3"));
101 PROPERTY(int, g_pickup_rockets);
102 void ammo_rockets_init(entity item)
104 if(!item.ammo_rockets)
105 item.ammo_rockets = g_pickup_rockets;
108 REGISTER_ITEM(Rockets, Ammo) {
110 this.m_model = MDL_Rockets_ITEM;
112 this.m_name = "rockets";
113 this.m_icon = "ammo_rockets";
115 this.m_botvalue = 1500;
116 this.m_itemid = IT_ROCKETS;
117 this.m_iteminit = ammo_rockets_init;
122 MODEL(Shells_ITEM, Item_Model("a_shells.md3"));
126 PROPERTY(int, g_pickup_shells);
127 void ammo_shells_init(entity item)
129 if(!item.ammo_shells)
130 item.ammo_shells = g_pickup_shells;
133 REGISTER_ITEM(Shells, Ammo) {
135 this.m_model = MDL_Shells_ITEM;
137 this.m_name = "shells";
138 this.m_icon = "ammo_shells";
140 this.m_botvalue = 1000;
141 this.m_itemid = IT_SHELLS;
142 this.m_iteminit = ammo_shells_init;