Property system bug

Started by Nihongo^, Sep 16, 2018, 01:09 PM

Previous topic - Next topic

Nihongo^

I am trying to add Basic property system  on my script  https://forum.vc-mp.org/?topic=4503.0

but i am getting error here also can you guys explain "typeoff" ?
Thanks for your time guys really appreciate if your help me



!

Use IsNum( arg )
if ( !IsNum( text ) ) return print( "Error >> Expected an integer." );


typeof
It returns the name of type to which the passed argument belongs.

Discord: zeus#5155

Nihongo^

Hi thanka for your kind reply
I am sorry I am noon in scripting just started recently
 I replace it with numtok kindly check the code o think I did it wrong can u correct it if you don't mind

else if( typeof( IsNum( text, " ", 1 ).tointeger() ) != "integer" ) return pMSG( "Error - Usually 'price' means numbers...", player );

!

Quote from: Nihongo^ on Sep 16, 2018, 04:30 PMHi thanka for your kind reply
I am sorry I am noon in scripting just started recently
 I replace it with numtok kindly check the code o think I did it wrong can u correct it if you don't mind

else if( typeof( IsNum( text, " ", 1 ).tointeger() ) != "integer" ) return pMSG( "Error - Usually 'price' means numbers...", player );

Correct
else if( !IsNum( GetTok( text, " ", 1 ) ) ) return pMSG( "Error - Usually 'price' means numbers...", player );

Discord: zeus#5155