Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local SMSG_INIT_WORLD_STATES = 0x2C2
- local SMSG_UPDATE_WORLD_STATE = 0x2C3
- local function Initialize(plr)
- local pack = CreatePacket(SMSG_INIT_WORLD_STATES, 18)
- pack:WriteULong(566) -- Map
- pack:WriteULong(0) -- Zone
- pack:WriteULong(0)
- pack:WriteUShort(1)
- pack:WriteULong(2720) -- ID
- pack:WriteULong(0) -- Value
- pack:WriteULong(2719) -- ID
- pack:WriteULong(0) -- Value
- pack:WriteULong(2718) -- ID
- pack:WriteULong(0) -- Value
- plr:SendPacket(pack)
- end
- local function UpdateState(plr, state, value)
- local pack = CreatePacket(SMSG_UPDATE_WORLD_STATE, 8)
- pack:WriteULong(state)
- pack:WriteULong(value)
- plr:SendPacket(pack)
- end
- local function RunCommand(event, player, cmd)
- if cmd == "kkk" then
- Initialize(player)
- UpdateState(player, 2720, 40)
- UpdateState(player, 2719, 50)
- UpdateState(player, 2718, 1)
- return false
- end
- end
- RegisterPlayerEvent(42, RunCommand)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement