GetLookVector() public method

public GetLookVector ( ) : Vector3
return Vector3
示例#1
0
        public void FireRadar()
        {
            if (netClient.Status != NetConnectionStatus.Connected)
            {
                return;
            }

            playerToolCooldown = GetToolCooldown(PlayerTools.ProspectingRadar);

            NetBuffer msgBuffer = netClient.CreateBuffer();

            msgBuffer.Write((byte)InfiniminerMessage.UseTool);
            msgBuffer.Write(playerPosition);
            msgBuffer.Write(playerCamera.GetLookVector());
            msgBuffer.Write((byte)PlayerTools.ProspectingRadar);
            msgBuffer.Write((byte)BlockType.None);
            netClient.SendMessage(msgBuffer, NetChannel.ReliableUnordered);
        }
示例#2
0
        public void FireRadar()
        {
            if (netClient.Status != NetPeerStatus.Running)
            {
                return;
            }

            playerToolCooldown = GetToolCooldown(PlayerTools.ProspectingRadar);

            NetOutgoingMessage msgBuffer = netClient.CreateMessage();

            msgBuffer.Write((byte)InfiniminerMessage.UseTool);
            msgBuffer.Write(playerPosition);
            msgBuffer.Write(playerCamera.GetLookVector());
            msgBuffer.Write((byte)PlayerTools.ProspectingRadar);
            msgBuffer.Write((byte)BlockType.None);
            netClient.SendMessage(msgBuffer, NetDeliveryMethod.ReliableUnordered);
        }