error 035: argument type mismatch (argument 2)
#1

I have this error: error 035: argument type mismatch (argument 2)

On this line: CreateDynamic3DTextLabel(schildtext,schildtext,wPo s[0], wPos[1], wPos[2],40.0,0,0,1,0,0,-1,100.0);

The hole stock:
Код:
stock CreateSchilder()
{
	new
	    File:schilderFile,
	    Float:wPos[3],
		Line[50],
		schildfarbe[64],
		schildtext[128],
		Float:oPos;

	schilderFile = fopen(SCHILDER_FILE, io_read);
	oPos = wPos[2]-1;
	while(fread(schilderFile, Line))
	{
		sscanf(Line, "p<|>ssfff",schildfarbe,schildtext, wPos[0], wPos[1], wPos[2]);
		CreateDynamicObject(1229, wPos[0], wPos[1], oPos, 0.00000000,0.00000000,0.00000000, 0, 0, -1, 200.0);
		CreateDynamic3DTextLabel(schildtext,schildtext,wPos[0], wPos[1], wPos[2],40.0,0,0,1,0,0,-1,100.0);
	}
	fclose(schilderFile);
}

Please help me D:
Reply
#2

The second argument it a colour, not a string. Put -1 if you don't know what colour you want.
Reply
#3

But i want to save the color as a string, and read it as a string to use it as a color, how does it work?

I save so:
Код:
			CreateDynamicObject(1229, newobjectPos[0], newobjectPos[1], oPos, 0.00000000,0.00000000,0.00000000, 0, 0, -1, 200.0);
			CreateDynamic3DTextLabel(inputtext,COLOR_RED,newobjectPos[0], newobjectPos[1], newobjectPos[2],30.0,0,0,1,0,0,-1,100.0);
			format(schildString, sizeof(schildString), "%s\t|%s\t|%f\t|%f\t|%f\r\n",COLOR_RED,inputtext,newobjectPos[0], newobjectPos[1], newobjectPos[2]);
			schilderDatei = fopen(SCHILDER_FILE, io_append);
			fwrite(schilderDatei, schildString);
			fclose(schilderDatei);
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)