Raised This Month: $ Target: $400
 0% 

Drops 0 level gun,appears new 1level gun


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
xbatista
Veteran Member
Join Date: Mar 2008
Location: Lithuania
Old 09-21-2008 , 06:57   Drops 0 level gun,appears new 1level gun
Reply With Quote #1

I need code that will drop 0 Level gun and gives you new level 1 gun(on this round!!!And immidiatly,when gain ;)):
if(PlayerLevel[id]==0)
set_task(0.4,"glock",id)
if(PlayerLevel[id]==1)
set_task(0.4,"usp",id)


public glock(id)
{
give_item(id,"weapon_glock18");
give_item(id,"ammo_9mm");
give_item(id,"ammo_9mm");
give_item(id,"ammo_9mm");
give_item(id,"ammo_9mm");
give_item(id,"ammo_9mm");
give_item(id,"ammo_9mm");
give_item(id,"ammo_9mm");
}
public usp(id)
{
give_item(id,"weapon_usp");
give_item(id,"ammo_45acp");
give_item(id,"ammo_45acp");
give_item(id,"ammo_45acp");
give_item(id,"ammo_45acp");
give_item(id,"ammo_45acp");
give_item(id,"ammo_45acp");
give_item(id,"ammo_45acp");
give_item(id,"ammo_45acp");
give_item(id,"ammo_45acp");
give_item(id,"weapon_smokegrenade");
}

Last edited by xbatista; 09-21-2008 at 07:37.
xbatista is offline
Send a message via Skype™ to xbatista
hleV
Veteran Member
Join Date: Mar 2007
Location: Lithuania
Old 09-21-2008 , 07:12   Re: Drops 0 level gun,appears new 1level gun
Reply With Quote #2

PHP Code:
public usp()
{
        
engclient_cmd(id"drop""weapon_glock")
 
        
// USP code 
__________________
hleV is offline
xbatista
Veteran Member
Join Date: Mar 2008
Location: Lithuania
Old 09-21-2008 , 07:22   Re: Drops 0 level gun,appears new 1level gun
Reply With Quote #3

OK
And wait think I will have a bug ,ok i'm going to test
xbatista is offline
Send a message via Skype™ to xbatista
xbatista
Veteran Member
Join Date: Mar 2008
Location: Lithuania
Old 09-21-2008 , 07:26   Re: Drops 0 level gun,appears new 1level gun
Reply With Quote #4

Yep it is.
This is code no weapon drop that you was given to me a lot of months ago
register_clcmd("drop", "cmdDrop")
public cmdDrop()
return PLUGIN_HANDLED


How to fix it?
1.I wanna just drop level 0 gun and appear level 1 gun,but I still whant no weapon drop.
2.And I need IMMIDIATLY GIVE new level gun, not wait a round start.!


Sorry ,bad english.


P.S. This is when you gain level:
if(PlayerXp[id] >= LEVELS[PlayerLevel[id]])
{
PlayerLevel[id] += 1
PlayerPoints[id] += 1
client_cmd(id, "spk %s", LevelUpSound)
}

Last edited by xbatista; 09-21-2008 at 07:38.
xbatista is offline
Send a message via Skype™ to xbatista
xbatista
Veteran Member
Join Date: Mar 2008
Location: Lithuania
Old 09-21-2008 , 08:44   Re: Drops 0 level gun,appears new 1level gun
Reply With Quote #5

ummmmm.... Someone?
xbatista is offline
Send a message via Skype™ to xbatista
hleV
Veteran Member
Join Date: Mar 2007
Location: Lithuania
Old 09-21-2008 , 09:34   Re: Drops 0 level gun,appears new 1level gun
Reply With Quote #6

Why do you use No Weapon Drop?
__________________
hleV is offline
xbatista
Veteran Member
Join Date: Mar 2008
Location: Lithuania
Old 09-21-2008 , 10:43   Re: Drops 0 level gun,appears new 1level gun
Reply With Quote #7

I have an idea, I am making one Mod And now i need this:
Quote:
1.I wanna just drop level 0 gun and appear level 1 gun,but I still whant no weapon drop.
2.And I need IMMIDIATLY GIVE new level gun, not wait a round start.!
if(PlayerLevel[id]==0)
set_task(0.4,"glock",id)
if(PlayerLevel[id]==1)
set_task(0.4,"usp",id)


public glock(id)
{
give_item(id,"weapon_glock18");
give_item(id,"ammo_9mm");
give_item(id,"ammo_9mm");
give_item(id,"ammo_9mm");
give_item(id,"ammo_9mm");
give_item(id,"ammo_9mm");
give_item(id,"ammo_9mm");
give_item(id,"ammo_9mm");
}
public usp(id)
{
give_item(id,"weapon_usp");
give_item(id,"ammo_45acp");
give_item(id,"ammo_45acp");
give_item(id,"ammo_45acp");
give_item(id,"ammo_45acp");
give_item(id,"ammo_45acp");
give_item(id,"ammo_45acp");
give_item(id,"ammo_45acp");
give_item(id,"ammo_45acp");
give_item(id,"ammo_45acp");
give_item(id,"weapon_smokegrenade");
}


P.S. This is when you gain level:
if(PlayerXp[id] >= LEVELS[PlayerLevel[id]])
{
PlayerLevel[id] += 1 //level gained
PlayerPoints[id] += 1 //points gained
client_cmd(id, "spk %s", LevelUpSound)
}

Last edited by xbatista; 09-21-2008 at 10:47.
xbatista is offline
Send a message via Skype™ to xbatista
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 16:13.


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