Skip to content

Commit

Permalink
Set connection owner for priority update (#55)
Browse files Browse the repository at this point in the history
  • Loading branch information
stijnwop committed Mar 24, 2018
1 parent 4e64a25 commit 230c658
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/events/HoseSystemDropEvent.lua
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ function HoseSystemDropEvent:run(connection)
end

if not connection:getIsServer() then
self.object:setOwner(nil)

g_server:broadcastEvent(self, false, connection, self.object)
end
end
Expand Down
2 changes: 2 additions & 0 deletions src/events/HoseSystemGrabEvent.lua
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ function HoseSystemGrabEvent:run(connection)
end

if not connection:getIsServer() then
self.object:setOwner(connection)

g_server:broadcastEvent(self, false, connection, self.object)
end
end
Expand Down

0 comments on commit 230c658

Please sign in to comment.