View Full Version : SetPvP(True) having a problem

Lightning Blade
11-04-2013, 12:33 PM

This is my script, whenever i use the teleporter it prints this in the console " Attempt to call globa 'SetPvP' < nil value > " don't mind the SetFFA thingy.

11-04-2013, 12:35 PM
It's not a global, it has to be called on an object, in this case the player.


Replace yours with that

Lightning Blade
11-04-2013, 12:39 PM
You are such a cutiepie <3

- - - Updated - - -

One last question, When i try to set the ffa to true, it works. But it just turns off again, is that because the zone is not ffa ?.

11-04-2013, 12:46 PM
Whenever you trigger an area update, it checks the ffa flag, I have a script at home I used to prevent that, but it definitely shouldn't be done that way. It should be done through a dbc edit tbh

Lightning Blade
11-04-2013, 12:48 PM
Alrighty, just wanted to know if i should do a dbc edit or what. :)

11-04-2013, 05:32 PM
This is how I did it to keep FFA active when changing area. DO NOT USE THIS! Was hacky and not intended to be used at all, just for testing purposes. The correct way is DBC editing.

function KeepFFAAlive(event, player, newz, newa)
if newz > 1 then
CreateLuaEvent(function() SetFFAFlag(player) end, 0, 1)

function SetFFAFlag(player)

RegisterServerHook(27, KeepFFAAlive);