Advertisement
HR_Shaft

blank script for phasor version 2

Oct 11th, 2013
141
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 5.86 KB | None | 0 0
  1. -- blank script for phasor version 2
  2.  
  3. function GetRequiredVersion()
  4.     return 200
  5. end
  6.  
  7. -- Do not return a value.
  8. function OnScriptLoad(process, game, persistent)
  9.  
  10. end
  11.  
  12. -- Do not return a value.
  13. function OnScriptUnload()
  14.  
  15. end
  16.  
  17. -- Called when a player has changed teams.
  18. -- returns boolean indicating whether or not the player should change teams.
  19. -- Note: relevant is similar to voluntary (1) or involuntary (0). If relevant is 1 the return value is considered, if it's 0 then the return value is ignored.
  20. function OnTeamChange(player, old_team, new_team, relevant)
  21.  
  22.     return nil
  23.  
  24. end
  25.  
  26. -- Called when a server command is being executed.
  27. -- returns boolean indicating whether or not Phasor should process the command.
  28.  function OnServerCommand(player, command)
  29.  
  30.     return nil
  31.    
  32. end
  33.  
  34. -- Called when a player without the correct password is trying to execute a server command.
  35. -- returns boolean indicating whether or not the command can be processed.
  36. function OnServerCommandAttempt(player, command, password)
  37.  
  38.     return nil
  39.  
  40. end
  41.  
  42. -- Called when a new game is starting.
  43. -- Do not return a value.  'map' is the map the game is running.
  44. function OnNewGame(map)
  45.  
  46. end
  47.    
  48.  -- Called when a game is ending.
  49.  -- Do not return a value.
  50. function OnGameEnd(stage)
  51.     -- stages:
  52.     -- 1 The game has just ended, and the ingame score card is shown.
  53.     -- 2 The postgame scorecard is shown.
  54.     -- 3 Players can now leave.
  55.  
  56. end
  57.  
  58. -- Called when a player is attempting to join.
  59. -- returns boolean indicating whether or not the player is allowed to join.
  60. function OnBanCheck(hash, ip)
  61.  
  62.     return nil
  63.  
  64. end
  65.  
  66. -- Called when a client sends its update packet. This function is called 30 times a second for every player in the server.
  67. -- Do not process this event unless you absolutely have to, and when processing it make your code as efficient as possible
  68. -- Do not return a value.
  69. function OnClientUpdate(player)
  70.  
  71. end
  72.  
  73. -- Called when a player successfully joins the game.
  74. -- Do not return a value.
  75. function OnPlayerJoin(player)
  76.  
  77. end
  78.  
  79. -- Called when a player quits.
  80. -- Do not return a value.
  81. function OnPlayerLeave(player)
  82.  
  83. end
  84.  
  85. -- Called when a player needs to be assigned a team.
  86. -- return the team you want the player on, or nil if you don't care.
  87. function OnTeamDecision(team)
  88.  
  89.     return nil
  90.  
  91. end
  92.  
  93. -- Called when a player has spawned.
  94. -- Do not return a value.
  95. function OnPlayerSpawn(player, m_objectId)
  96.  
  97. end
  98.  
  99.  
  100. -- Called when the server has been notified on the player's spawn.
  101. -- Do not return a value.
  102. function OnPlayerSpawnEnd(player, m_objectId)
  103.  
  104. end
  105.  
  106. -- Called when an object has just been created. You can modify most object settings and have it sync.
  107. -- Do not return a value.
  108. function OnObjectCreation(m_objectId)
  109.  
  110. end
  111.  
  112. -- Called when an object wants to be created. You can block it.
  113. -- returns boolean indicating whether or not the object should be created OR map id of object to create instead.
  114. function OnObjectCreationAttempt(mapid, parentid, player)
  115.  
  116.     return nil
  117.    
  118. end
  119.  
  120. -- Called when an object is being assigned their spawn weapons.
  121. -- For this to have any effect the gametype must have starting equipment set to generic.
  122. -- returns the map id as 'weap_id' of the weapon you wish to assign.
  123. function OnWeaponAssignment(player, owner_id, order, weap_id)
  124.  
  125.     -- nil if you don't want to change the assigned weapon.
  126.     -- or the map id of the weapon you wish to assign
  127.     -- or -1 if you don't want the weapon to be assigned.
  128.  
  129.     return nil
  130.    
  131. end
  132.  
  133. -- Called when a player interacts with an object (ie stands on it)
  134. -- returns boolean indicating whether or not to allow the interaction.
  135. function OnObjectInteraction(player, objid, mapid)
  136.  
  137.     return nil
  138.  
  139. end
  140.  
  141. -- Called when the server needs to apply damage to an object.
  142. -- returns boolean indicating whether or not to allow the damage.
  143. function OnDamageLookup(receiver, causer, tagid)
  144.  
  145.     return nil
  146.    
  147. end
  148.  
  149. -- Called when the server is about to apply damage to an object.
  150. -- returns boolean indicating whether or not to allow the damage.
  151. function OnDamageApplication(receiving, causing, tagid, hit, backtap)
  152.     -- return true to allow, false to block
  153.    
  154.     return nil
  155.    
  156. end
  157.  
  158. -- Called when a player chats in the server.
  159. -- returns allow, msg, type.  return true to allow, false to block
  160. function OnServerChat(player, type, msg)
  161.  
  162.     -- type:
  163.     -- 0 All chat
  164.     -- 1 Team chat
  165.     -- 2 Vehicle chat
  166.     -- 3 Server message
  167.     -- 4 Private server message
  168.  
  169.     return nil
  170.    
  171. end
  172.  
  173. -- Called when a player is wanting to enter a vehicle.
  174. -- returns boolean indicating whether or not they should be allowed to enter.
  175. function OnVehicleEntry(player, veh_id, seat, mapid, relevant)
  176.  
  177.     return nil
  178.    
  179. end
  180.  
  181. -- Called when a player is leaving a vehicle.
  182. -- returns boolean indicating whether or not you can stop them leaving
  183. function OnVehicleEject(player, relevant)
  184.    
  185.     return nil
  186.    
  187. end
  188.  
  189. -- Called when a player is killed. Killer can be nil. victim is never nil.
  190. -- Do not return a value.
  191. function OnPlayerKill(killer, victim, mode)
  192.    
  193.     -- modes:
  194.     -- 0 Killed by the server.
  195.     -- 1 Killed by fall damage.
  196.     -- 2 Killed by the guardians.
  197.     -- 3 Killed by a vehicle.
  198.     -- 4 Killed by killer
  199.     -- 5 Betrayed by killer
  200.     -- 6 Suicide
  201.  
  202. end
  203.  
  204. -- Called when a player gets a kill streak.
  205. -- Do not return a value.
  206. function OnKillMultiplier(player, multiplier)
  207.    
  208.     -- Valid multipliers are:
  209.     -- 7 Double kill
  210.     -- 9 Triple kill
  211.     -- 10 Killtacular
  212.     -- 11 Killing spree
  213.     -- 12 Running riot
  214.     -- I think the these happen in Slayer:
  215.     -- 16 Double kill
  216.     -- 15 Triple kill
  217.     -- 14 Killtacular
  218.     -- 18 Killing spree
  219.     -- 17 Running riot
  220.  
  221. end
  222.  
  223. -- Called when a weapon is being reloaded.
  224. -- returns Boolean indicating whether or not they can reload.
  225. function OnWeaponReload(player, objid)
  226.  
  227.     return nil
  228.    
  229. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement