Raised This Month: $12 Target: $400
 3% 

Help here please :)


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Shadezz
Senior Member
Join Date: Jul 2009
Location: Denmark
Old 03-14-2010 , 12:55   Help here please :)
Reply With Quote #1

Fixed thanks to Wrecked&fysiks

EDIT; please just trash this again as its fixed.
__________________

Last edited by Shadezz; 03-15-2010 at 02:29.
Shadezz is offline
wrecked_
Veteran Member
Join Date: Jan 2010
Location: New York (GMT-5)
Old 03-14-2010 , 12:58   Re: Help here please :)
Reply With Quote #2

When you declare AddValue, you need to do it like
PHP Code:
new Float:AddValue
// not
new AddValue 
You also need to prefix AddValue with float: in most of those.
__________________
[ Paid Requests ]
DO NOT PM ME ABOUT BLOCKMAKER
NO PRIVATE SUPPORT
wrecked_ is offline
Shadezz
Senior Member
Join Date: Jul 2009
Location: Denmark
Old 03-14-2010 , 13:04   Re: Help here please :)
Reply With Quote #3

then i just get this:

/home/groups/amxmodx/tmp3/phpKW8Ygv.sma(1581) : error 021: symbol already defined: "AddValue"
/home/groups/amxmodx/tmp3/phpKW8Ygv.sma(1581) : error 008: must be a constant expression; assumed zero
/home/groups/amxmodx/tmp3/phpKW8Ygv.sma(1581) : error 036: empty statement
/home/groups/amxmodx/tmp3/phpKW8Ygv.sma(1581) : fatal error 107: too many error messages on one line
__________________
Shadezz is offline
wrecked_
Veteran Member
Join Date: Jan 2010
Location: New York (GMT-5)
Old 03-14-2010 , 13:06   Re: Help here please :)
Reply With Quote #4

No I meant REPLACE your previous declaration with the first option.

You should ONLY have
PHP Code:
new Float:AddValue 
__________________
[ Paid Requests ]
DO NOT PM ME ABOUT BLOCKMAKER
NO PRIVATE SUPPORT
wrecked_ is offline
Hviideren
Junior Member
Join Date: Mar 2009
Location: Denmark
Old 03-14-2010 , 13:13   Re: Help here please :)
Reply With Quote #5

Like this?
PHP Code:
new Float:AddValue[id] = str_to_float(property) + playerMoney[id]; 
__________________
i give +karma if any 1 helps me .
+Karma if i help

Hviideren is offline
wrecked_
Veteran Member
Join Date: Jan 2010
Location: New York (GMT-5)
Old 03-14-2010 , 13:16   Re: Help here please :)
Reply With Quote #6

You'd want to make it
PHP Code:
new Float:AddValue[33]

// or
new Float:AddValue[MAX_PLAYERS+1
and then index the array after.
__________________
[ Paid Requests ]
DO NOT PM ME ABOUT BLOCKMAKER
NO PRIVATE SUPPORT
wrecked_ is offline
Hviideren
Junior Member
Join Date: Mar 2009
Location: Denmark
Old 03-14-2010 , 13:31   Re: Help here please :)
Reply With Quote #7

I dont know what you mean
__________________
i give +karma if any 1 helps me .
+Karma if i help

Hviideren is offline
Shadezz
Senior Member
Join Date: Jul 2009
Location: Denmark
Old 03-14-2010 , 13:33   Re: Help here please :)
Reply With Quote #8

i srsly have no idea what u mean XD could u post how its supposed to be standing? like right now i tried with:
new Float:AddValue[MAX_PLAYERS+1] = str_to_float(property) + playerMoney[id];

i srsly dont know what u mean :/
__________________
Shadezz is offline
wrecked_
Veteran Member
Join Date: Jan 2010
Location: New York (GMT-5)
Old 03-14-2010 , 13:35   Re: Help here please :)
Reply With Quote #9

PHP Code:
new Float:AddValue[33]
Float:AddValue[id] = str_to_float(property) + playerMoney[id]; 
__________________
[ Paid Requests ]
DO NOT PM ME ABOUT BLOCKMAKER
NO PRIVATE SUPPORT
wrecked_ is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 03-14-2010 , 13:37   Re: Help here please :)
Reply With Quote #10

Wow, this is sad.

Find the line in your code like this:

PHP Code:
new AddValue[33
then change it to:

PHP Code:
new Float:AddValue[33
Similarly with g_money_used[33] you probably need to add bool:

Quote:
Originally Posted by wrecked_ View Post
PHP Code:
new Float:AddValue[33]
Float:AddValue[id] = str_to_float(property) + playerMoney[id]; 
You shouldn't need to retag the variable AddValue

Oh, and playerMoney should be a Float also.
__________________

Last edited by fysiks; 03-14-2010 at 13:40.
fysiks 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 18:45.


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