DarkRP.Entity.removeDoorOwner

From DarkRP
(Redirected from DarkRP.Entity.RemoveOwner)
This page refers to DarkRP 2.4.3. This information may be incorrect as of later versions.
Check here for a up-to-date list of functions.
Function
Function name Entity:removeDoorOwner(Player ply)
Description:
Makes a player no longer own the door.
Returns: nil
Part of Library: Entity
Realm:
BBCode Link: [b][url=http://wiki.darkrp.com/index.php?title=DarkRP.Entity.removeDoorOwner]Entity:removeDoorOwner[/url][/b]

Examples[edit]

DescriptionMakes a player no longer own every door that he has group ownership with.
Used on
Code
--ply = player that's gonna loose all his/her doors
for _, ent in ipairs(ents.GetAll()) do
	if ent:IsDoor() == true then
		ent:removeDoorOwner(ply)
	end
end
OutputN/A


Important things to know[edit]

  • RemoveAllowed makes the player no longer allowed to own the door, this makes the player actually unown the door.