30.04.2014, 13:20
am trying to get system's 64 register login textdrawed fixed but i can't do it.
Main Post release.
https://sampforum.blast.hk/showthread.php?tid=308561
errors listed below
error 010: invalid function or declaration
error 010: invalid function or declaration
Main Post release.
https://sampforum.blast.hk/showthread.php?tid=308561
errors listed below
Код:
(178) : error 017: undefined symbol "defer" (178) : error 017: undefined symbol "RemoveClassSelection" (179) : error 017: undefined symbol "repeat" (179) : error 017: undefined symbol "LoadingScreenTimer" (252) : error 010: invalid function or declaration (258) : error 010: invalid function or declaration (263) : error 010: invalid function or declaration (270) : error 010: invalid function or declaration (270 -- 275) : error 010: invalid function or declaration (270 -- 281) : error 010: invalid function or declaration (270 -- 281) : fatal error 107: too many error messages on one line
Код:
public OnPlayerRequestClass(playerid, classid) { PlayerPlaySound(playerid, 1185, 0, 0, 0); SetPlayerCameraPos(playerid, 1579.94, -1304.85, 122.40); SetPlayerCameraLookAt(playerid, 1577.19, -1309.03, 126.39); TogglePlayerSpectating(playerid, 1); defer RemoveClassSelection(playerid); // <---- this giving error undefined symbol "defer" same with RemoveClassSelection LST[playerid] = repeat LoadingScreenTimer(playerid); // <-- the same with for(new chat = 0; chat <= 30; chat++) { SendClientMessage(playerid, -1, ""); } // Register TD Login. RegisterLoginTD[playerid][0] = TextDrawCreate(330.000000, 170.000000, "Welcome %s~n~~n~Please type your password!"); TextDrawAlignment(RegisterLoginTD[playerid][0], 2); TextDrawBackgroundColor(RegisterLoginTD[playerid][0], 255); TextDrawFont(RegisterLoginTD[playerid][0], 1); TextDrawLetterSize(RegisterLoginTD[playerid][0], 0.500000, 1.000000); TextDrawColor(RegisterLoginTD[playerid][0], -1); TextDrawSetOutline(RegisterLoginTD[playerid][0], 0); TextDrawSetProportional(RegisterLoginTD[playerid][0], 1); TextDrawSetShadow(RegisterLoginTD[playerid][0], 1); RegisterLoginTD[playerid][1] = TextDrawCreate(59.000000, 270.000000, "A B C D E F G H I J K L M N O P R S~n~T U V Z Q W Y X 0 1 2 3 4 5 6 7 8 9"); TextDrawBackgroundColor(RegisterLoginTD[playerid][1], 255); TextDrawFont(RegisterLoginTD[playerid][1], 2); TextDrawLetterSize(RegisterLoginTD[playerid][1], 0.589999, 2.000000); TextDrawColor(RegisterLoginTD[playerid][1], -1); TextDrawSetOutline(RegisterLoginTD[playerid][1], 0); TextDrawSetProportional(RegisterLoginTD[playerid][1], 1); TextDrawSetShadow(RegisterLoginTD[playerid][1], 1); RegisterLoginTD[playerid][2] = TextDrawCreate(313.000000, 248.000000, "LOGIN DELETE"); TextDrawAlignment(RegisterLoginTD[playerid][2], 2); TextDrawBackgroundColor(RegisterLoginTD[playerid][2], 255); TextDrawFont(RegisterLoginTD[playerid][2], 2); TextDrawLetterSize(RegisterLoginTD[playerid][2], 0.500000, 1.000000); TextDrawColor(RegisterLoginTD[playerid][2], -1); TextDrawSetOutline(RegisterLoginTD[playerid][2], 0); TextDrawSetProportional(RegisterLoginTD[playerid][2], 1); TextDrawSetShadow(RegisterLoginTD[playerid][2], 1); RegisterLoginTD[playerid][3] = TextDrawCreate(316.000000, 219.000000, "PASSWORD"); TextDrawAlignment(RegisterLoginTD[playerid][3], 2); TextDrawBackgroundColor(RegisterLoginTD[playerid][4], 255); TextDrawFont(RegisterLoginTD[playerid][3], 2); TextDrawLetterSize(RegisterLoginTD[playerid][3], 0.599999, 2.000000); TextDrawColor(RegisterLoginTD[playerid][3], 11322367); TextDrawSetOutline(RegisterLoginTD[playerid][3], 1); TextDrawSetProportional(RegisterLoginTD[playerid][3], 1); RegisterLoginTD[playerid][4] = TextDrawCreate(240.000000, 100.000000, "Password is incorrect!"); TextDrawBackgroundColor(RegisterLoginTD[playerid][4], 255); TextDrawFont(RegisterLoginTD[playerid][4], 1); TextDrawLetterSize(RegisterLoginTD[playerid][4], 0.500000, 1.000000); TextDrawColor(RegisterLoginTD[playerid][4], -16776961); TextDrawSetOutline(RegisterLoginTD[playerid][4], 0); TextDrawSetProportional(RegisterLoginTD[playerid][4], 1); TextDrawSetShadow(RegisterLoginTD[playerid][4], 1); RegisterLoginTD[playerid][5] = TextDrawCreate(321.000000, 212.000000, "100%~n~~w~Loading..."); TextDrawAlignment(RegisterLoginTD[playerid][5], 2); TextDrawBackgroundColor(RegisterLoginTD[playerid][5], 255); TextDrawFont(RegisterLoginTD[playerid][5], 2); TextDrawLetterSize(RegisterLoginTD[playerid][5], 0.500000, 1.000000); TextDrawColor(RegisterLoginTD[playerid][5], 11322367); TextDrawSetOutline(RegisterLoginTD[playerid][5], 0); TextDrawSetProportional(RegisterLoginTD[playerid][5], 1); TextDrawSetShadow(RegisterLoginTD[playerid][5], 1); TextDrawShowForPlayer(playerid, RegisterLoginTD[playerid][5]); for(new td = 3; td <= 6; td++) { TextDrawShowForPlayer(playerid, RegisterLoginTD2[td]); } return 1; } timer RemoveClassSelection[10](playerid) { SetPlayerCameraPos(playerid, 1579.94, -1304.85, 122.40); SetPlayerCameraLookAt(playerid, 1577.19, -1309.03, 126.39); } timer LoadingScreenTimer[100](playerid) { LoadingPercentage[playerid] ++; format(string, sizeof(string), "%d%%~n~~w~Loading...", LoadingPercentage[playerid]); TextDrawSetString(RegisterLoginTD[playerid][5], string); if(LoadingPercentage[playerid] == 100) { SendClientMessage(playerid, COLOR_YELLOW, "Use keys up-down and right-left and when you select action press F!"); format(string, sizeof(string), "Welcome %s~n~~n~Please type your password!", GetName(playerid)); TextDrawSetString(RegisterLoginTD[playerid][0], string); LoadingPercentage[playerid] = 0; TextDrawHideForPlayer(playerid, RegisterLoginTD[playerid][5]); mysql_format(1, Query, "SELECT * FROM `test_table` WHERE `Name` = '%e'", GetName(playerid)); mysql_query(Query); mysql_store_result(); SelectedCharacter[playerid] = 0; if(mysql_num_rows() == 1) { SendClientMessage(playerid, COLOR_LIME, "You are registered, please type your password!"); CPLK[playerid] = repeat CheckPlayerLoginKeys(playerid); TextDrawSetString(RegisterLoginTD[playerid][2], "LOGIN DELETE"); } else { SendClientMessage(playerid, COLOR_LIME, "You are not registered, please type your new password!"); CPRK[playerid] = repeat CheckPlayerRegisterKeys(playerid); TextDrawSetString(RegisterLoginTD[playerid][2], "REGISTER DELETE"); } TextDrawSetString(RegisterLoginTD[playerid][1], "~b~~h~A ~w~B C D E F G H I J K L M N O P R S~n~T U V Z Q W Y X 0 1 2 3 4 5 6 7 8 9"); for(new td = 0; td <= 2; td++) { TextDrawShowForPlayer(playerid, RegisterLoginTD[playerid][td]); } TextDrawShowForPlayer(playerid, RegisterLoginTD2[0]); TextDrawShowForPlayer(playerid, RegisterLoginTD2[1]); TextDrawShowForPlayer(playerid, RegisterLoginTD2[2]); stop LST[playerid]; } mysql_free_result(); return 1; }
Код:
timer RemoveClassSelection[10](playerid)// <-- error 010: invalid function or declaration { SetPlayerCameraPos(playerid, 1579.94, -1304.85, 122.40); SetPlayerCameraLookAt(playerid, 1577.19, -1309.03, 126.39); }
Код:
timer LoadingScreenTimer[100](playerid) // <-- error 010: invalid function or declaration { LoadingPercentage[playerid] ++; format(string, sizeof(string), "%d%%~n~~w~Loading...", LoadingPercentage[playerid]); TextDrawSetString(RegisterLoginTD[playerid][5], string); if(LoadingPercentage[playerid] == 100) { SendClientMessage(playerid, COLOR_YELLOW, "Use keys up-down and right-left and when you select action press F!"); format(string, sizeof(string), "Welcome %s~n~~n~Please type your password!", GetName(playerid)); TextDrawSetString(RegisterLoginTD[playerid][0], string); LoadingPercentage[playerid] = 0; TextDrawHideForPlayer(playerid, RegisterLoginTD[playerid][5]); mysql_format(1, Query, "SELECT * FROM `test_table` WHERE `Name` = '%e'", GetName(playerid)); // <--- same with this error invalid function or declaration mysql_query(Query); mysql_store_result(); SelectedCharacter[playerid] = 0; if(mysql_num_rows() == 1) { SendClientMessage(playerid, COLOR_LIME, "You are registered, please type your password!"); CPLK[playerid] = repeat CheckPlayerLoginKeys(playerid); TextDrawSetString(RegisterLoginTD[playerid][2], "LOGIN DELETE"); } else { SendClientMessage(playerid, COLOR_LIME, "You are not registered, please type your new password!"); CPRK[playerid] = repeat CheckPlayerRegisterKeys(playerid); TextDrawSetString(RegisterLoginTD[playerid][2], "REGISTER DELETE"); } TextDrawSetString(RegisterLoginTD[playerid][1], "~b~~h~A ~w~B C D E F G H I J K L M N O P R S~n~T U V Z Q W Y X 0 1 2 3 4 5 6 7 8 9"); for(new td = 0; td <= 2; td++) { TextDrawShowForPlayer(playerid, RegisterLoginTD[playerid][td]); } TextDrawShowForPlayer(playerid, RegisterLoginTD2[0]); TextDrawShowForPlayer(playerid, RegisterLoginTD2[1]); TextDrawShowForPlayer(playerid, RegisterLoginTD2[2]); stop LST[playerid]; } mysql_free_result(); return 1; }