Raised This Month: $ Target: $400
 0% 

Gravity buy error


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
SaM.ThE.MaN
Senior Member
Join Date: Jan 2010
Old 05-08-2010 , 10:20   Gravity buy error
Reply With Quote #1

Hi there ,

I am trying to re-build a plugin that when you type /buy_fly you get 0.35 gravity.

Features:
costs 5000$ (Done)
gravity = 0.35 (Done)
Time set to 10 seconds (Need help)

When even i try to compile it gives me an error:
error 001: expected token: "}", but found "-end of file-"

I can see the error but idk how to fix it,

Quote:
#include <amxmodx>
#include <cstrike>
#include <fun>

#define PLUGIN "Gravity Plugins"
#define VERSION "0.1"
#define AUTHOR "SaMThEMaN"

new plugin_on
new price

public plugin_init()

{
register_plugin(PLUGIN, VERSION, AUTHOR)
register_clcmd("say /Buy_fly", "Gravity")

plugin_on = register_cvar("amx_tutorial_plugin", "1")
price = register_cvar("amx_tutorial_price", "100")

}

public Gravity(id)
{

new money = cs_get_user_money(id)

if (get_pcvar_num(plugin_on) == 1)

{

if (money >= get_pcvar_num(price))
}

{
set_user_health(id, 5000)

set_user_gravity(id,0.35)

client_print(id, print_chat,"You just purchased 300 Gravity with 10,000 $")
}

else
{
client_print(id, print_chat,"Not enough money to purchase Gravity")
}
}
}
SaM.ThE.MaN is offline
Ryokin
Senior Member
Join Date: Jan 2010
Old 05-08-2010 , 10:21   Re: Gravity buy error
Reply With Quote #2

non-steam noob lol

Last edited by Ryokin; 05-08-2010 at 10:24.
Ryokin is offline
SaM.ThE.MaN
Senior Member
Join Date: Jan 2010
Old 05-08-2010 , 10:26   Re: Gravity buy error
Reply With Quote #3

#Fixed
Sorry i fixed it ,
#Request close
SaM.ThE.MaN is offline
SaM.ThE.MaN
Senior Member
Join Date: Jan 2010
Old 05-08-2010 , 12:15   Re: Gravity buy error
Reply With Quote #4

Before closing how to time it, like when i buy 5000 hp and 0.35 gravity , i want it to last for 10 seconds, Am i supposed to use this function : http://www.amxmodx.org/funcwiki.php?go=func&id=1169
SaM.ThE.MaN 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 03:40.


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