house:setOwner(0)
local houses = Game.getHouses()
for i = 1, #houses do
local house = houses[i]
local owner = house:getOwnerGuid()
if owner > 0 then
local own = Player(owner)
if own and not own:isVip() then
house:setOwnerGuid(0)
end
end
end
I already try this one: but not working maby you be see what is wrong:
LUA:local houses = Game.getHouses() for i = 1, #houses do local house = houses[i] local owner = house:getOwnerGuid() if owner > 0 then local own = Player(owner) if own and not own:isVip() then house:setOwnerGuid(0) end end end
house:setOwnerGuid(0)
house:setOwner(0)