Is This Code Right?
#1

Is This Code Right
Код:
// This is a comment
// uncomment the line below if you want to write a filterscript
//#define FILTERSCRIPT

#include <a_samp>
new Text:Textdraw0;
new Text:Textdraw1;
new Text:Textdraw2;
new Text:Textdraw3;
new Text:Textdraw4;
new Text:Textdraw5;
new Text:Textdraw6;
new Text:Textdraw7;

#if defined FILTERSCRIPT

public OnFilterScriptInit()
{
   	print(" Textdraw for Server  ");
	print("        By Aryan     ");
	


	Textdraw0 = TextDrawCreate(328.000000, 392.746643, "Dark Eagle Generation");
TextDrawLetterSize(Textdraw0, 0.761999, 3.802667);
TextDrawTextSize(Textdraw0, -700.000000, -563.733520);
TextDrawAlignment(Textdraw0, 2);
TextDrawColor(Textdraw0, 8388863);
TextDrawSetShadow(Textdraw0, 12);
TextDrawSetOutline(Textdraw0, 0);
TextDrawBackgroundColor(Textdraw0, 51);
TextDrawFont(Textdraw0, 0);
TextDrawSetProportional(Textdraw0, 1);

Textdraw1 = TextDrawCreate(0.000000, 378.559967, "LD_SPAC:white");
TextDrawLetterSize(Textdraw1, 0.000000, 0.000000);
TextDrawTextSize(Textdraw1, 640.000000, 91.839996);
TextDrawAlignment(Textdraw1, 1);
TextDrawColor(Textdraw1, 255);
TextDrawSetShadow(Textdraw1, 0);
TextDrawSetOutline(Textdraw1, 0);
TextDrawBackgroundColor(Textdraw1, 255);
TextDrawFont(Textdraw1, 4);

Textdraw2 = TextDrawCreate(0.000000, 0.000000, "LD_SPAC:white");
TextDrawLetterSize(Textdraw2, 0.000000, 0.000000);
TextDrawTextSize(Textdraw2, 640.000000, 120.213340);
TextDrawAlignment(Textdraw2, 1);
TextDrawColor(Textdraw2, 255);
TextDrawSetShadow(Textdraw2, 0);
TextDrawSetOutline(Textdraw2, 0);
TextDrawFont(Textdraw2, 4);

Textdraw3 = TextDrawCreate(0.799999, 97.813331, "LD_SPAC:white");
TextDrawLetterSize(Textdraw3, 0.000000, 0.000000);
TextDrawTextSize(Textdraw3, 639.200012, 20.906661);
TextDrawAlignment(Textdraw3, 1);
TextDrawColor(Textdraw3, 8388863);
TextDrawSetShadow(Textdraw3, 0);
TextDrawSetOutline(Textdraw3, 0);
TextDrawFont(Textdraw3, 4);

Textdraw4 = TextDrawCreate(257.600006, 97.813308, "Welcome......");
TextDrawLetterSize(Textdraw4, 0.449999, 1.600000);
TextDrawAlignment(Textdraw4, 1);
TextDrawColor(Textdraw4, -1);
TextDrawSetShadow(Textdraw4, 0);
TextDrawSetOutline(Textdraw4, 2);
TextDrawBackgroundColor(Textdraw4, 51);
TextDrawFont(Textdraw4, 1);
TextDrawSetProportional(Textdraw4, 1);

Textdraw5 = TextDrawCreate(233.600006, 392.746643, "Dark Eagle Generation");
TextDrawLetterSize(Textdraw5, 0.702000, 3.802665);
TextDrawAlignment(Textdraw5, 1);
TextDrawColor(Textdraw5, -1);
TextDrawSetShadow(Textdraw5, 0);
TextDrawSetOutline(Textdraw5, 1);
TextDrawBackgroundColor(Textdraw5, 51);
TextDrawFont(Textdraw5, 0);
TextDrawSetProportional(Textdraw5, 1);

Textdraw6 = TextDrawCreate(-0.000000, 437.546691, "LD_SPAC:white");
TextDrawLetterSize(Textdraw6, 0.000000, 0.000000);
TextDrawTextSize(Textdraw6, 640.000000, 15.679992);
TextDrawAlignment(Textdraw6, 1);
TextDrawColor(Textdraw6, 8388863);
TextDrawSetShadow(Textdraw6, 0);
TextDrawSetOutline(Textdraw6, 0);
TextDrawFont(Textdraw6, 4);

Textdraw7 = TextDrawCreate(0.799999, 439.786682, "LD_SPAC:white");
TextDrawLetterSize(Textdraw7, 0.000000, 0.000000);
TextDrawTextSize(Textdraw7, 639.200012, 3.733337);
TextDrawAlignment(Textdraw7, 1);
TextDrawColor(Textdraw7, 255);
TextDrawSetShadow(Textdraw7, 0);
TextDrawSetOutline(Textdraw7, 0);
TextDrawFont(Textdraw7, 4);

	return 1;
}

public OnFilterScriptExit()
{
	return 1;
}

#else

main()
{
	print("\n----------------------------------");
	print(" Blank Gamemode by your name here");
	print("----------------------------------\n");
}

#endif

public OnGameModeInit()
{
	
	return 1;
}

public OnGameModeExit()
{
	return 1;
}

public OnPlayerRequestClass(playerid, classid)
{
	
	return 1;
}

public OnPlayerConnect(playerid)
{
    TextDrawShowForPlayer(playerid, Textdraw0);
	TextDrawShowForPlayer(playerid, Textdraw1);
	TextDrawShowForPlayer(playerid, Textdraw2);
	TextDrawShowForPlayer(playerid, Textdraw3);
	TextDrawShowForPlayer(playerid, Textdraw4);
	TextDrawShowForPlayer(playerid, Textdraw5);
	TextDrawShowForPlayer(playerid, Textdraw6);
	TextDrawShowForPlayer(playerid, Textdraw7);
	return 1;
}

public OnPlayerDisconnect(playerid, reason)
{
	return 1;
}

public OnPlayerSpawn(playerid)
{
    TextDrawHideForAll(Textdraw0);
	TextDrawDestroy(Textdraw0);
	TextDrawHideForAll(Textdraw1);
	TextDrawDestroy(Textdraw1);
	TextDrawHideForAll(Textdraw2);
	TextDrawDestroy(Textdraw2);
	TextDrawHideForAll(Textdraw3);
	TextDrawDestroy(Textdraw3);
	TextDrawHideForAll(Textdraw4);
	TextDrawDestroy(Textdraw4);
	TextDrawHideForAll(Textdraw5);
	TextDrawDestroy(Textdraw5);
	TextDrawHideForAll(Textdraw6);
	TextDrawDestroy(Textdraw6);
	TextDrawHideForAll(Textdraw7);
	TextDrawDestroy(Textdraw7);
	return 1;
}

public OnPlayerDeath(playerid, killerid, reason)
{
	return 1;
}

public OnVehicleSpawn(vehicleid)
{
	return 1;
}

public OnVehicleDeath(vehicleid, killerid)
{
	return 1;
}

public OnPlayerText(playerid, text[])
{
	return 1;
}

public OnPlayerCommandText(playerid, cmdtext[])
{
	if (strcmp("/mycommand", cmdtext, true, 10) == 0)
	{
		// Do something here
		return 1;
	}
	return 0;
}

public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
	return 1;
}

public OnPlayerExitVehicle(playerid, vehicleid)
{
	return 1;
}

public OnPlayerStateChange(playerid, newstate, oldstate)
{
	return 1;
}

public OnPlayerEnterCheckpoint(playerid)
{
	return 1;
}

public OnPlayerLeaveCheckpoint(playerid)
{
	return 1;
}

public OnPlayerEnterRaceCheckpoint(playerid)
{
	return 1;
}

public OnPlayerLeaveRaceCheckpoint(playerid)
{
	return 1;
}

public OnRconCommand(cmd[])
{
	return 1;
}

public OnPlayerRequestSpawn(playerid)
{
	return 1;
}

public OnObjectMoved(objectid)
{
	return 1;
}

public OnPlayerObjectMoved(playerid, objectid)
{
	return 1;
}

public OnPlayerPickUpPickup(playerid, pickupid)
{
	return 1;
}

public OnVehicleMod(playerid, vehicleid, componentid)
{
	return 1;
}

public OnVehiclePaintjob(playerid, vehicleid, paintjobid)
{
	return 1;
}

public OnVehicleRespray(playerid, vehicleid, color1, color2)
{
	return 1;
}

public OnPlayerSelectedMenuRow(playerid, row)
{
	return 1;
}

public OnPlayerExitedMenu(playerid)
{
	return 1;
}

public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
{
	return 1;
}

public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
	return 1;
}

public OnRconLoginAttempt(ip[], password[], success)
{
	return 1;
}

public OnPlayerUpdate(playerid)
{
	return 1;
}

public OnPlayerStreamIn(playerid, forplayerid)
{
	return 1;
}

public OnPlayerStreamOut(playerid, forplayerid)
{
	return 1;
}

public OnVehicleStreamIn(vehicleid, forplayerid)
{
	return 1;
}

public OnVehicleStreamOut(vehicleid, forplayerid)
{
	return 1;
}

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
	return 1;
}

public OnPlayerClickPlayer(playerid, clickedplayerid, source)
{
	return 1;
}
Reply
#2

What are you actually trying to do? Just from looking, it looks like you've copied and pasted a default pawno script or something like that, explain a little more.
Reply
#3

Yea, ryt
Reply
#4

Код:
// This is a comment
// uncomment the line below if you want to write a filterscript
//#define FILTERSCRIPT

#include <a_samp>
new Text:Textdraw0;
new Text:Textdraw1;
new Text:Textdraw2;
new Text:Textdraw3;
new Text:Textdraw4;
new Text:Textdraw5;
new Text:Textdraw6;
new Text:Textdraw7;

#if defined FILTERSCRIPT

public OnFilterScriptInit()
{
   	print(" Textdraw for Server  ");
	print("        By Aryan     ");



	Textdraw0 = TextDrawCreate(328.000000, 392.746643, "Dark Eagle Generation");
TextDrawLetterSize(Textdraw0, 0.761999, 3.802667);
TextDrawTextSize(Textdraw0, -700.000000, -563.733520);
TextDrawAlignment(Textdraw0, 2);
TextDrawColor(Textdraw0, 8388863);
TextDrawSetShadow(Textdraw0, 12);
TextDrawSetOutline(Textdraw0, 0);
TextDrawBackgroundColor(Textdraw0, 51);
TextDrawFont(Textdraw0, 0);
TextDrawSetProportional(Textdraw0, 1);

Textdraw1 = TextDrawCreate(0.000000, 378.559967, "LD_SPAC:white");
TextDrawLetterSize(Textdraw1, 0.000000, 0.000000);
TextDrawTextSize(Textdraw1, 640.000000, 91.839996);
TextDrawAlignment(Textdraw1, 1);
TextDrawColor(Textdraw1, 255);
TextDrawSetShadow(Textdraw1, 0);
TextDrawSetOutline(Textdraw1, 0);
TextDrawBackgroundColor(Textdraw1, 255);
TextDrawFont(Textdraw1, 4);

Textdraw2 = TextDrawCreate(0.000000, 0.000000, "LD_SPAC:white");
TextDrawLetterSize(Textdraw2, 0.000000, 0.000000);
TextDrawTextSize(Textdraw2, 640.000000, 120.213340);
TextDrawAlignment(Textdraw2, 1);
TextDrawColor(Textdraw2, 255);
TextDrawSetShadow(Textdraw2, 0);
TextDrawSetOutline(Textdraw2, 0);
TextDrawFont(Textdraw2, 4);

Textdraw3 = TextDrawCreate(0.799999, 97.813331, "LD_SPAC:white");
TextDrawLetterSize(Textdraw3, 0.000000, 0.000000);
TextDrawTextSize(Textdraw3, 639.200012, 20.906661);
TextDrawAlignment(Textdraw3, 1);
TextDrawColor(Textdraw3, 8388863);
TextDrawSetShadow(Textdraw3, 0);
TextDrawSetOutline(Textdraw3, 0);
TextDrawFont(Textdraw3, 4);

Textdraw4 = TextDrawCreate(257.600006, 97.813308, "Welcome......");
TextDrawLetterSize(Textdraw4, 0.449999, 1.600000);
TextDrawAlignment(Textdraw4, 1);
TextDrawColor(Textdraw4, -1);
TextDrawSetShadow(Textdraw4, 0);
TextDrawSetOutline(Textdraw4, 2);
TextDrawBackgroundColor(Textdraw4, 51);
TextDrawFont(Textdraw4, 1);
TextDrawSetProportional(Textdraw4, 1);

Textdraw5 = TextDrawCreate(233.600006, 392.746643, "Dark Eagle Generation");
TextDrawLetterSize(Textdraw5, 0.702000, 3.802665);
TextDrawAlignment(Textdraw5, 1);
TextDrawColor(Textdraw5, -1);
TextDrawSetShadow(Textdraw5, 0);
TextDrawSetOutline(Textdraw5, 1);
TextDrawBackgroundColor(Textdraw5, 51);
TextDrawFont(Textdraw5, 0);
TextDrawSetProportional(Textdraw5, 1);

Textdraw6 = TextDrawCreate(-0.000000, 437.546691, "LD_SPAC:white");
TextDrawLetterSize(Textdraw6, 0.000000, 0.000000);
TextDrawTextSize(Textdraw6, 640.000000, 15.679992);
TextDrawAlignment(Textdraw6, 1);
TextDrawColor(Textdraw6, 8388863);
TextDrawSetShadow(Textdraw6, 0);
TextDrawSetOutline(Textdraw6, 0);
TextDrawFont(Textdraw6, 4);

Textdraw7 = TextDrawCreate(0.799999, 439.786682, "LD_SPAC:white");
TextDrawLetterSize(Textdraw7, 0.000000, 0.000000);
TextDrawTextSize(Textdraw7, 639.200012, 3.733337);
TextDrawAlignment(Textdraw7, 1);
TextDrawColor(Textdraw7, 255);
TextDrawSetShadow(Textdraw7, 0);
TextDrawSetOutline(Textdraw7, 0);
TextDrawFont(Textdraw7, 4);

	return 1;
}

public OnFilterScriptExit()
{
	return 1;
}

#else

main()
{
	print("\n----------------------------------");
	print(" Blank Gamemode by your name here");
	print("----------------------------------\n");
}

#endif

public OnGameModeInit()
{

	return 1;
}

public OnGameModeExit()
{
	return 1;
}

public OnPlayerRequestClass(playerid, classid)
{

	return 1;
}

public OnPlayerConnect(playerid)
{
    TextDrawShowForPlayer(playerid, Textdraw0);
	TextDrawShowForPlayer(playerid, Textdraw1);
	TextDrawShowForPlayer(playerid, Textdraw2);
	TextDrawShowForPlayer(playerid, Textdraw3);
	TextDrawShowForPlayer(playerid, Textdraw4);
	TextDrawShowForPlayer(playerid, Textdraw5);
	TextDrawShowForPlayer(playerid, Textdraw6);
	TextDrawShowForPlayer(playerid, Textdraw7);
	return 1;
}

public OnPlayerDisconnect(playerid, reason)
{
	return 1;
}

public OnPlayerSpawn(playerid)
{
    TextDrawHideForAll(Textdraw0);
	TextDrawDestroy(Textdraw0);
	TextDrawHideForAll(Textdraw1);
	TextDrawDestroy(Textdraw1);
	TextDrawHideForAll(Textdraw2);
	TextDrawDestroy(Textdraw2);
	TextDrawHideForAll(Textdraw3);
	TextDrawDestroy(Textdraw3);
	TextDrawHideForAll(Textdraw4);
	TextDrawDestroy(Textdraw4);
	TextDrawHideForAll(Textdraw5);
	TextDrawDestroy(Textdraw5);
	TextDrawHideForAll(Textdraw6);
	TextDrawDestroy(Textdraw6);
	TextDrawHideForAll(Textdraw7);
	TextDrawDestroy(Textdraw7);
	return 1;
}

public OnPlayerDeath(playerid, killerid, reason)
{
	return 1;
}

public OnVehicleSpawn(vehicleid)
{
	return 1;
}

public OnVehicleDeath(vehicleid, killerid)
{
	return 1;
}

public OnPlayerText(playerid, text[])
{
	return 1;
}

public OnPlayerCommandText(playerid, cmdtext[])
{
	if (strcmp("/mycommand", cmdtext, true, 10) == 0)
	{
		// Do something here
		return 1;
	}
	return 0;
}

public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
	return 1;
}

public OnPlayerExitVehicle(playerid, vehicleid)
{
	return 1;
}

public OnPlayerStateChange(playerid, newstate, oldstate)
{
	return 1;
}

public OnPlayerEnterCheckpoint(playerid)
{
	return 1;
}

public OnPlayerLeaveCheckpoint(playerid)
{
	return 1;
}

public OnPlayerEnterRaceCheckpoint(playerid)
{
	return 1;
}

public OnPlayerLeaveRaceCheckpoint(playerid)
{
	return 1;
}

public OnRconCommand(cmd[])
{
	return 1;
}

public OnPlayerRequestSpawn(playerid)
{
	return 1;
}

public OnObjectMoved(objectid)
{
	return 1;
}

public OnPlayerObjectMoved(playerid, objectid)
{
	return 1;
}

public OnPlayerPickUpPickup(playerid, pickupid)
{
	return 1;
}

public OnVehicleMod(playerid, vehicleid, componentid)
{
	return 1;
}

public OnVehiclePaintjob(playerid, vehicleid, paintjobid)
{
	return 1;
}

public OnVehicleRespray(playerid, vehicleid, color1, color2)
{
	return 1;
}

public OnPlayerSelectedMenuRow(playerid, row)
{
	return 1;
}

public OnPlayerExitedMenu(playerid)
{
	return 1;
}

public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
{
	return 1;
}

public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
	return 1;
}

public OnRconLoginAttempt(ip[], password[], success)
{
	return 1;
}

public OnPlayerUpdate(playerid)
{
	return 1;
}

public OnPlayerStreamIn(playerid, forplayerid)
{
	return 1;
}

public OnPlayerStreamOut(playerid, forplayerid)
{
	return 1;
}

public OnVehicleStreamIn(vehicleid, forplayerid)
{
	return 1;
}

public OnVehicleStreamOut(vehicleid, forplayerid)
{
	return 1;
}

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
	return 1;
}

public OnPlayerClickPlayer(playerid, clickedplayerid, source)
{
	return 1;
}
Yes CODE's are right but I dont understand that what you want to do?
Reply
#5

This the the textdraw script that i am adding in my server i created it so i am thinking that is it right or wrong so i posted it
Reply
#6

eh you can Compile it
Reply
#7

How about you compile it first and then if an error pops up, post a thread?
Reply
#8

I Have complied it but i posted this post becau its not working when i run my server...
Reply
#9

Ohhh! comon this thread is getTin intresting ...(`)_(`)
Reply
#10

What Do u mean?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)