コード例 #1
0
 // log and send ship motion info to comm
 private void sendData()
 {
     UDPSend.newPacket();
     UDPSend.addFloat(Time.time);
     UDPSend.addFloat(scale * Movement.instance.getLinVel().magnitude);
     UDPSend.addVector(scale * Movement.instance.getAngVel());
     UDPSend.addVector(scale * Movement.instance.getLinAcc());
     UDPSend.addVector(scale * Movement.instance.getAngAcc());
     UDPSend.addVector(transform.rotation.eulerAngles);
     UDPSend.sendPacket();
 }