WriteCoord(MSG_ENTITY, this.speed);
WriteString(MSG_ENTITY, this.targetname);
WriteVector(MSG_ENTITY, this.origin);
-
- WriteAngle(MSG_ENTITY, this.mangle_x);
- WriteAngle(MSG_ENTITY, this.mangle_y);
- WriteAngle(MSG_ENTITY, this.mangle_z);
+ WriteAngleVector(MSG_ENTITY, this.mangle);
}
return true;
//setorigin(this, this.origin + '0 0 27'); // To fix a mappers' habit as old as Quake
setorigin(this, this.origin);
- IFTARGETED
+ if(!this.targetname || this.targetname == "")
{
- }
- else
objerror (this, "^3Teleport destination without a targetname");
+ return; // don't link it to CSQC in this case!
+ }
teleport_dest_link(this);
}
this.speed = ReadCoord();
this.targetname = strzone(ReadString());
this.origin = ReadVector();
-
- this.mangle_x = ReadAngle();
- this.mangle_y = ReadAngle();
- this.mangle_z = ReadAngle();
+ this.mangle = ReadAngleVector();
setorigin(this, this.origin);