Existing user? Sign in
Sign up
Games
Servers
Useful
User
Pass
2FA
[rezolvat]Problema plugin Nab Zombie
Freakz Forum Index
->
Trash Bin
->
CS 2006-2019 (Archived)
->
Plugins - Help / Support
Author
Message
770
zp.Bodo
[Creep]
Status: Offline
(since 17-11-2019 13:51)
Joined: 15 Jun 2014
Posts: 663
,
Topics: 166
Location:
Romania
Reputation:
548.2
Votes
: 20
Posted: 10-02-2017, 19:26:00
| Translate post to:
... (
Click for more languages
)
»Nume*: Zombie Nab (reinvie de 4 ori)
»Descriere problema*: Imi da eroare in consola serverului la clasa de nab zombie. Sa fie de la clasa Zombie respawn pentru ca au aceeasi abilitate?
Folosesc acelasi plugin doar ca sunt la levele diferite.
»Poze/Sma:
SMA
Spoiler:
#include <amxmodx>
#include <amxmisc>
#include <fun>
#include <hamsandwich>
#include <zombieplague>
#include <zombiexp>
#define PLUGNAME "[ZP] Zombie Respawn"
#define AUTHOR "CHyC/PomanoB"
#define VERSION "4.0"
new const zclass_name[] = { "Nab Zombie" }
new const zclass_info[] = { "Can revive 4 times" }
new const zclass_model[] = { "zombie_source" }
new const zclass_clawmodel[] = { "v_knife_zombie.mdl" }
const zclass_health = 3600
const zclass_speed = 300
const Float:zclass_gravity = 0.8
const Float:zclass_knockback = 0.1
const zclass_level = 1 // level required to use
new bool:g_end
new g_respawn_count[33]
new cvar_maxspawn , cvar_spawndelay , cvar_color , cvar_colorspawn , cvar_amount , cvar_time;
new g_zclass_respawn
public plugin_precache()
{
g_zclass_respawn = zpxp_register_zombie_class(zclass_name, zclass_info, zclass_model, zclass_clawmodel, zclass_health, zclass_speed, zclass_gravity, zclass_knockback, zclass_level)
}
public plugin_init()
{
RegisterHam(Ham_Killed, "player", "PlayerKilled", 1);
register_cvar("zp_respawn", VERSION, FCVAR_SERVER)
cvar_maxspawn = register_cvar("zp_max_spawn" , "4");
cvar_spawndelay = register_cvar("zp_spawn_time" , "5.0");
cvar_color = register_cvar("zp_color" , "1");
cvar_colorspawn = register_cvar("zp_color_spawn" , "0 255 0");
cvar_amount = register_cvar("zp_color_amount" , "30");
cvar_time = register_cvar("zp_color_time" , "10.0");
}
public PlayerKilled(Victim)
if (zp_get_user_zombie(Victim) && zp_get_user_zombie_class(Victim) == g_zclass_respawn && !zp_get_user_nemesis(Victim))
set_task((get_pcvar_float(cvar_spawndelay)), "PlayerRespawn", Victim);
public PlayerRespawn(id)
{
if (g_respawn_count[id]++>=get_pcvar_num(cvar_maxspawn))
return PLUGIN_CONTINUE;
if (!g_end && !is_user_alive(id) && zp_get_user_zombie(id) && zp_get_user_zombie_class(id) == g_zclass_respawn && !zp_get_user_nemesis(id))
{
remove_task(id);
zp_respawn_user(id, ZP_TEAM_ZOMBIE)
if(get_pcvar_num(cvar_color))
{
new szColor[12], szRed[4], szGreen[4], szBlue[4]
get_pcvar_string(cvar_colorspawn,szColor,11)
parse(szColor,szRed,3,szGreen,3,szBlue,4)
new iRed = clamp(str_to_num(szRed),0,255)
new iGreen = clamp(str_to_num(szGreen),0,255)
new iBlue = clamp(str_to_num(szBlue),0,255)
set_user_rendering(id,kRenderFxGlowShell,iRed,iGreen,iBlue,kRenderNormal,get_pcvar_num(cvar_amount))
set_task(get_pcvar_float(cvar_time),"event_time_color",id)
}
}
return PLUGIN_CONTINUE;
}
public event_time_color(id)
{
set_user_rendering(id,kRenderFxNone,0,0,0,kRenderNormal,0)
}
public zp_round_ended(winteam)
{
g_end = true
}
public zp_round_started(gamemode, player)
{
g_end = false
arrayset(g_respawn_count,0,33)
}
Code:
L 02/10/2017 - 19:19:28: [AMXX] Run time error 10 (plugin "1_nab.amxx") (native "set_user_rendering") - debug not enabled!
L 02/10/2017 - 19:19:28: [AMXX] To enable debug mode, add "debug" after the plugin name in plugins.ini (without quotes).
Contact Skype | zm.bodo
Grup Facebook |
CSRO 2k17+
0
0
Back to top
|X|Repper
[]King Of The Night[]
Status: Offline
(online 2 weeks ago)
Joined: 19 Apr 2014
Posts: 4444
,
Topics: 241
Location:
Romania
Reputation:
433.1
Votes
: 365
Posted: 10-02-2017, 20:01:50
| Translate post to:
... (
Click for more languages
)
Ai incercat sa ii adaugi debug la final in plugins.ini?
0
0
Back to top
SamDude
[★★★]
Status: Offline
(since 09-07-2020 08:13)
Joined: 06 Jun 2010
Posts: 10525
,
Topics: 516
Location:
Romania
Reputation:
317.7
Votes
: 122
Posted: 11-02-2017, 16:44:31
| Translate post to:
... (
Click for more languages
)
Ar trebui sa nu mai apara
Spoiler:
#include <amxmodx>
#include <amxmisc>
#include <fun>
#include <hamsandwich>
#include <zombieplague>
#include <zombiexp>
#define PLUGNAME "[ZP] Zombie Respawn"
#define AUTHOR "CHyC/PomanoB"
#define VERSION "4.0"
new const zclass_name[] = { "Nab Zombie" }
new const zclass_info[] = { "Can revive 4 times" }
new const zclass_model[] = { "zombie_source" }
new const zclass_clawmodel[] = { "v_knife_zombie.mdl" }
const zclass_health = 3600
const zclass_speed = 300
const Float:zclass_gravity = 0.8
const Float:zclass_knockback = 0.1
const zclass_level = 1 // level required to use
new bool:g_end
new g_respawn_count[33]
new cvar_maxspawn , cvar_spawndelay , cvar_color , cvar_colorspawn , cvar_amount , cvar_time;
new g_zclass_respawn
public plugin_precache()
{
g_zclass_respawn = zpxp_register_zombie_class(zclass_name, zclass_info, zclass_model, zclass_clawmodel, zclass_health, zclass_speed, zclass_gravity, zclass_knockback, zclass_level)
}
public plugin_init()
{
RegisterHam(Ham_Killed, "player", "PlayerKilled", 1);
register_cvar("zp_respawn", VERSION, FCVAR_SERVER)
cvar_maxspawn = register_cvar("zp_max_spawn" , "4");
cvar_spawndelay = register_cvar("zp_spawn_time" , "5.0");
cvar_color = register_cvar("zp_color" , "1");
cvar_colorspawn = register_cvar("zp_color_spawn" , "0 255 0");
cvar_amount = register_cvar("zp_color_amount" , "30");
cvar_time = register_cvar("zp_color_time" , "10.0");
}
public PlayerKilled(Victim)
if (zp_get_user_zombie(Victim) && zp_get_user_zombie_class(Victim) == g_zclass_respawn && !zp_get_user_nemesis(Victim))
set_task((get_pcvar_float(cvar_spawndelay)), "PlayerRespawn", Victim);
public PlayerRespawn(id)
{
if (g_respawn_count[id]++>=get_pcvar_num(cvar_maxspawn))
return PLUGIN_CONTINUE;
if (!g_end && !is_user_alive(id) && zp_get_user_zombie(id) && zp_get_user_zombie_class(id) == g_zclass_respawn && !zp_get_user_nemesis(id))
{
remove_task(id);
zp_respawn_user(id, ZP_TEAM_ZOMBIE)
if(get_pcvar_num(cvar_color))
{
new szColor[12], szRed[4], szGreen[4], szBlue[4]
get_pcvar_string(cvar_colorspawn,szColor,11)
parse(szColor,szRed,3,szGreen,3,szBlue,4)
//set_user_rendering(id,kRenderFxGlowShell,iRed,iGreen,iBlue,kRenderNormal,get_pcvar_num(cvar_amount))
set_task(get_pcvar_float(cvar_time),"event_time_color",id)
}
}
return PLUGIN_CONTINUE;
}
public event_time_color(id)
{
//set_user_rendering(id,kRenderFxNone,0,0,0,kRenderNormal,0)
}
public zp_round_ended(winteam)
{
g_end = true
}
public zp_round_started(gamemode, player)
{
g_end = false
arrayset(g_respawn_count,0,33)
}
0
0
Back to top
ZPLegendary
[Mentally Stable]
Status: Offline
(since 03-10-2019 20:59)
Joined: 13 Jan 2017
Posts: 142
,
Topics: 7
Location:
Polovragi, GJ
Reputation:
15.4
Votes
: 17
Posted: 11-02-2017, 22:26:58
| Translate post to:
... (
Click for more languages
)
Face aceeasi chestie, dar am mai fixat-o putin.
Arata in chat cate respawn-uri mai ai + niste buguri rezolvate.
Am mai folosit o clasa care se reinvia pe langa asta si nu am avut probleme.
Spoiler:
Code:
#include amxmodx>
#include hamsandwich
#include fun
#include zombieplague>
#include colorchat
new const Nume6[] = "Rebirth Zombie"
new const Info6[] = "Respawns 4 Times"
new const Model6[] = "zombie_bullet"
new const ModelMaini6[] = "v_knife_bullet.mdl"
const Viata6 = 6500
const Viteza6 = 355
const Float:Gravitatie6 = 0.90
const Float:Putere6 = 1.0
const Nivel6 = 14
new bool:g_end
new g_respawns[33]
new zrebirth;
native zpxp_register_zombie_class(const name[], const info[], const model[], const clawmodel[], hp, speed, Float:gravity, Float:knockback, level)
public plugin_init() {
register_plugin("Zombie 6", "1.0", "Legendary")
RegisterHam(Ham_Killed, "player", "PlayerKilled", 1);
}
public plugin_precache()
zrebirth = zpxp_register_zombie_class(Nume6, Info6, Model6, ModelMaini6, Viata6, Viteza6, Gravitatie6, Putere6, Nivel6)
public client_putinserver(id)
g_respawns[id] = 0
public client_disconnect(id)
g_respawns[id] = 0
public PlayerKilled(Victim)
{
if(zp_get_user_nemesis(Victim) || zp_get_user_sniper(Victim) || zp_get_user_survivor(Victim) || zp_get_user_assassin(Victim))
return PLUGIN_HANDLED;
if (!g_respawns[Victim])
return PLUGIN_HANDLED;
if (zp_get_user_zombie(Victim) && zp_get_user_zombie_class(Victim) == zrebirth)
{
ColorChat(Victim, RED, "^3[^4Zombie Legendary^3] Vei fi reinviat in^4 3 seuncde^3.")
set_task(3.0, "PlayerRespawn", Victim);
}
return PLUGIN_HANDLED;
}
public PlayerRespawn(id) {
if (!g_respawns[id])
return PLUGIN_HANDLED;
if(zp_get_user_nemesis(id) || zp_get_user_sniper(id) || zp_get_user_survivor(id) || zp_get_user_assassin(id))
return PLUGIN_HANDLED;
if(!zp_get_user_zombie(id))
return PLUGIN_HANDLED;
if (!g_end && zp_get_user_zombie_class(id) == zrebirth)
{
remove_task(id);
g_respawns[id]--
zp_respawn_user(id, ZP_TEAM_ZOMBIE)
ColorChat(id, RED, "^3[^4Zombie Legendary^3] Mai ai^4 %d respawn^3.", g_respawns[id])
set_user_rendering(id,kRenderFxGlowShell,200,0,0,kRenderNormal,30)
set_task(5.0,"event_time_color",id)
}
return PLUGIN_HANDLED;
}
public event_time_color(id)
set_user_rendering(id,kRenderFxNone,0,0,0,kRenderNormal,0)
public zp_round_ended(winteam)
g_end = true
public zp_round_started(gamemode, player) {
g_end = false
g_respawns[player] = 4
}
Be the one, not anyone.
Currently working on Zombie Legendary 8.1
0
0
Back to top
zp.Bodo
[Creep]
Status: Offline
(since 17-11-2019 13:51)
Joined: 15 Jun 2014
Posts: 663
,
Topics: 166
Location:
Romania
Reputation:
548.2
Votes
: 20
Posted: 11-02-2017, 22:29:15
| Translate post to:
... (
Click for more languages
)
Rezolvat. Multumesc amandurora!
Contact Skype | zm.bodo
Grup Facebook |
CSRO 2k17+
0
0
Back to top
Topic locked
Topic is closed, you cannot post any messages in it anymore
Locked by
TheVipera
, 12 February 2017 10:10
Freakz Forum Index
->
Trash Bin
->
CS 2006-2019 (Archived)
->
Plugins - Help / Support
The time now is 10-01-2025, 20:30:57
Copyright info
Based on phpBB
ro
/
com
B
Login
I forgot my password
World of Warcraft
Login for more...
Download WoW 7.3.5
Misc
eSports
Achievements
Buy reputation with votes
Reputation trades
Forum rules
Ban list
Members list
User guide (FAQ)
World of Warcraft
View details