Raised This Month: $ Target: $400
 0% 

[Help]


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
.Dare Devil.
Veteran Member
Join Date: Sep 2010
Old 09-18-2010 , 07:14   [Help]
Reply With Quote #1

PHP Code:
#include <amxmodx>
#include <hamsandwich>
#include <zombieplague>
#define TASK_DUCK 2430
#define ID_DUCK (task_id - TASK_DUCK)
new cvar_redcvar_bluecvar_greencvar_alphag_msgScreenFade
public plugin_init() 
{
    
register_plugin("[ZP] Addon: CSO Screen Fade""1.0""@bdul!")
    
    
cvar_red =     register_cvar("zp_fade_red","150")
    
cvar_green =     register_cvar("zp_fade_green","150")
    
cvar_blue =     register_cvar("zp_fade_blue","150")
    
cvar_alpha =    register_cvar("zp_fade_alpha","150")
    
    
g_msgScreenFade get_user_msgid("ScreenFade")
    
    
RegisterHam(Ham_Spawn"player""fw_PlayerSpawn_Post"1)
    
RegisterHam(Ham_Killed"player""fw_PlayerKilled")
}
// User Infected forward
public zp_user_infected_post(idinfectornemesis)
{
    if (
nemesis)
    {
        
remove_task(nemesis+TASK_DUCK)
        return
    }
        
    
// Check if the infected player is using our custom zombie class
    
if (zp_get_user_zombie(id))
        
set_task(0.1"zp_crouch_user"id+TASK_DUCK__"b")    
    
}
public 
zp_crouch_user(task_id)
{
    
// Make a screen fade 
    
message_begin(MSG_ONEg_msgScreenFade_ID_DUCK)
    
write_short((1<<12)*2// duration
    
write_short(0// hold time
    
write_short(0x0000// fade type
    
write_byte(get_pcvar_num(cvar_red)) // red
    
write_byte(get_pcvar_num(cvar_green)) // green
    
write_byte(get_pcvar_num(cvar_blue)) // blue
    
write_byte(get_pcvar_num(cvar_alpha)) // alpha
    
message_end()
}
// User Humanized forward
public zp_user_humanized_post(idsurvivor)
{
    if (
survivor)
        
remove_task(survivor+TASK_DUCK)
    
    
remove_task(id+TASK_DUCK)
}
// Ham Player Spawn Post Forward
public fw_PlayerSpawn_Post(id)
{
    
// Checks, checks and checks...how bugged would our servers be without them?
    
if (zp_get_user_zombie(id))
        return;
        
    
remove_task(id+TASK_DUCK)
}
// Ham Player Killed Forward
public fw_PlayerKilled(id)
{
    
remove_task(id+TASK_DUCK)

When Zombie Has Frozed ,The Screen Are Black not blue.

I've tried to do yourself, however, I do not know how to do so When Zombie Frozed He Are Blue Screen , no such thing as the zp_get_user_frozed
.Dare Devil. is offline
Old 09-18-2010, 10:31
nikhilgupta345
This message has been deleted by nikhilgupta345. Reason: d
nikhilgupta345
Veteran Member
Join Date: Aug 2009
Location: Virginia
Old 09-18-2010 , 10:32   Re: [Help]
Reply With Quote #2

Just search around for the RGB colors for black.
nikhilgupta345 is offline
Send a message via ICQ to nikhilgupta345 Send a message via Yahoo to nikhilgupta345
.Dare Devil.
Veteran Member
Join Date: Sep 2010
Old 09-18-2010 , 11:56   Re: [Help]
Reply With Quote #3

No I Dont Want A Black I Want When Zombie Get Frozed He Screen Is Blue Not Black Or My Cvars Options ...
.Dare Devil. is offline
nikhilgupta345
Veteran Member
Join Date: Aug 2009
Location: Virginia
Old 09-18-2010 , 11:59   Re: [Help]
Reply With Quote #4

http://web.njit.edu/~kevin/rgb.txt.html
nikhilgupta345 is offline
Send a message via ICQ to nikhilgupta345 Send a message via Yahoo to nikhilgupta345
.Dare Devil.
Veteran Member
Join Date: Sep 2010
Old 09-18-2010 , 12:45   Re: [Help]
Reply With Quote #5

I Dont Need It , I Know All rgb Color I Need Just If Player Frozed he Screen Blue / Frost Screen But When I Add This Plugin - Player Screen Is Black If He got frozed .
.Dare Devil. is offline
albert123
Veteran Member
Join Date: Mar 2009
Location: VietNam, Hai Phong
Old 09-18-2010 , 12:49   Re: [Help]
Reply With Quote #6

Set color RGB to 0 0 0.. Just try it, i don't sure.
__________________
albert123 is offline
abdul-rehman
Veteran Member
Join Date: Jan 2010
Location: Khi, Pakistan
Old 09-18-2010 , 12:58   Re: [Help]
Reply With Quote #7

Thats a problem bcoz right now there is no proper way in normal ZP to check if player is frozen how ever if you want i can edit this plugin to work properly without that bug butt it would reqiure ZP with new natives
__________________

My Plugins For ZP

Inactive due to College and Studies
abdul-rehman is offline
Send a message via Yahoo to abdul-rehman Send a message via Skype™ to abdul-rehman
.Dare Devil.
Veteran Member
Join Date: Sep 2010
Old 09-18-2010 , 13:56   Re: [Help]
Reply With Quote #8

Quote:
Originally Posted by abdul-rehman View Post
Thats a problem bcoz right now there is no proper way in normal ZP to check if player is frozen how ever if you want i can edit this plugin to work properly without that bug butt it would reqiure ZP with new natives
Please make to work
.Dare Devil. is offline
abdul-rehman
Veteran Member
Join Date: Jan 2010
Location: Khi, Pakistan
Old 09-18-2010 , 14:08   Re: [Help]
Reply With Quote #9

Try this requires ZP new natives:
Code:
#include <amxmodx> #include <hamsandwich> #include <zombieplague> #define TASK_DUCK 2430 #define ID_DUCK (task_id - TASK_DUCK) new cvar_red, cvar_blue, cvar_green, cvar_alpha, g_msgScreenFade public plugin_init() {     register_plugin("[ZP] Addon: CSO Screen Fade", "1.0", "@bdul!")         cvar_red =     register_cvar("zp_fade_red","150")     cvar_green =     register_cvar("zp_fade_green","150")     cvar_blue =     register_cvar("zp_fade_blue","150")     cvar_alpha =    register_cvar("zp_fade_alpha","150")         g_msgScreenFade = get_user_msgid("ScreenFade")         RegisterHam(Ham_Spawn, "player", "fw_PlayerSpawn_Post", 1)     RegisterHam(Ham_Killed, "player", "fw_PlayerKilled") } // User Infected forward public zp_user_infected_post(id, infector, nemesis) {     if (nemesis)     {         remove_task(nemesis+TASK_DUCK)         return     }             // Check if the infected player is using our custom zombie class     if (zp_get_user_zombie(id))         set_task(0.1, "zp_crouch_user", id+TASK_DUCK, _, _, "b")         } public zp_crouch_user(task_id) {     if (!zp_get_user_frozen(ID_DUCK))     {         // Make a screen fade         message_begin(MSG_ONE, g_msgScreenFade, _, ID_DUCK)         write_short((1<<12)*2) // duration         write_short(0) // hold time         write_short(0x0000) // fade type         write_byte(get_pcvar_num(cvar_red)) // red         write_byte(get_pcvar_num(cvar_green)) // green         write_byte(get_pcvar_num(cvar_blue)) // blue         write_byte(get_pcvar_num(cvar_alpha)) // alpha         message_end()     } } // User Humanized forward public zp_user_humanized_post(id, survivor) {     if (survivor)         remove_task(survivor+TASK_DUCK)         remove_task(id+TASK_DUCK) } // Ham Player Spawn Post Forward public fw_PlayerSpawn_Post(id) {     // Checks, checks and checks...how bugged would our servers be without them?     if (zp_get_user_zombie(id))         return;             remove_task(id+TASK_DUCK) } // Ham Player Killed Forward public fw_PlayerKilled(id) {     remove_task(id+TASK_DUCK) }
__________________

My Plugins For ZP

Inactive due to College and Studies
abdul-rehman is offline
Send a message via Yahoo to abdul-rehman Send a message via Skype™ to abdul-rehman
.Dare Devil.
Veteran Member
Join Date: Sep 2010
Old 09-19-2010 , 03:10   Re: [Help]
Reply With Quote #10

Thx
.Dare Devil. is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 01:53.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode