ParaScript.RequestOwnership

Declaration

public void RequestOwnership(Action<bool> onFinished);

Description

Requests the network owner permissions of the object.

Parameter

onFinished

Callback notification when a request is completed. If the boolean parameter in the callback function is true, the request is successful.

function OnNetSpawned()
    self:RequestOwnership(function(bSucceed)
    	if bSucceed then
        	print("request ownership succeed");
      end
    end);
end