Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <a_samp>
- public OnFilterScriptInit()
- {
- print("\n--------------------------------------");
- print(" Meu Primeiro script Game mode");
- print("--------------------------------------\n");
- return 1;
- }
- main()
- {
- print("tamo dentro");
- return 1;
- }
- public OnGameModeInit()
- {
- // Don't use these lines if it's a filterscript
- SetGameModeText("Blank Script");
- AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
- SetTimer("main", 1000, true);
- return 1;
- }
- public OnPlayerRequestClass(playerid, classid)
- {
- SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);
- SetPlayerCameraPos(playerid, 1958.3783, 1343.1572, 15.3746);
- SetPlayerCameraLookAt(playerid, 1958.3783, 1343.1572, 15.3746);
- return 1;
- }
- public OnPlayerCommandText(playerid, cmdtext[])
- {
- if (strcmp("/mycommand", cmdtext, true, 10) == 0)
- {
- //SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);
- new Float:x, Float:y, Float:z;
- GetPlayerPos(playerid, x, y, z);
- CreateVehicle(503, x+20, y, z, 82.2873, -1, -1, 60);
- return 1;
- }
- if (!strcmp("/velocity", cmdtext))
- {
- new Float:Velocity[3], string[80];
- GetVehicleVelocity(GetPlayerVehicleID(playerid), Velocity[0], Velocity[1], Velocity[2]);
- format(string, sizeof(string), "You are going at a velocity of X: %f, Y: %f, Z: %f", Velocity[0], Velocity[1], Velocity[2]);
- SendClientMessage(playerid, 0xFFFFFFFF, string);
- return 1;
- }
- if (!strcmp("/criar", cmdtext))
- {
- new Float:x, Float:y, Float:z;
- GetPlayerPos(playerid, x, y, z);
- CreateObject(25, x, y, z, 0.0, 0.0, 96.0, 300.0);
- return 1;
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement