public void BroadcastUnequip(Pickupable pickupable, GameObject owner, string slot) { string itemGuid = GuidHelper.GetGuid(pickupable.gameObject); string ownerGuid = GuidHelper.GetGuid(owner); EquipmentRemoveItem removeEquipment = new EquipmentRemoveItem(ownerGuid, slot, itemGuid); packetSender.Send(removeEquipment); }
public void Unequip(Pickupable pickupable, GameObject owner, string slot) { string itemGuid = GuidHelper.GetGuid(pickupable.gameObject); string ownerGuid = GuidHelper.GetGuid(owner); Vector3 ownerPos = owner.transform.position; EquipmentRemoveItem removeEquipment = new EquipmentRemoveItem(ownerGuid, slot, itemGuid, ownerPos); packetSender.Send(removeEquipment); }
public void BroadcastUnequip(Pickupable pickupable, GameObject owner, string slot) { string itemGuid = GuidHelper.GetGuid(pickupable.gameObject); string ownerGuid = GuidHelper.GetGuid(owner); Player player = owner.GetComponent <Player>(); bool isPlayerEquipment = (player != null); EquipmentRemoveItem equipPacket = new EquipmentRemoveItem(ownerGuid, slot, itemGuid, isPlayerEquipment); packetSender.Send(equipPacket); }
public void BroadcastUnequip(Pickupable pickupable, GameObject owner, string slot) { string itemGuid = GuidHelper.GetGuid(pickupable.gameObject); string ownerGuid = GuidHelper.GetGuid(owner); if (pickupable.GetTechType() == TechType.VehicleStorageModule) { List <InteractiveChildObjectIdentifier> childIdentifiers = VehicleChildObjectIdentifierHelper.ExtractGuidsOfInteractiveChildren(owner); VehicleChildUpdate vehicleChildInteractiveData = new VehicleChildUpdate(ownerGuid, childIdentifiers); packetSender.Send(vehicleChildInteractiveData); } Player player = owner.GetComponent <Player>(); bool isPlayerEquipment = (player != null); EquipmentRemoveItem equipPacket = new EquipmentRemoveItem(ownerGuid, slot, itemGuid, isPlayerEquipment); packetSender.Send(equipPacket); }