Advertisement
HeidiStone1

Plain firework

Apr 24th, 2018
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.53 KB | None | 0 0
  1. ╭╮╱╭╮╱╱╱╱╱╭╮╱╭━━━╮╭╮
  2. ┃┃╱┃┃╱╱╱╱╱┃┃╱┃╭━╮┣╯╰╮
  3. ┃╰━╯┣━━┳┳━╯┣╮┃╰━━╋╮╭╋━━┳━╮╭━━╮
  4. ┃╭━╮┃┃━╋┫╭╮┣┫╰━━╮┃┃┃┃╭╮┃╭╮┫┃━┫
  5. ┃┃╱┃┃┃━┫┃╰╯┃┃┃╰━╯┃┃╰┫╰╯┃┃┃┃┃━┫
  6. ╰╯╱╰┻━━┻┻━━┻╯╰━━━╯╰━┻━━┻╯╰┻━━╯
  7. ╭━━━╮╱╱╱╱╱╱╭╮╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╭╮╭╮╭╮
  8. ╰╮╭╮┃╱╱╱╱╭┳╯╰╮╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱┃┣╯╰┫┃
  9. ╱┃┃┃┣━━┳━┫┣╮╭╯╭━┳━━┳╮╭┳━━┳╮╭┳━━╮╭━━┳━┳━━┳━╯┣╮╭┫┃
  10. ╱┃┃┃┃╭╮┃╭╋┫┃┃╱┃╭┫┃━┫╰╯┃╭╮┃╰╯┃┃━┫┃╭━┫╭┫┃━┫╭╮┣┫┃╰╯
  11. ╭╯╰╯┃╰╯┃┃┃┃┃╰╮┃┃┃┃━┫┃┃┃╰╯┣╮╭┫┃━┫┃╰━┫┃┃┃━┫╰╯┃┃╰┳╮
  12. ╰━━━┻━━┻╯╰╯╰━╯╰╯╰━━┻┻┻┻━━╯╰╯╰━━╯╰━━┻╯╰━━┻━━┻┻━┻╯
  13.  
  14.  
  15. // Usage: /heidifire //
  16.  
  17. #define FILTERSCRIPT
  18. #include <a_samp>
  19. new firework;
  20. public OnFilterScriptInit()
  21. {
  22. print("Firework script by Heidi Stone loaded.");
  23. return 1;
  24. }
  25.  
  26. public OnFilterScriptExit()
  27. {
  28. return 1;
  29. }
  30. public OnPlayerCommandText(playerid, cmdtext[])
  31. {
  32. if (strcmp("/heidifire", cmdtext, true, 9) == 0)
  33. {
  34. if(!IsPlayerInAnyVehicle(playerid))
  35. {
  36. if(!IsObjectMoving(firework))
  37. {
  38. new Float:pX, Float:pY, Float:pZ;
  39. GetPlayerPos(playerid, pX, pY, pZ);
  40. firework = CreateObject(2918, pX, pY, pZ, 0.0, 0.0, 100.0);
  41. MoveObject(firework, pX, pY + 16, pZ + 50, 25.0);
  42. }
  43. else
  44. {
  45. SendClientMessage(playerid, -1, "{FF0000}** Please wait until your other firework is done, d00d **");
  46. }
  47. }
  48. else
  49. {
  50. SendClientMessage(playerid, -1, "{FF0000}** You can't launch firework from your car, nigga. Like srsly?**");
  51. }
  52. return 1;
  53. }
  54. return 0;
  55. }
  56. public OnObjectMoved(objectid)
  57. {
  58. if(objectid == firework)
  59. {
  60. new Float:obX, Float:obY, Float:obZ;
  61. GetObjectPos(objectid, obX, obY, obZ);
  62. DestroyObject(firework);
  63. CreateExplosion(obX, obY, obZ, 0, 15.0);
  64. }
  65. return 1;
  66. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement