Saveing text in a .cfg file
#3

so i have done and try to make a command for it and i got one error this is my command:
Code:
	if(strcmp(cmd, "/leaveanote", true) == 0)
	{
	    if(IsPlayerConnected(playerid))
	    {
	        if(PlayerInfo[playerid][pAdmin] >= 1337)
			{
				tmp = strtok(cmdtext, idx);
				if(!strlen(tmp))
				{
					SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /leaveanote [Note(TEXT)]");
					return 1;
				}
				new note;
				note = strvalEx(tmp);
				{
					new File:log = fopen("/adminnotes.txt", io_write);
				    fwrite(log, note);// this is line 27006
    				fclose(log);
					format(string, sizeof(string), "   You have left the note %s", note);
					SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
				}
			}
		}
		return 1;
	}
and this is my error:
Code:
C:\Users\Ryan\Desktop\World Wide RolePlay\gamemodes\WWRP.pwn(27006) : error 035: argument type mismatch (argument 2)
Reply


Messages In This Thread
Saveing text in a .cfg file - by yarrum3 - 17.01.2011, 07:47
Re: Saveing text in a .cfg file - by JamesC - 17.01.2011, 08:12
Re: Saveing text in a .cfg file - by yarrum3 - 17.01.2011, 10:10
Re: Saveing text in a .cfg file - by Battleman - 17.01.2011, 10:51
Re: Saveing text in a .cfg file - by yarrum3 - 17.01.2011, 11:06
Re: Saveing text in a .cfg file - by sekol - 17.01.2011, 11:20
Re: Saveing text in a .cfg file - by yarrum3 - 17.01.2011, 11:30

Forum Jump:


Users browsing this thread: 2 Guest(s)