FS variable conflict
#1

I am trying to use a fs on my server, it works perfectly when i use it with grandlrc but when i try to use it with my gm, It just stops working. Through debbugging i found that this line is causing the problem i even changed the variables but it didn't solve the problem.

Код:
F_ObjectInfo[fr_preview[playerid]][fr_id] = fr_preview[playerid];
It just dies on this line......
Reply
#2

Wrong section.

But the variable is incorrect, if you created the variable like that it should've given you errors during compilation.


F_ObjectInfo[fr_preview[playerid]][fr_id] = fr_preview[playerid];

You can never use an opening bracket twice like that in a variable., always close it before opening another one.

pawn Код:
// If your variable is created like this (changing MAX_...  to whatever number you defined)
new F_ObjectInfo[MAX_fr_preview][MAX_PLAYERS][MAX_fr_id]

//Than this is the correct way of doing it, although it confuses me a bit since you didn't provide the belonging code, and might not actally work. But you can never put two [[ or ]], or [something[ etc...
F_ObjectInfo[fr_preview][playerid][fr_id] = fr_preview[playerid];
Reply
#3

Nope its like that

Код:
new F_ObjectInfo[MAX_fr_preview][MAX_fr_id]
new fr_preview[MAX_PLAYERS]
than this
Код:
F_ObjectInfo[fr_preview[playerid]][fr_id] = fr_preview[playerid];
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)