A New PROBLEM!!!!
#1

Hello, i edited this topic because i make very much new topics about stupid question
but here;s a new question too, this is my script and i my pawno compiler crashes when
it compile :
Quote:

public ShowLicenses(playerid);
{
new string[100];
new string1[100];
new string2[100];
new string3[100];
new guide = dini_Int(file, "HasGuide");
new dlic = dini_Int(file, "DriveLic");
new slic = dini_Int(file, "SailLic");
new flic = dini_Int(file, "FlyLic");
new glic = dini_Int(file, "GunLic");

format(string, sizeof(string), "Guide: [%s]", (guide == 1) ? ("Yes") : ("No"));
format(string1, sizeof(string1), "Driving License: [%s]", (dlic == 1) ? ("Yes") : ("No"));
format(string2, sizeof(string2), "Sailing License: [%s]", (slic == 1) ? ("Yes") : ("No"));
format(string3, sizeof(string3), "Weapon License: [%s]", (glic == 1) ? ("Yes") : ("No"));

SendClientMessage(playerid, COLOR_GREEN, "");
SendClientMessage(playerid, COLOR_GREEN, "");
SendClientMessage(playerid, COLOR_GREEN, "");
SendClientMessage(playerid, COLOR_GREEN, "");
SendClientMessage(playerid, COLOR_GREEN, "");
SendClientMessage(playerid, COLOR_GREEN, "");
SendClientMessage(playerid, COLOR_GREEN, "");
SendClientMessage(playerid, COLOR_GREEN, "");
SendClientMessage(playerid, COLOR_GREEN, "");
SendClientMessage(playerid, COLOR_GREEN, "");
SendClientMessage(playerid, COLOR_GREEN, "[====================| Stats Menu |====================]");
SendClientMessage(playerid, COLOR_LGREEN, string);
SendClientMessage(playerid, COLOR_LGREEN, string1);
SendClientMessage(playerid, COLOR_LGREEN, string2);
SendClientMessage(playerid, COLOR_LGREEN, string3);
SendClientMessage(playerid, COLOR_GREEN, "[====================| Stats Menu |====================]");

return 1;
}

Reply
#2

Omg, Dude I've saw you've posted! 2 topics so far..

Will you just learn..
Reply
#3

Don't make another fucking topic, use the same one.
Reply
#4

Код:
SendClientMessage(playerid, COLOR_GREEN, "");
probably because you are sending null strings.
Reply
#5

Quote:
Originally Posted by big comfy couch
Код:
SendClientMessage(playerid, COLOR_GREEN, "");
probably because you are sending null strings.
That's not the problem, i deleted that still crash
Reply
#6

Maybe because:
pawn Код:
format(string2, sizeof(string2), "Guide: [%s] Driving License: [%s] Sailing License: [%s] Flying License: [%s] Weapon License: [%s]",(guide == 1) ? ("Yes") : ("No"), (dlic == 1) ? ("Yes") : ("No"));
Try whitout it does it work?
also you should use %d when there is number and %s when text..

And how about use like:
if(dlic == 1) { LicText = "Passed"; } else { LicText = "None"; }
then add "LicText" there...
also where is sailing, flying, weapon license?
(guide == 1) ? ("Yes") : ("No"), (dlic == 1) ? ("Yes") : ("No") <-- WTF

Script looks wierd
Reply
#7

Bump for the new topic
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)