Raised This Month: $ Target: $400
 0% 

set_task parameters


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Excalibur.007
Veteran Member
Join Date: Sep 2009
Location: Singapore
Old 12-02-2011 , 09:25   set_task parameters
Reply With Quote #1

Is this the correct way of doing this? This is my first time using the parameters in set_task. Searched for help but none of them has help out. Correct my codes. Thanks in advance.

PHP Code:
#define TASK_ONE    574397

public function1(victimattacker)
{
    new 
args[1]
    
    
args[0] = attacker
    
    set_task
(10.0"function2"player+TASK_ONEargs1)
}

public 
function2(taskidargs[])
{
    static 
player
    player 
= (taskid TASK_ONE)
    
    new 
attacker args[0]

or this

PHP Code:
#define TASK_ONE    574397

public function1(victimattacker)
{
    new 
args[2]
    
    
args[0] = victim
    args
[1] = attacker
    
    set_task
(10.0"function2"TASK_ONEargs2)
}

public 
function2(args[])
{
    new 
victim args[0]
    new 
attacker args[1]

Most likely the 2nd one works but I want to use remove_task on ONLY ONE player.
Excalibur.007 is offline
 


Thread Tools
Display Modes

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 08:28.


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