AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   how can i make a Gummi Bears (https://forums.alliedmods.net/showthread.php?t=55926)

Damir 06-02-2007 06:43

how can i make a Gummi Bears
 
How can i make a Gummi Bear mod so you can buy GBJ
and cost 16000$ and gives you 999 HP and 999 AP and makes you 3 times faster that gives you the capability to jump twice as high as normal and you can only use knife when you have it ???

how can I make such a script ? or can you script it to me ?:)

regalis 06-02-2007 08:05

Re: how can i make a Gummi Bears
 
Buy a good text editor and read the pawn tutorials..
Or simply post it here if you are too lazy to read: http://forums.alliedmods.net/forumdisplay.php?f=12

flyeni6 06-02-2007 13:34

Re: how can i make a Gummi Bears
 
here you go :)
PHP Code:

#include <amxmodx>
#include <amxmisc>
#include <fun>
#include <cstrike>
#define PLUGIN "Gummi Bear Mod"
#define VERSION "1.0"
#define AUTHOR "fLyEnI6"
 
new gummybearprice
new gummyhealth
new gummyarmor
 
public plugin_init() 
{
 
register_plugin(PLUGINVERSIONAUTHOR)
 
register_clcmd("say /buygummybear","cmd_gummybear");
 
register_clcmd("say /buygummi","cmd_gummybear");
 
register_clcmd("say /gummy","cmd_gummybear");
 
register_clcmd("say /gummies","cmd_gummybear");
 
 
gummybearprice register_cvar("gm_price","16000")
 
gummyhealth register_cvar("gm_health","999")
 
gummyarmor register_cvar("gm_armor","999")
}
 
public 
cmd_gummybear(id)
{
 if(
cs_get_user_money(id) < get_pcvar_num(gummybearprice))
 {
  
client_print(id,print_chat,"[GBM] Sorry you do not have enough money to buy a gummy bear")
  
client_print(id,print_console,"[GBM] Sorry you do not have enough money to buy a gummy bear")
  return 
PLUGIN_CONTINUE
 
}
 
 else
 {
  
set_user_maxspeed(id,960.0)
  
set_user_health(id,get_pcvar_num(gummyhealth))
  
set_user_armor(id,get_pcvar_num(gummyarmor))
  
set_user_gravity(id,0.5)
  
client_print(id,print_chat,"[GBM] Gummy Bear purchaced! You will now jump higher, run faster, and have more health and armor!")
  
client_print(id,print_console,"[GBM] Gummy Bear purchaced! You will now jump higher, run faster, and have more health and armor!")
 }
 
return 
PLUGIN_CONTINUE




All times are GMT -4. The time now is 10:36.

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