PDA

View Full Version : problem... inputtext


Lirbo
17/05/2014, 08:25 PM
if(strval(inputtext) > DOF2_GetInt(pFile(playerid),"Money")) return SendClientMessage(playerid,COLOR_DENIED,"[ERROR] {FF6969}You don't have this ammount of money");

Error 1: error 033: array must be indexed (variable "inputtext")
Error 2: error 033: array must be indexed (variable "inputtext")

Aerotactics
17/05/2014, 08:28 PM
inputtext is a string, in which you need to use strcmp.

If you are trying to ask a player for a numerical input, one way you could do it is with sscanf. That would be the easiest in my opinion.

Lirbo
17/05/2014, 08:39 PM
inputtext is a string, in which you need to use strcmp.

If you are trying to ask a player for a numerical input, one way you could do it is with sscanf. That would be the easiest in my opinion.

example?

Denying
17/05/2014, 08:42 PM
Try storing the value of the money in a variable instead of how you do it.
strval(inputtext) should be working, to be honest.

Lirbo
17/05/2014, 09:15 PM
Try storing the value of the money in a variable instead of how you do it.
strval(inputtext) should be working, to be honest.

not working... i need example...