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

[TUT] Combos ZP


  
 
 
Thread Tools Display Modes
Sidix
Senior Member
Join Date: Feb 2011
Location: Limbo City
Old 03-19-2013 , 00:10   Re: [TUT] Combos ZP
#31

Quote:
Originally Posted by Caramelo_ZP View Post
PHP Code:
// TASK


// TASK_COMBO en el enum de task

#define ID_COMBO (taskid - TASK_COMBO)

new g_combo[33]

public 
take_damage bla )
{
    
    
g_combo[attacker] += floatround(damage)
    
    
set_hudmessage(255 255 ,  -1.00.606.01.0)
    
show_hudmessage(attacker "[Daño : %d][Total: %d]^n[Combo Numero: %d]" floatround(damage) , g_combo[attacker] , return_combo(attacker))
    
    if(
task_exists(attacker+TASK_COMBO))
        
remove_task(attacker+TASK_COMBO)
    
    
set_task(2.0 "get_combo" attacker+TASK_COMBO)
}

public 
return_combo(id)
{
    new 
0
    
new dm g_combo[id]
    
    while(
dm 250)
    {
        
dm -= 250
        i
++
    }
    
    return 
i
}

public 
get_combo(taskid)
{
    new 
id ID_COMBO
    
new bono 
    
    bono 
= (return_combo(id) * (g_vip[id]+1))
    
zp_colored_print(id "%s Combo:^x04 %d^x01 - Daño Total:^x04 %d^x01 - Bonus:^x04 %d." TAG return_combo(id) , g_combo[id] , bono)
    
g_combo[id] = 0
    update_xp
(id bono)

yo hice esto de 0 y me funciona de 0 y sin usar tantas cosas
Si en verdad eres el autor que hace la variable TAG? ni siquiera está registrada...
__________________
[IMG]http://img839.**************/img839/1879/dmcdanteprofile.png[/IMG]
Sidix is offline
Caramelo_ZP
Member
Join Date: Mar 2013
Old 03-19-2013 , 00:11   Re: [TUT] Combos ZP
#32

#define TAG "ZP NAME" y g_vip es el aceso
__________________
IWannaBeBoy
Champ : Master Yii

Last edited by Caramelo_ZP; 03-19-2013 at 00:13.
Caramelo_ZP is offline
Sidix
Senior Member
Join Date: Feb 2011
Location: Limbo City
Old 03-19-2013 , 00:34   Re: [TUT] Combos ZP
#33

Entiendo, pero creo que le falta algo a ese code ya que le puede tirar bugs por el define "TASK_COMBO"

PHP Code:
remove_task(id+TASK_COMBO
remueve el task al terminar el combo
__________________
[IMG]http://img839.**************/img839/1879/dmcdanteprofile.png[/IMG]

Last edited by Sidix; 03-19-2013 at 00:37.
Sidix is offline
Caramelo_ZP
Member
Join Date: Mar 2013
Old 03-19-2013 , 00:48   Re: [TUT] Combos ZP
#34

en el zp ponen el task_combo , en el enum de los task
__________________
IWannaBeBoy
Champ : Master Yii
Caramelo_ZP is offline
ErKalifa
BANNED
Join Date: Mar 2013
Old 03-19-2013 , 04:55   Re: [TUT] Combos ZP
#35

Quote:
Originally Posted by Caramelo_ZP View Post
PHP Code:
// TASK


// TASK_COMBO en el enum de task

#define ID_COMBO (taskid - TASK_COMBO)

new g_combo[33]

public 
take_damage bla )
{
    
    
g_combo[attacker] += floatround(damage)
    
    
set_hudmessage(255 255 ,  -1.00.606.01.0)
    
show_hudmessage(attacker "[Daño : %d][Total: %d]^n[Combo Numero: %d]" floatround(damage) , g_combo[attacker] , return_combo(attacker))
    
    if(
task_exists(attacker+TASK_COMBO))
        
remove_task(attacker+TASK_COMBO)
    
    
set_task(2.0 "get_combo" attacker+TASK_COMBO)
}

public 
return_combo(id)
{
    new 
0
    
new dm g_combo[id]
    
    while(
dm 250)
    {
        
dm -= 250
        i
++
    }
    
    return 
i
}

public 
get_combo(taskid)
{
    new 
id ID_COMBO
    
new bono 
    
    bono 
= (return_combo(id) * (g_vip[id]+1))
    
zp_colored_print(id "%s Combo:^x04 %d^x01 - Daño Total:^x04 %d^x01 - Bonus:^x04 %d." TAG return_combo(id) , g_combo[id] , bono)
    
g_combo[id] = 0
    update_xp
(id bono)

yo hice esto de 0 y me funciona de 0 y sin usar tantas cosas
Pon todo el code.
ErKalifa 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 05:16.


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