[pawn]/*
Filterscript generated using Zamaroht\'s TextDraw Editor Version 1.0.
Designed for SA-MP 0.3a.
Time and Date: 2011-12-16 @ 21:31:36
Instructions:
1- Compile this file using the compiler provided with the sa-mp server package.
2- Copy the .amx file to the filterscripts directory.
3- Add the filterscripts in the server.cfg file (more info here:
http://wiki.sa-mp.com/wiki/Server.cfg)
4- Run the server!
Disclaimer:
You have full rights over this file. You can distribute it, modify it, and
change it as much as you want, without having to give any special credits.
*/
#include <a_samp>
#pragma tabsize 0
new sebesseg[64];
new Float:X,Float:Y,Float:Z;
new kmh;
new Text:Textdraw0;
public OnPlayerUpdate(playerid)
{
GetVehicleVelocity(GetPlayerVehicleID(playerid),X,Y,Z);
kmh = X+Y+Z/ 60;
// Create the textdraws:
format(sebesseg, sizeof(sebesseg),\"Sebesseg: %d kmh\", kmh);
Textdraw0 = TextDrawCreate(576.000000, 428.000000, sebesseg);
}
public OnFilterScriptInit()
{
print(\"Textdraw file generated by\");
print(\" Zamaroht\'s textdraw editor was loaded.\");
TextDrawAlignment(Textdraw0, 3);
TextDrawBackgroundColor(Textdraw0, 255);
TextDrawFont(Textdraw0, 3);
TextDrawLetterSize(Textdraw0, 0.500000, 1.000000);
TextDrawColor(Textdraw0, 16777215);
TextDrawSetOutline(Textdraw0, 1);
TextDrawSetProportional(Textdraw0, 1);
return 1;
}
public OnFilterScriptExit()
{
TextDrawHideForAll(Textdraw0);
TextDrawDestroy(Textdraw0);
return 1;
}
public OnPlayerStateChange(playerid, newstate, oldstate)
{
if(newstate == PLAYER_STATE_DRIVER || newstate == PLAYER_STATE_PASSENGER)
{
TextDrawShowForPlayer(playerid, Textdraw0);
}
else if(oldstate == PLAYER_STATE_DRIVER || oldstate == PLAYER_STATE_PASSENGER)
{
TextDrawHideForPlayer(playerid, Textdraw0);
}
return 1;
}[/pawn]
Most ne azt tessék nézni hogy mennyit fog kiírni, késõbb realizálom:D. Az érdekel hogy miért ír ki warningot?
(30) : warning 213: tag mismatch
[pawn]
kmh = X+Y+Z/ 60;[/pawn]
erre