Read sleeping bag/bed text?
Discussion in 'Rust Development' started by Norn, Oct 26, 2015.
-
Something like:
Not sure if you'll need to call some sort of network update or not after.Code:var bag= entity.GetComponent<SleepingBag>(); bag.niceName= "Whatever";
-
Sorry I forgot to reply, yes I got it by looking at the finder plugins source. Thanks though ^^
Now I'm stuck detecting when a bag has been given to a friend, is there a hook that exists for that? -
Wulf Community Admin
It can probably be detected using one of the existing hooks, though you'd need to look in the source to see. -
I don't think there are any hooks that would trap the assign, it's pretty specific to that object. Didn't look at oxide but looking at the decompiled code here I don't see any triggers. Unless there is a specific hook for this action, i think you're kinda screwed on that one. You could compile a list of all bags with their location and compare ownerids but meh, that would be expensive and very hackish.
