Raised This Month: $51 Target: $400
 12% 

[ZP] Nuevo Modo


  
 
 
Thread Tools Display Modes
Author Message
aguchox
Member
Join Date: Aug 2010
Old 06-14-2011 , 23:27   [ZP] Nuevo Modo
#1

Hola, quisiera saber como hago este modo, estoy probando y no me salio todabia, el modo que quiero es que todo los modos esten dentro de uno, osea que este en 1 modo salga ej: al azar, si somo x player 3 neme,3 survi,3 ninja, 3 wesker, asi los modos que tengo yo, y renascan al azar, yo probé usando el de modo multi pero nu me salio les dejo mi code x las dudas y si me ayudan mejor
PHP Code:
else if ((mode == MODE_NONE && (!preventconsecutive || g_lastmode != MODE_FUN) && random_num(1get_pcvar_num(cvar_funchance)) == get_pcvar_num(cvar_fun) && floatround(iPlayersnum*get_pcvar_float(cvar_funratio), floatround_ceil) >= && floatround(iPlayersnum*get_pcvar_float(cvar_funratio), floatround_ceil) < iPlayersnum && iPlayersnum >= get_pcvar_num(cvar_funminplayers)) || mode == MODE_FUN)
    {
        
// Multi Infection Mode
        
g_lastmode MODE_FUN
              g_funround 
true
        g_ninja
[id] = false
        g_nemesis
[id] = false
        g_survivor
[id] = false
        g_wesker
[id] = false
        
        
        
// iMaxZombies is rounded up, in case there aren't enough players
        
iMaxZombies floatround(iPlayersnum*get_pcvar_float(cvar_funratio), floatround_ceil)
        
iZombies 0
        
        
// Randomly turn iMaxZombies players into zombies
        
while (iZombies iMaxZombies)
        {
            
// Keep looping through all players
            
if (++id g_maxplayersid 1
            
            
// Dead or already a zombie
            
if (!is_user_alive(id) || g_zombie[id] || !g_zombie[id] || g_survivor[id] || g_ninja[id] || g_wesker[id])
                continue;
            
            
// Random chance
            
if (random_num(01))
            {
                
// Turn into a zombie
                
zombieme(id001)
                
g_nemesis[id] = true
                iZombies
++
             

                
humanme(id1)
                
g_ninja[id] = true
                g_survivor
[id] = true
                        g_wesker
[id] = true
                  
}
        }

        
        
// Turn the remaining players into humans
        
for (id 1id <= g_maxplayersid++)
        {
            
// Only those of them who aren't zombies
            
if (!is_user_alive(id) || g_zombie[id])
                continue
            
            
// Remove previous tasks
            
remove_task(id+TASK_TEAM)
            
            
// Switch to CT
            
if (fm_get_user_team(id) != CS_TEAM_CT// need to change team?
            
{
                
fm_set_user_team(idCS_TEAM_CT)
                
fm_user_team_update(id)
            }
        }
        new 
red random_num(10,255)
    new 
gren random_num(10,255)
    new 
blue random_num(10,255)
        
        
// Show wesker HUD notice
        
set_hudmessage(redbluegrenHUD_EVENT_XHUD_EVENT_Y10.05.01.01.0, -1)
        
ShowSyncHudMsg(0g_MsgSync"MODO FUN!!")
        
        
        
// Round start forward
        
ExecuteForward(g_fwRoundStartg_fwDummyResultMODE_FUN0);
    } 
Compila todo bien, pero cuando lanzo el modo no sale nada y se me cierra el cs
aguchox is offline
Sambuseti
Member
Join Date: Jun 2011
Location: Chile
Old 06-15-2011 , 13:55   Re: [ZP] Nuevo Modo
#2

YO HE COPIADO EL MOD L4D Y LE MODIFIQUE LOS PLAYERS QUE KERIA KE SALGAN EJ:
PHP Code:
else if ((mode == MODE_NONE && (!preventconsecutive || g_lastmode != MODE_FUN) && random_num(1get_pcvar_num(cvar_funchance)) == get_pcvar_num(cvar_fun) && floatround((iPlayersnum-2)*get_pcvar_float(cvar_funratio), floatround_ceil) >= && iPlayersnum >= get_pcvar_num(cvar_funminplayers)) || mode == MODE_FUN

//Modo L4D 
g_funround true
g_swarmround 
true 

// Todos Los Players Restantes Se Comvierten Nemesis
for (id 1id <= g_maxplayersid++) 

// si no esta vivo 
if (!is_user_alive(id)) 
continue; 

// si es un zombie 
if (g_zombie[id]) 
continue; 

// Convertir en zombie 
zombieme(id010


// Convertir 4 de los zombies en Humanos 
id fnGetRandomAlive(random_num(1iPlayersnum))
// Tu Ninja
g_ninja[id] = true 
humanme
(id1)
fm_set_user_health(id400)
fm_strip_user_weapons(id)
fm_give_item(id"weapon_knife")
id fnGetRandomAlive(random_num(1iPlayersnum)) 
if (
g_zombie[id]) 

// Tu Survivor
g_survivor[id] = true 
humanme
(id1)
fm_set_user_health(id400)
fm_strip_user_weapons(id)
fm_give_item(id"weapon_knife")
fm_give_item(id"weapon_m3")
fm_give_item(id"weapon_deagle"
}  

id fnGetRandomAlive(random_num(1iPlayersnum)) 
if (
g_zombie[id]) 

// Tu Wesker Si Tenes
g_wesker[id] = true
humanme
(id1)
fm_set_user_health(id400)
fm_strip_user_weapons(id)
fm_give_item(id"weapon_deagle"


id fnGetRandomAlive(random_num(1iPlayersnum)) 
if (
g_zombie[id]) 

// Tu Raptor
g_raptor[id] = true
humanme
(id1)
fm_set_user_health(id400)
fm_strip_user_weapons(id)
fm_give_item(id"weapon_knife")
fm_give_item(id"weapon_mp5navy")
fm_give_item(id"weapon_deagle"
}

PlaySound(sound_plague[random_num(0sizeof sound_plague -1)]); 

// Mostramos la noticia del modo en un HuD 
set_hudmessage(050200, -1.00.1710.05.01.01.0, -1
ShowSyncHudMsg(0g_MsgSync"%L"LANG_PLAYER"NOTICE_FUN"

ExecuteForward(g_fwRoundStartg_fwDummyResultMODE_FUN0); 

Espero Que Te Sirva Si Esta Mal Algo Avisen
Sambuseti is offline
Send a message via MSN to Sambuseti Send a message via Skype™ to Sambuseti
stickcs
Senior Member
Join Date: Jan 2011
Old 06-17-2011 , 21:41   Re: [ZP] Nuevo Modo
#3

Quote:
Originally Posted by Sambuseti View Post
YO HE COPIADO EL MOD L4D Y LE MODIFIQUE LOS PLAYERS QUE KERIA KE SALGAN EJ:
PHP Code:
else if ((mode == MODE_NONE && (!preventconsecutive || g_lastmode != MODE_FUN) && random_num(1get_pcvar_num(cvar_funchance)) == get_pcvar_num(cvar_fun) && floatround((iPlayersnum-2)*get_pcvar_float(cvar_funratio), floatround_ceil) >= && iPlayersnum >= get_pcvar_num(cvar_funminplayers)) || mode == MODE_FUN

//Modo L4D 
g_funround true
g_swarmround 
true 

// Todos Los Players Restantes Se Comvierten Nemesis
for (id 1id <= g_maxplayersid++) 

// si no esta vivo 
if (!is_user_alive(id)) 
continue; 

// si es un zombie 
if (g_zombie[id]) 
continue; 

// Convertir en zombie 
zombieme(id010


// Convertir 4 de los zombies en Humanos 
id fnGetRandomAlive(random_num(1iPlayersnum))
// Tu Ninja
g_ninja[id] = true 
humanme
(id1)
fm_set_user_health(id400)
fm_strip_user_weapons(id)
fm_give_item(id"weapon_knife")
id fnGetRandomAlive(random_num(1iPlayersnum)) 
if (
g_zombie[id]) 

// Tu Survivor
g_survivor[id] = true 
humanme
(id1)
fm_set_user_health(id400)
fm_strip_user_weapons(id)
fm_give_item(id"weapon_knife")
fm_give_item(id"weapon_m3")
fm_give_item(id"weapon_deagle"
}  

id fnGetRandomAlive(random_num(1iPlayersnum)) 
if (
g_zombie[id]) 

// Tu Wesker Si Tenes
g_wesker[id] = true
humanme
(id1)
fm_set_user_health(id400)
fm_strip_user_weapons(id)
fm_give_item(id"weapon_deagle"


id fnGetRandomAlive(random_num(1iPlayersnum)) 
if (
g_zombie[id]) 

// Tu Raptor
g_raptor[id] = true
humanme
(id1)
fm_set_user_health(id400)
fm_strip_user_weapons(id)
fm_give_item(id"weapon_knife")
fm_give_item(id"weapon_mp5navy")
fm_give_item(id"weapon_deagle"
}

PlaySound(sound_plague[random_num(0sizeof sound_plague -1)]); 

// Mostramos la noticia del modo en un HuD 
set_hudmessage(050200, -1.00.1710.05.01.01.0, -1
ShowSyncHudMsg(0g_MsgSync"%L"LANG_PLAYER"NOTICE_FUN"

ExecuteForward(g_fwRoundStartg_fwDummyResultMODE_FUN0); 

Espero Que Te Sirva Si Esta Mal Algo Avisen
Yo editaria eso a lo siguiente:
PHP Code:
else if ((mode == MODE_NONE && (!preventconsecutive || g_lastmode != MODE_FUN) && random_num(1get_pcvar_num(cvar_funchance)) == get_pcvar_num(cvar_fun) && floatround((iPlayersnum-2)*get_pcvar_float(cvar_funratio), floatround_ceil) >= && iPlayersnum >= get_pcvar_num(cvar_funminplayers)) || mode == MODE_FUN

//Modo L4D 
g_funround true
g_swarmround 
true 

// Todos Los Players Restantes Se Comvierten Nemesis
for (id 1id <= g_maxplayersid++) 

// si no esta vivo 
if (!is_user_alive(id)) 
continue; 

// si es un zombie 
if (g_zombie[id]) 
continue; 

// Convertir en zombie 
zombieme(id010


// Todos Los Players Restantes Se Comvierten Nemesis
for (id 1id <= 4id++) 

                        switch(
random_num(1,4))
            {
                case 
humanme(id1//Survivor
                
case humanme(id01//Ninja
                
case humanme(id001//Wesker
                
case humanme(id0001//Raptor
            
}


PlaySound(sound_plague[random_num(0sizeof sound_plague -1)]); 

// Mostramos la noticia del modo en un HuD 
set_hudmessage(050200, -1.00.1710.05.01.01.0, -1
ShowSyncHudMsg(0g_MsgSync"%L"LANG_PLAYER"NOTICE_FUN"

ExecuteForward(g_fwRoundStartg_fwDummyResultMODE_FUN0); 

Luego iria a: humanme(id, survivor) (si mal no recuerdo)
y editaria eso por:
PHP Code:
humanme(idsurvivorninja 0wesker 0raptor 0
Luego agregaria abajo los siguientes elseif (el siguiente codigo si no entienden mucho)
PHP Code:
else if(ninja)
{
      
g_ninja[id] = true 
      fm_set_user_health
(id400)
      
fm_strip_user_weapons(id)
      
fm_give_item(id"weapon_knife")
}
else if(
wesker)
{
      
g_wesker[id] = true
      fm_set_user_health
(id400)
      
fm_strip_user_weapons(id)
      
fm_give_item(id"weapon_deagle"
}
else if(
raptor)
{
      
g_raptor[id] = true
     fm_set_user_health
(id400)
     
fm_strip_user_weapons(id)
     
fm_give_item(id"weapon_knife")
     
fm_give_item(id"weapon_mp5navy")
     
fm_give_item(id"weapon_deagle"

Creditos: a kiske q me dio la recomendacion hace un tiempo ya largo

asi podras usar ese codigo en cualquier modo al humanme
stickcs is offline
 



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 18:57.


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