Garry's Mod

Garry's Mod

Not enough ratings
Transfer Ownership
Type: Tool, Addon
Tags: Roleplay, Build
File Size
0.003 MB
Jul 17, 2017 @ 12:40pm
Aug 13, 2017 @ 12:34pm
3 Change Notes ( view )

Subscribe to download
Transfer Ownership

This addon requires that you're using a prop protection addon that is CPPI compliant
Examples of popular prop protection addons which are CPPI compliant:

Allows players to transfer ownership of selected entities to another player.
The ownership transfer can be undone using the "Undo" button in-game

Use the convar transfer_ownership_check_ownership to choose whether to check strictly against the owner of the prop (1) or if the player has permission to use toolgun on the prop (0). The latter is useful for cases where you want the players to change the ownership of their friends props.

The convar transfer_ownership_admin_check_ownership is the same as above, but only applies to admins so that admins can change ownership of players props or disconnected players props. This convar is ignored if the above is set to 0.

The convar transfer_ownership_admin_usergroup sets which usergroup that should take advantage of the above admin check.
E.g. transfer_ownership_admin_usergroup "superadmin" allows only superadmins (and on ULX, exsto and AssMod any group that inherits from it. "admin" and "superadmin" will use the IsAdmin and IsSuperAdmin checks respectively.)

Source Code
The source code is available on GitHub[] and is released under the GNU Affero General Public License v3 (AGPL-3.0)[]

Bug reporting/Suggestions
Any bugs/errors/suggestions should be posted on GitHub[], I will not be looking at the workshop comments often.
< >
☮shift☮ Aug 11 @ 7:11am 
can you trasfer owner to world ?
Polp Retsim Aug 14, 2017 @ 3:59pm 
Ohhh that's a nice thing to hear !
Thanks and good job ! I'll try it when I got time to :)
Rynoxx |  [author] Aug 13, 2017 @ 12:38pm 
@Mister.Plop There we go, updated and at least during my testing it works with Simfphys cars now :D
It works with both primary and secondary fire :steamhappy:
Polp Retsim Aug 9, 2017 @ 8:36am 
@Rynoxx Okay nice, thanks :)
Rynoxx |  [author] Aug 9, 2017 @ 6:58am 
@Mister.Plop Ok, I've updated the github with some code that should solve the issue. However I haven't had the opportunity to test it in-game yet.
I'll see if I get time to test it later today and if I do, I'll update the workshop with a simphys compatible version :)
Polp Retsim Aug 9, 2017 @ 2:09am 
@Rynoxx Yeah he right click, it works pretty well but not so much with simfphys based cars. The player can actually pick up his items
But no matter what, if the "original" owner disconnects, the wheels disappear, and the seats too. I mean, we can't get into the car no more , but it's still there as a prop
Rynoxx |  [author] Aug 9, 2017 @ 12:33am 
@Mister.Plop Try using the secondary fire feature to transfer all entities constrained to the car. Otherwise try doing each wheel separately. If that doesn't work I'll see if I can take a look at it
Polp Retsim Aug 7, 2017 @ 6:31am 
Oh, seems when I transfer a simfphys car to a player and then disconnects, the wheels disappear and we can't drive anymore
Polp Retsim Aug 7, 2017 @ 6:17am 
Thanks for this pal.
Works perfectly well, does what it says.