Skip to content

Commit a72eb2d

Browse files
authored
Merge pull request #71 from Hedgefog/master
Release 1.4.0
2 parents f0df5fc + f5fadc5 commit a72eb2d

35 files changed

+1681
-267
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
### Zombie Panic Mod for Counter-Strike 1.6
2-
__Version:__ 1.3.0
2+
__Version:__ 1.4.0
33

44
### Download latest:
55
- [Releases](../../releases)

assets/addons/amxmodx/configs/plugins-zombiepanic.ini

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ zp_music.amxx
2626
zp_use_pickup.amxx
2727
zp_controls.amxx
2828
zp_infection.amxx
29+
; zp_bot_fixes.amxx
2930

3031
; Hud
3132
zp_mapinfo.amxx
@@ -71,7 +72,10 @@ zp_entity_weapon_handgrenade.amxx
7172
zp_entity_weapon_satchel.amxx
7273
zp_entity_weapon_shotgun.amxx
7374
zp_entity_weapon_9mmhandgun.amxx
75+
zp_entity_weapon_crowbar.amxx
7476

7577
; Extra
7678
zp_objective_marks.amxx
77-
zp_hud_hints.amxx
79+
zp_hints.amxx
80+
81+

assets/addons/amxmodx/configs/zombiepanic.cfg

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ mp_scoreboard_showhealth 0
88
mp_scoreboard_showmoney 0
99

1010
// [Zombie Panic] Flashlight
11-
zp_flashlight_consumption_rate 0.5
11+
zp_flashlight_consumption_rate 1.0
1212
zp_flashlight_recovery_rate 0.5
1313

1414
// [Zombie Panic] Gamerules
@@ -38,8 +38,9 @@ zp_zombievision_auto 1
3838

3939
// [Entity] item_healthkit
4040
zp_healthkit_cure_chance 25
41+
zp_healthkit_suspend_infection 1
4142

42-
// [Zombie Panic] Hints HUD
43+
// [Zombie Panic] Hints
4344
zp_hints 1
4445

4546
// [Zombie Panic] Objective Marks

assets/addons/amxmodx/configs/zombiepanic/characters/male.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
{
2+
"selectable": true,
23
"models": {
34
"zombie": "models/zombiepanic/v100/characters/male/zombie.mdl",
45
"human": "models/zombiepanic/v100/characters/male/human.mdl",

assets/maps/zpo_contingency.bsp

116 Bytes
Binary file not shown.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "zombiepanic",
3-
"version": "1.3.0",
3+
"version": "1.4.0",
44
"description": "Zombie Panic Mod",
55
"scripts": {
66
"gulp": "gulp",

src/include/api_custom_weapons.inc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ enum CW_Flags (<<=1) {
5151

5252
native CW:CW_Register(const szName[], iWeaponId, iClipSize = WEAPON_NOCLIP, iPrimaryAmmoType = -1, iPrimaryAmmoMaxAmount = -1, iSecondaryAmmoType = -1, iSecondaryAmmoMaxAmount = -1, iSlotId = 0, iPosition = 0, iWeaponFlags = 0, const szIcon[] = "", CW_Flags:iFlags = CWF_None);
5353
native CW_Bind(CW:iHandler, CW_Binding:iBinding, const szFunctionName[]);
54-
native CW:CW_GetHandlerByEntity(iEntity);
54+
native CW:CW_GetHandlerByEntity(pEntity);
5555
native CW:CW_GetHandler(const szName[]);
5656

5757
native CW_Deploy(pItem);

src/include/zombiepanic.inc

Lines changed: 47 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,38 @@
11
/*
2+
1.4.0
3+
Additions and improvements:
4+
Infected players with symptoms can now pickup healthkit
5+
Healthkit is now suspends infection
6+
Player disconnection now affets zombie lives
7+
Increased flashlight consumption rate
8+
Bots no longer affect items respawn
9+
Reduced respawn control range for not visible items
10+
Added bodyindex property to Character API
11+
Added inherit property to Characters API
12+
Reduced weapon drop velocity
13+
Force disable minmodels
14+
Added weapon_crowbar entity
15+
Updated humans win message
16+
Increased duration for win message screen fade effect
17+
Improved team menu
18+
Added plugin to fix and improve bots behavior
19+
20+
Cvars:
21+
Added zp_healthkit_suspend_infection cvar
22+
23+
Fixes:
24+
Fixed weaponbox cleanup
25+
Fixed a bug when weapons overflow entities storage
26+
Grenades can no longer be dropped at the start of a throw
27+
Fixed melee hit detection
28+
Fixed respawn task for spectators
29+
Fixed respawn hints
30+
Fixed infected attribute updating
31+
Fixed weapon animations for spectators
32+
Fixed crosshair for spectators
33+
Fixed team info for spectators
34+
Fixed game messages on zpo_contingency map
35+
236
1.3.0
337
Additions and improvements:
438
Removed default pain sound
@@ -81,16 +115,21 @@ native bool:ZP_Player_IsInfected(pPlayer);
81115
native bool:ZP_Player_IsTransforming(pPlayer);
82116
native bool:ZP_Player_IsPartialZombie(pPlayer);
83117
native ZP_Player_SetInfected(pPlayer, bool:bValue, pInfector = 0);
118+
native ZP_Player_GetInfector(pPlayer);
84119
native bool:ZP_Player_SetCharacter(pPlayer, const szCharacter[]);
85120

86121
forward ZP_Fw_PlayerJoined(pPlayer);
87122
forward ZP_Fw_PlayerPanic(pPlayer);
88123
forward ZP_Fw_PlayerZombieVision(pPlayer, bool:bValue);
89-
forward ZP_Fw_Player_AimItem(pPlayer, pItem);
124+
forward ZP_Fw_PlayerAimItem(pPlayer, pItem);
90125
forward ZP_Fw_PlayerInfected(pPlayer, pInfector);
126+
forward ZP_Fw_PlayerCured(pPlayer);
91127
forward ZP_Fw_PlayerTransformationDeath(pPlayer);
92128
forward ZP_Fw_PlayerTransformed(pPlayer);
93129
forward ZP_Fw_PlayerEquiped(pPlayer);
130+
forward ZP_Fw_PlayerSpeedUpdated(pPlayer);
131+
forward ZP_Fw_PlayerCharacterUpdated(pPlayer);
132+
forward ZP_Fw_PlayerModelUpdated(pPlayer);
94133

95134
// Player inventory
96135

@@ -102,6 +141,8 @@ native ZP_Player_SetAmmo(pPlayer, const szAmmo[], iValue);
102141
native ZP_Player_AddAmmo(pPlayer, const szAmmo[], iValue);
103142
native ZP_Player_NextAmmo(pPlayer);
104143
native ZP_Player_DropAmmo(pPlayer);
144+
native ZP_Player_GetSelectedAmmo(pPlayer);
145+
native ZP_Player_SetSelectedAmmo(pPlayer, const szAmmo[]);
105146

106147
// Weapons
107148

@@ -131,6 +172,11 @@ native ZP_GameRules_DispatchWin(iTeam);
131172
native ZP_GameRules_CanItemRespawn(pItem);
132173
native ZP_GameRules_IsCompetitive();
133174

175+
forward ZP_Fw_NewRound();
176+
forward ZP_Fw_RoundStarted();
177+
forward ZP_Fw_RoundEnd(iWinnerTeam);
178+
forward ZP_Fw_ZombieLivesChanged(iLives);
179+
134180
// Map Info
135181

136182
native ZP_ShowMapInfo(pPlayer);

src/include/zombiepanic_const.inc

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,10 @@
11
#define ZP_TITLE "Zombie Panic"
2-
#define ZP_VERSION "1.3.0"
2+
#define ZP_VERSION "1.4.0"
33

44
#define ZP_HUMAN_TEAM 2
55
#define ZP_ZOMBIE_TEAM 1
6-
#define ZP_ZOMBIE_WIN_MESSAGE "#Terrorists_Win"
7-
#define ZP_HUMAN_WIN_MESSAGE "#CTs_Win"
86
#define ZP_ZOMBIE_TEAM_NAME "Zombies"
9-
#define ZP_HUMAN_TEAM_NAME "Survivors"
7+
#define ZP_HUMAN_TEAM_NAME "Humans"
108

119
#define ZP_HUMAN_HEALTH 100.0
1210
#define ZP_ZOMBIE_HEALTH 200.0

src/include/zombiepanic_utils.inc

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -206,3 +206,32 @@ stock UTIL_SetupSpawnerRespawn(pEntity) {
206206
}
207207
}
208208

209+
stock UTIL_GetAmmoId(const szAmmoName[]) {
210+
new iSize = sizeof(AMMO_LIST);
211+
for (new iAmmoId = 0; iAmmoId < iSize; ++iAmmoId) {
212+
if (equal(AMMO_LIST[iAmmoId], szAmmoName)) {
213+
return iAmmoId;
214+
}
215+
}
216+
217+
return -1;
218+
}
219+
220+
stock bool:UTIL_IsUsableButton(pButton, pPlayer) {
221+
new iszMaster = get_ent_data(pButton, "CBaseToggle", "m_sMaster");
222+
223+
if (iszMaster) {
224+
static szMaster[32];
225+
engfunc(EngFunc_SzFromIndex, iszMaster, szMaster, charsmax(szMaster));
226+
227+
if (!UTIL_IsMasterTriggered(szMaster, pPlayer)) {
228+
return false;
229+
}
230+
}
231+
232+
if (get_ent_data(pButton, "CBaseToggle", "m_toggle_state") != TS_AT_BOTTOM) {
233+
return false;
234+
}
235+
236+
return true;
237+
}

0 commit comments

Comments
 (0)