Guest User

Food Stand Filterscript

a guest
Jul 20th, 2016
501
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.72 KB | None | 0 0
  1. //Filterscript created by Milokavis(EinarS)
  2. #include <a_samp>
  3. #include <streamer>
  4.  
  5. #if defined FILTERSCRIPT
  6.  
  7. public OnFilterScriptInit()
  8. {
  9. print("\n--------------------------------------");
  10. print("--Food Stand Filterscript by Milokavis--");
  11. print("--------------------------------------\n");
  12. return 1;
  13. }
  14.  
  15. public OnFilterScriptExit()
  16. {
  17. return 1;
  18. }
  19.  
  20. #else
  21.  
  22. main()
  23. {
  24. print("\n----------------------------------");
  25. print("Food Stand Filterscript by Milokavis");
  26. print("----------------------------------\n");
  27. }
  28.  
  29. #endif
  30.  
  31. public OnGameModeInit()
  32. {
  33. return 1;
  34. }
  35.  
  36. public OnGameModeExit()
  37. {
  38. return 1;
  39. }
  40.  
  41. public OnPlayerRequestClass(playerid, classid)
  42. {
  43. SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);
  44. SetPlayerCameraPos(playerid, 1958.3783, 1343.1572, 15.3746);
  45. SetPlayerCameraLookAt(playerid, 1958.3783, 1343.1572, 15.3746);
  46. return 1;
  47. }
  48.  
  49. public OnPlayerConnect(playerid)
  50. {
  51. CreateDynamicCP(999.9788,-1850.3571,12.8146,1,-1,-1,-1,100.0);
  52. CreateDynamicCP(388.9464,-2072.9277,7.8359,1,-1,-1,-1,100.0);
  53. CreateDynamicCP(377.9103,-1886.7567,7.8359,1,-1,-1,-1,100.0);
  54. CreateDynamicCP(380.9232,-1911.1285,7.8359,1,-1,-1,-1,100.0);
  55. CreateDynamicCP(379.8557,-1922.2986,7.8301,1,-1,-1,-1,100.0);
  56. CreateDynamicCP(359.3307,-2031.9679,7.8359,1,-1,-1,-1,100.0);
  57. return 1;
  58. }
  59.  
  60. public OnPlayerDisconnect(playerid, reason)
  61. {
  62. return 1;
  63. }
  64.  
  65. public OnPlayerSpawn(playerid)
  66. {
  67. return 1;
  68. }
  69.  
  70. public OnPlayerDeath(playerid, killerid, reason)
  71. {
  72. return 1;
  73. }
  74.  
  75. public OnVehicleSpawn(vehicleid)
  76. {
  77. return 1;
  78. }
  79.  
  80. public OnVehicleDeath(vehicleid, killerid)
  81. {
  82. return 1;
  83. }
  84.  
  85. public OnPlayerText(playerid, text[])
  86. {
  87. return 1;
  88. }
  89.  
  90. public OnPlayerCommandText(playerid, cmdtext[])
  91. {
  92. if (strcmp("/Buy food", cmdtext, true, 10) == 0)
  93. {
  94. if (IsPlayerInCheckpoint(playerid))
  95. {
  96. ShowPlayerDialog(playerid, 1, DIALOG_STYLE_LIST, "Food Stand",
  97. "Hotdog\n\
  98. Pizza\n\
  99. Burger",
  100. "Buy", "Cancel");
  101. }
  102. else
  103. {
  104. SendClientMessage(playerid,-1, "SERVER: You are not at a food stand!");
  105. }
  106. return 1;
  107. }
  108. return 1;
  109. }
  110.  
  111. public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
  112. {
  113. if(dialogid == 1)
  114. {
  115. if(response)
  116. {
  117. SendClientMessage(playerid,-1, "SERVER: Enjoy your food!");
  118. GivePlayerMoney(playerid, -100);
  119. SetPlayerHealth(playerid, 100);
  120. }
  121. else
  122. {
  123. SendClientMessage(playerid,-1, "SERVER: See you soon!");
  124. }
  125. return 1;
  126. }
  127. return 0;
  128. }
  129.  
  130. public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
  131. {
  132. DisablePlayerCheckpoint(playerid);
  133. return 1;
  134. }
  135.  
  136. public OnPlayerExitVehicle(playerid, vehicleid)
  137. {
  138. CreateDynamicCP(999.9788,-1850.3571,12.8146,1,-1,-1,-1,100.0);
  139. CreateDynamicCP(388.9464,-2072.9277,7.8359,1,-1,-1,-1,100.0);
  140. CreateDynamicCP(377.9103,-1886.7567,7.8359,1,-1,-1,-1,100.0);
  141. CreateDynamicCP(380.9232,-1911.1285,7.8359,1,-1,-1,-1,100.0);
  142. CreateDynamicCP(379.8557,-1922.2986,7.8301,1,-1,-1,-1,100.0);
  143. CreateDynamicCP(359.3307,-2031.9679,7.8359,1,-1,-1,-1,100.0);
  144. return 1;
  145. }
  146.  
  147. public OnPlayerStateChange(playerid, newstate, oldstate)
  148. {
  149. return 1;
  150. }
  151.  
  152. public OnPlayerEnterDynamicCP(playerid)
  153. {
  154. SendClientMessage(playerid,-1,"SERVER: /buy food to buy food from the food stand");
  155. return 1;
  156. }
  157.  
  158. public OnPlayerLeaveCheckpoint(playerid)
  159. {
  160. return 1;
  161. }
  162.  
  163. public OnPlayerEnterRaceCheckpoint(playerid)
  164. {
  165. return 1;
  166. }
  167.  
  168. public OnPlayerLeaveRaceCheckpoint(playerid)
  169. {
  170. return 1;
  171. }
  172.  
  173. public OnRconCommand(cmd[])
  174. {
  175. return 1;
  176. }
  177.  
  178. public OnPlayerRequestSpawn(playerid)
  179. {
  180. return 1;
  181. }
  182.  
  183. public OnObjectMoved(objectid)
  184. {
  185. return 1;
  186. }
  187.  
  188. public OnPlayerObjectMoved(playerid, objectid)
  189. {
  190. return 1;
  191. }
  192.  
  193. public OnPlayerPickUpPickup(playerid, pickupid)
  194. {
  195. return 1;
  196. }
  197.  
  198. public OnVehicleMod(playerid, vehicleid, componentid)
  199. {
  200. return 1;
  201. }
  202.  
  203. public OnVehiclePaintjob(playerid, vehicleid, paintjobid)
  204. {
  205. return 1;
  206. }
  207.  
  208. public OnVehicleRespray(playerid, vehicleid, color1, color2)
  209. {
  210. return 1;
  211. }
  212.  
  213. public OnPlayerSelectedMenuRow(playerid, row)
  214. {
  215. return 1;
  216. }
  217.  
  218. public OnPlayerExitedMenu(playerid)
  219. {
  220. return 1;
  221. }
  222.  
  223. public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
  224. {
  225. return 1;
  226. }
  227.  
  228. public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
  229. {
  230. return 1;
  231. }
  232.  
  233. public OnRconLoginAttempt(ip[], password[], success)
  234. {
  235. return 1;
  236. }
  237.  
  238. public OnPlayerUpdate(playerid)
  239. {
  240. return 1;
  241. }
  242.  
  243. public OnPlayerStreamIn(playerid, forplayerid)
  244. {
  245. return 1;
  246. }
  247.  
  248. public OnPlayerStreamOut(playerid, forplayerid)
  249. {
  250. return 1;
  251. }
  252.  
  253. public OnVehicleStreamIn(vehicleid, forplayerid)
  254. {
  255. return 1;
  256. }
  257.  
  258. public OnVehicleStreamOut(vehicleid, forplayerid)
  259. {
  260. return 1;
  261. }
  262.  
  263. public OnPlayerClickPlayer(playerid, clickedplayerid, source)
  264. {
  265. return 1;
  266. }
Advertisement
Add Comment
Please, Sign In to add comment