public virtual void Spawn() { UFLevelStructure.PosRot pr = default(UFLevelStructure.PosRot); if (UFLevel.playerInfo != null) { pr = UFLevel.playerInfo.GetSpawn(UFPlayerInfo.PlayerClass.Free); } this.gameObject.layer = UFLevel.playerInfo.playerLayer; this.transform.position = pr.position; this.transform.rotation = Quaternion.Euler(0f, pr.rotation.eulerAngles.y, 0f); SetRotation(pr.rotation); GetComponent <UFPlayerWeapons>().Reset(); }
public CenteredBox(PosRot posRot, Vector3 extents) { this.transform = new UFTransform(posRot); this.extents = extents; }
public UFTransform(Vector3 pos, int id) { this.posRot = new PosRot(pos); this.id = id; }
public UFTransform(Vector3 pos, Quaternion rot, int id) { this.posRot = new PosRot(pos, rot); this.id = id; }
public UFTransform(PosRot posRot, int id) { this.posRot = posRot; this.id = id; }
public UFTransform(PosRot posRot) : this(posRot, -1) { }