Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --Master Server for phasor 057 for PC (untested) by H® Shaft (doesn't support CE)
- --Changes to the new lobby that the server broadcasts to. Also allows you to change the version.
- default_version = "01.00.10.0621"
- version_address = nil
- Game = nil
- function GetRequiredVersion()
- return 10057
- end
- function OnScriptLoad(process)
- local addr1 = nil
- local addr2 = nil
- addr1 = 0x5c34b4
- addr2 = 0x5c3a08
- version_address = 0x5df840
- -- phasor's writestring functions are ridiculously bugged (lol)
- writestring(addr1, "s1.master.hosthpc.com")
- writestring(addr2, "s1.ms01.hosthpc.com")
- writestring(version_address, default_version)
- end
- function OnServerCommand(player, command)
- t = getcmdtokencount(command)
- count = #t
- if (count == 0) then return nil end
- if t[1] == "sv_version" then
- local processed = false
- if (count == 2) then
- v = t[2]
- if (v == "1.10" or v == "110" or v == "10") then
- writestring(version_address, "01.00.10.0621")
- processed = true
- respond("Broadcasting on version " .. readstring(version_address))
- end
- else
- respond("current version: " .. readstring(version_address))
- respond("valid versions: 110")
- end
- return not processed
- end
- end
- function writestring(addr, str)
- local l = 0
- for i = 1, #str do
- local c = string.byte(str, i)
- writebyte(addr + i - 1, c)
- l = l + 1
- end
- writebyte(addr + l, 0)
- end
- function OnClientUpdate(player, m_objectId) end
- function OnPlayerKill(killer, victim, mode) end
- function OnDamageLookup(receiving_obj, causing_obj, tagdata, tagname) end
- function OnGameEnd(mode) end
- function OnServerChat(player, chattype, message) return 1 end
- function OnPlayerSpawn(player, m_objectId) end
- function OnScriptUnload() end
- function OnNewGame(map) end
- function OnTeamDecision(team) return team end
- function OnPlayerJoin(player, team) end
- function OnPlayerLeave(player, team) end
- function OnKillMultiplier(player, multiplier) end
- function OnPlayerSpawnEnd(player, m_objectId) end
- function OnTeamChange(relevant, player, team, dest_team) return 1 end
- function OnWeaponReload(player, weapon) return 1 end
- function OnVehicleEject(player, forceEject) return 1 end
- function OnWeaponAssignment(player, object, count, tag) end
- function OnObjectCreation(m_objectId, player_owner, tag) end
- function OnVehicleEntry(relevant, player, vehicleId, vehicle_tag, seat) return 1 end
- function OnObjectInteraction(player, m_ObjectId, tagType, tagName) return 1 end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement