Could use a bit of help...
#1

Ok. So this is what i need to do, and wonder if its possible.

Код:
new LongString[MAX_PLAYER][255]; // Yes i know 255, its a example so shut up xD
if (LongString[playerid]["blabla"] = 1) BAN BAN BAN;
This is just an example. But you should get where im going at. Is this possible with Enums/NormalVars/Something? If not with Vars, maybe PVars?
Reply
#2

Quote:
Originally Posted by DeadAhead
Посмотреть сообщение
Ok. So this is what i need to do, and wonder if its possible.

Код:
new LongString[MAX_PLAYER][255]; // Yes i know 255, its a example so shut up xD
if (LongString[playerid]["blabla"] = 1) BAN BAN BAN;
This is just an example. But you should get where im going at. Is this possible with Enums/NormalVars/Something? If not with Vars, maybe PVars?
Sure it's possible but I think you would need another dimension in your array (or you use smth that ****** released, I think he made some plugin you could use). I'd do it like this:
pawn Код:
new LongString[MAX_PLAYER][255][255]; // Blablabla, adding another dimension, so the string can be stored.
if (strcmp(LongString[playerid][0], "Blabla")==0&&LongString[playerid][somevar which is not 0][somevar]==1) BAN BAN BAN;
Do you understand how I'd do it or do i need to explain it?
Reply
#3

Of course i understand, and thank you. But this was not exactly what i was hoping for. I was hoping for a way to Use Characters as keys instead of Numbers. Like lua has that neat function. But i understand that is not possible. Thanks for the reply anyways :0
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)