DarkRP.Entity.GetDoorOwner
Jump to navigation
Jump to search
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:GetDoorOwner() |
Description: | |
Returns the door owner. | |
Returns: | Player |
Part of Library: | Entity |
Realm: |
![]() |
BBCode Link: | [b][url=http://wiki.darkrp.com/index.php?title=DarkRP.Entity.GetDoorOwner]Entity:GetDoorOwner[/url][/b] |
Examples[edit]
Description | Sends a message to the door owner saying that a player wants to own their door. |
---|---|
Used on | ![]() |
Code | function WantsToOwn( ply, door )
if door:AllowedToOwn( ply ) then
door:GetDoorOwner():ChatPrint( ply:Nick() .. " wants to own your door too!" )
end
end
|
Output | N/A |
Additional Notes[edit]
- Will return nil if there is no door owner.
- Can sometimes return owners that have disconnected recently.