Raised This Month: $ Target: $400
 0% 

set_task [PAWN]


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
bLacK-bLooD
AlliedModders Donor
Join Date: Jun 2008
Old 01-06-2013 , 07:56   set_task [PAWN]
Reply With Quote #1

PHP Code:
   RegisterHamHam_Spawn"player""OnSpawn");

//code

public OnSpawniPlayer 

    if ( 
is_user_aliveiPlayer ) ) 
    { 
            
menu_displayiPlayerg_Menu);
            
set_task(15.0,"smokegren");
    } 
}

//code

public smokegren(iPlayer)
{
    if(
is_user_alive(iPlayer))
    
give_item(iPlayer"weapon_smokegrenade");

This code is supposed to give me a smokegrenade 15 seconds after i spawn. But it doesn't, it doesn't give me a smoke grenade at all.

Why?
bLacK-bLooD is offline
hleV
Veteran Member
Join Date: Mar 2007
Location: Lithuania
Old 01-06-2013 , 08:07   Re: set_task [PAWN]
Reply With Quote #2

Code:
set_task(15.0,"smokegren", iPlayer);
__________________
hleV is offline
bLacK-bLooD
AlliedModders Donor
Join Date: Jun 2008
Old 01-06-2013 , 08:08   Re: set_task [PAWN]
Reply With Quote #3

Damn, stupid mistake

Thanks hleV
bLacK-bLooD 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 13:39.


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