Skip to content

Commit

Permalink
Update 08-02-2022
Browse files Browse the repository at this point in the history
  • Loading branch information
PerfectScrash committed Feb 8, 2022
1 parent 87229d5 commit d5a3edd
Show file tree
Hide file tree
Showing 12 changed files with 1,049 additions and 526 deletions.
43 changes: 38 additions & 5 deletions Readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -245,15 +245,48 @@ Bombardier (From ZP Shade), Wesker (From Zombie Apocalipse), Spy and Dragon

* 4.5:
- REMOVED Amx 1.8.2 SUPORT
- Fixed trigger_hurt when killing with bugged players.
- Fixed trigger_hurt when killing with bugged players (i think).
- Fixed chat lang bug. (Sometimes appears in [en] language not in players language)
- Added Native: zp_force_user_class(id, spid, zombie, attacker = 0, sillentmode = 1)
- Added Native: zpsp_set_user_frozen(id, set, Float:Duration = -1.0)
- Added Native: zpsp_set_user_burn(id, set, Float:Duration = -1.0)
- Added Cvars: zp_human_frags_for_disinfect, zp_human_disnfect_reward
- Updated Native: zp_set_user_frozen(id, set, Float:Duration = -1.0)
- Updated Native: zp_set_user_madness(id, set, Float:Duration = -1.0)
- Updated Native: zp_set_user_burn(id, set, Float:Duration = -1.0)
- Added Cvars: zp_human_frags_for_disinfect, zp_human_disnfect_reward, zp_green_deathmsg
- Removed "HANDLE MODELS ON SEPARATE ENT"
- Removed "MODELCHANGE DELAY"
- Now models system are using "cstrike" module
- Added Native: zpsp_override_user_model(id, const model, body=0, skin=0, modelindex=0)
- Added Player Submodel Support (You can add more player models using only 1 .mdl)
- Added Player Skin Support (You can use other textures with 1 .mdl)
- Added Player Skin Support (You can use other textures with 1 .mdl)
- Added Native: zp_set_fw_param_int(int_id, value)
- Added Many Stocks (Check zpsp_stocks.inc)
- Fixed bug when you create a custom zombie special with same name with any custom human special
- Added Human Classes System
- Added Native: zp_register_human_class(const name[], const info[], hp, armor, speed, Float:gravity, use_lang=0, const name_lang_key[]="ITEM_LANG_DEFAULT_KEY", const info_lang_key[]="ITEM_LANG_DEFAULT_KEY");
- Added Native: zp_get_user_human_class(id);
- Added Native: zp_get_next_human_class(id);
- Added Native: zp_set_user_human_class(id, classid);
- Added Native: zp_register_hclass_model(classid, player_model[], body=0, skin=0)
- Added Native: zp_get_human_class_id(const name[])
- Added Native: zp_get_human_class_info(id, info[], len)
- Added Native: zp_get_human_class_name(id, name[], len)
- Added Native: zp_set_human_class_info(id, const info[])
- Added Native: zp_set_human_class_name(id, const name[])
- Added Native: zp_get_human_class_realname(id, realname[], len)
- Added Forward: zp_human_class_choosed_pre(id, classid)
- Added Forward: zp_human_class_choosed_post(id, classid)
- Added Native: zp_drop_weapons(id, dropwhat)
- Added Native: zp_give_item(id, const item[])
- Added Native: zp_strip_user_weapons(id)
- Added Native: zp_menu_textadd(const text[])
- Updated Native: zp_register_weapon(const name[], wpn_type, uselang=0, const langkey[] = "ITEM_LANG_DEFAULT_KEY")
- Added Cvar: zp_choose_hclass_instantanly
- Added "FLAGS" option in "zpsp_gamemodes.ini" and in "zpsp_special_classes.ini"
- Improved "save_custonomization" system
- Improved model/sound system for any external class
- Updated Native: zp_disinfect_user(id, silent, attacker)
- Updated Native: zpsp_register_gamemode(const name[], flags, chance, allow, dm_mode, resp_limit=0, enable_in_ze=0, uselang=0, const langkey[]="ITEM_LANG_DEFAULT_KEY");
- Added Forward: zp_player_show_hud(id, target, SpHudType:hudtype);
- Added Native: zp_add_hud_text(const text[]);
- Added Native: zp_get_user_hud_type(id);
- Now all natives are using "style 0"
1 change: 1 addition & 0 deletions addons/amxmodx/configs/zombie_plague_special.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ zp_bot_buy_extra_interval "60.0" // Interval for Buy Extra Item
zp_hud_display "1" // Enable ZP custom HUD display
zp_allow_buy_extra_before_start "1" // Buy Extra Item Berore Round Begins ? [0-disabled // 1-enable]
zp_choose_zclass_instantanly "0" // Choose a Zombie Class Immediate ? [0-disabled // 1-enable]
zp_choose_hclass_instantanly "0" // Choose a Human Class Immediate ? [0-disabled // 1-enable]
zp_zombie_idle_sound "1" // Zombie Idle Sound [0-disabled // 1-enable]
zp_ammopack_damage "1" // Ammo pack by damage
zp_green_deathmsg "1" // Green Deathmsg when player infecting another player [0-disabled // 1-enable]
Expand Down
24 changes: 24 additions & 0 deletions addons/amxmodx/configs/zpsp_humanclasses.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
; =========================================================
; * || Zombie Plague Special 4.5 Human Classes File || *
; =========================================================
;
; Any changes you make here will be
; automatically loaded at map start
;
; This file will be automatically updated with new
; editable entries as you install new human classes.

; Example:
; [Classic] // Section Name (Dont Change)
; NAME = Classic // Class name
; INFO = -=Balanced=- // Class Description
; HEALTH = 300 // Class Health (0 - For default human health by cvar)
; ARMOR = 0 // Class Armor
; SPEED = 0 // Class Speed (0 - For default human speed by cvar)
; GRAVITY = 0.8 // Class Gravity (0.0 - For default human gravity by cvar)
; MODELS = sas // Class model
; BODY = 0 // Model Bodygroup
; SKIN = 0 // Model Skin textures
; USE LANG = 0 // Enable Lang for Class Name and Class Description
; NAME LANG KEY = ITEM_LANG_DEFAULT_KEY // Lang Key for Class Name
; INFO LANG KEY = ITEM_LANG_DEFAULT_KEY // Lang Key for Class Description
16 changes: 10 additions & 6 deletions addons/amxmodx/data/lang/zombie_plague_special.txt
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ CMD_NOT_CANTUSE = You can't use this right now.
CMD_NOT_EXTRAS = Extra Items are disabled.
CMD_NOT_GAME_MODES = Custom game modes are disabled
CMD_NOT_ZCLASSES = Zombie Classes are disabled.
CMD_NOT_HCLASSES = Human Classes are disable.
CMD_NOT_CUSTOM_SP = Custom Special Classes are disabled.
CMD_HAVE_ITEM = You have alterady this item.
CMD_CUSTOM_SP = turned into a %s
Expand Down Expand Up @@ -289,6 +290,7 @@ CMD_NOT_CANTUSE = Voce nao Pode usar isso Agora.
CMD_NOT_EXTRAS = Itens Extras Desligados.
CMD_NOT_GAME_MODES = Modos Custonomizados Desligados.
CMD_NOT_ZCLASSES = Classes de Zombie Desligado.
CMD_NOT_HCLASSES = Classes de Humano desligado.
CMD_NOT_CUSTOM_SP = Classes Especiais Custonomizdas Desligados.
CMD_HAVE_ITEM = Voce Ja Tem esse Item.
CMD_CUSTOM_SP = Foi Convertido a %s
Expand Down Expand Up @@ -331,7 +333,7 @@ MENU_ADMIN_CUSTOM_SP_Z = Converter a Zombie Especial Custonomizado
MENU_BUY1_TITLE = Arma Primaria
MENU_BUY2_TITLE = Arma Secundaria
MENU_ZCLASS_TITLE = Escolher Classe de Zombie
MENU_HCLASS_TITLE = Human Class
MENU_HCLASS_TITLE = Escolher Classe de Humano
MENU_EXTRA_TITLE = Itens Extras
MENU_ADMIN_CUSTOM_TITLE = Iniciar Modo Custonomizado
MENU_ADMIN_TITLE = Mudar Classe de jogador
Expand Down Expand Up @@ -525,6 +527,7 @@ CMD_NOT_CANTUSE = No puedes usar esto ahora.
CMD_NOT_EXTRAS = los Items Extra estan deshabilitados.
CMD_NOT_GAME_MODES = los Juegos Personalizados estan deshabilitados.
CMD_NOT_ZCLASSES = las Clases Zombies estan deshabilitadas.
CMD_NOT_HCLASSES = las Clases Humanas estan deshabilitadas.
CMD_NOT_CUSTOM_SP = las Clases Especiales Personalizadas estan deshabilitadas.
CMD_HAVE_ITEM = Ya tienes este item.
CMD_CUSTOM_SP = convertido en %s
Expand All @@ -549,7 +552,7 @@ ZP_MAIN_MENU_TITLE = Zombie Plague Especial
MENU_BUY = Comprar Armas
MENU_EXTRABUY = Comprar Items Extra
MENU_ZCLASS = Elegir Clase Zombie
MENU_HCLASS = Choose Human class
MENU_HCLASS = Elegir Clase Humano
MENU_UNSTUCK = Destrabar
MENU_ADMIN_CUSTOM = Comenzar Modo Personalizado
MENU_ADMIN = Cambiar Clase
Expand All @@ -560,8 +563,8 @@ MENU_SPECTATOR = Unirse a los Espectadores

MENU_BUY1_TITLE = Arma Primaria
MENU_BUY2_TITLE = Arma Secundaria
MENU_ZCLASS_TITLE = Clase Zombie
MENU_HCLASS_TITLE = Human Class
MENU_ZCLASS_TITLE = Elegir Clase Zombie
MENU_HCLASS_TITLE = Elegir Classe Humano
MENU_EXTRA_TITLE = Items Extra
MENU_ADMIN_CUSTOM_TITLE = Elige un Modo Personalizado para comenzar
MENU_ADMIN_TITLE = Cambiar Clase
Expand Down Expand Up @@ -760,6 +763,7 @@ CMD_NOT_CANTUSE = Ezt most nem tudod használni.
CMD_NOT_EXTRAS = Extra eszközök letiltva.
CMD_NOT_GAME_MODES = Játékmódok letiltva
CMD_NOT_ZCLASSES = Zombie Osztályok letiltva.
CMD_NOT_HCLASSES = Human Osztályok letiltva.
CMD_NOT_CUSTOM_SP = Speciális Osztályok letiltva.
CMD_HAVE_ITEM = Már rendelkezel ezzel.
CMD_CUSTOM_SP = %s lett.
Expand All @@ -784,7 +788,7 @@ ZP_MAIN_MENU_TITLE = Zombie Plague Special
MENU_BUY = Fegyver vásárlás
MENU_EXTRABUY = Extra eszközök vásárlása
MENU_ZCLASS = Zombi osztályok
MENU_HCLASS = Choose Human class
MENU_HCLASS = Human osztályok
MENU_UNSTUCK = Kiszabadítás
MENU_ADMIN_CUSTOM = Mód Menü (egyéb)
MENU_ADMIN = Osztály váltás
Expand All @@ -796,7 +800,7 @@ MENU_SPECTATOR = Csatlakozás nézőnek
MENU_BUY1_TITLE = Elsődleges fegyver
MENU_BUY2_TITLE = Másodlagos fegyver
MENU_ZCLASS_TITLE = Zombi típusok
MENU_HCLASS_TITLE = Human Class
MENU_HCLASS_TITLE = Human típusok
MENU_EXTRA_TITLE = Extra eszközök
MENU_ADMIN_CUSTOM_TITLE = Válassz a módok közül az indításhoz
MENU_ADMIN_TITLE = Típus választás
Expand Down
36 changes: 23 additions & 13 deletions addons/amxmodx/scripting/examples/zpsp_hclass_example.sma
Original file line number Diff line number Diff line change
Expand Up @@ -14,25 +14,21 @@
================================================================================*/

#include <amxmodx>
#include <fakemeta>
#include <cstrike>
#include <zombie_plague_special>

native zp_register_human_class(const name[], const info[], hp, armor, speed, Float:gravity);
native zp_get_user_human_class(id);
native zp_get_next_human_class(id);
native zp_set_user_human_class(id, classid);

/*================================================================================
[Plugin Customization]
=================================================================================*/

// Classic Zombie Attributes
new const hclass_name[] = { "Humano Colete" }
new const hclass_info[] = { "=Teste=" }
const hclass_health = 500
const hclass_armor = 200
const hclass_speed = 900
const Float:hclass_gravity = 0.3
new const hclass_name[] = { "Sniper" }
new const hclass_info[] = { "Free G3SG1" }
const hclass_health = 300
const hclass_armor = 0
const hclass_speed = 240
const Float:hclass_gravity = 0.5
new const hclass_models[][] = { "vip" , "sas" , "urban" }

/*============================================================================*/

Expand All @@ -45,20 +41,34 @@ public plugin_precache() {

// Register all classes
g_classid = zp_register_human_class(hclass_name, hclass_info, hclass_health, hclass_armor, hclass_speed, hclass_gravity)

// Register models
for (new index = 0; index < sizeof hclass_models; index++)
zp_register_hclass_model(g_classid, hclass_models[index])
}

// Set attributes when spawn/disinfect
/*
public zp_user_humanized_post(id) {
if(zp_get_user_human_class(id) == g_classid)
hclass_attributes(id)
}
public zp_player_spawn_post(id) {
if(zp_get_user_human_class(id) == g_classid)
hclass_attributes(id)
}
*/

// Set Attributes after choose weapons
public zp_weapon_selected_post(id, wpn_type) {
if(wpn_type == WPN_SECONDARY && zp_get_user_human_class(id) == g_classid)
hclass_attributes(id)
}

hclass_attributes(id) {
if(!is_user_alive(id))
return;

client_print_color(id, print_team_default, "Classe Colete Teste")
zp_give_item(id, "weapon_g3sg1");
cs_set_user_bpammo(id, CSW_G3SG1, 90);
}
25 changes: 25 additions & 0 deletions addons/amxmodx/scripting/examples/zpsp_test_hud_natives.sma
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#include <amxmodx>
#include <zombie_plague_special>

public plugin_init() {
register_plugin("[ZPSp] Test Hud Natives", "1.0", "Perf. Scrash");
}
public zp_player_show_hud(id, target, SpHudType:hudtype) {
if(target) {
zp_add_hud_text("- Spec Hud")
return;
}
if(!is_user_alive(id))
return;

if(hudtype == HUD_DEFAULT)
zp_add_hud_text("^n[Hud Default]")
else if(hudtype == HUD_CLASSIC)
zp_add_hud_text("- Hud Classic")
else if(hudtype == HUD_ANTRAX_STYLE || hudtype == HUD_CENTER_ANTRAX)
zp_add_hud_text("^n[Hud AntRax]")
else
zp_add_hud_text("^n[Any other HUD]")

zp_add_hud_text("^n[Concat Test]")
}
11 changes: 5 additions & 6 deletions addons/amxmodx/scripting/examples/zpsp_weapon_example.sma
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
#include <amxmodx>
#include <cstrike>
#include <fun>
#include <zombie_plague_special>

#if ZPS_INC_VERSION < 42
#assert Zombie Plague Special 4.2 Include File Required. Download Link: https://forums.alliedmods.net/showthread.php?t=260845
#if ZPS_INC_VERSION < 45
#assert Zombie Plague Special 4.5 Include File Required. Download Link: https://forums.alliedmods.net/showthread.php?t=260845
#endif

#define PLUGIN "[ZPSp] Custom Weapon Example"
#define VERSION "1.0"
#define VERSION "1.1"
#define AUTHOR "[P]erfect [S]crash"

new wpn_id[2]
Expand All @@ -21,11 +20,11 @@ public plugin_init() {
}
public zp_weapon_selected_post(id, wpn_type, weaponid) {
if(wpn_type == WPN_PRIMARY && weaponid == wpn_id[0]) {
give_item(id, "weapon_g3sg1")
zp_give_item(id, "weapon_g3sg1")
cs_set_user_bpammo(id, CSW_G3SG1, 90)
}
else if(wpn_type == WPN_SECONDARY && weaponid == wpn_id[1]) {
give_item(id, "weapon_deagle")
zp_give_item(id, "weapon_deagle")
cs_set_user_bpammo(id, CSW_DEAGLE, 35)
}
}
Loading

0 comments on commit d5a3edd

Please sign in to comment.