X-Git-Url: https://de.git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fcommon%2Fmapobjects%2Fmisc%2Fteleport_dest.qc;h=efc457409364d4e3b1dc2710fa087bc083f1e58b;hb=0514f7948727cfa572b33bd29d1bdf2c13cd866d;hp=e7eedd52c413474745eab4e7c142db34f14dba34;hpb=0d0a2025de767dbfae0519941294f5947fe38c1f;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/common/mapobjects/misc/teleport_dest.qc b/qcsrc/common/mapobjects/misc/teleport_dest.qc index e7eedd52c..efc457409 100644 --- a/qcsrc/common/mapobjects/misc/teleport_dest.qc +++ b/qcsrc/common/mapobjects/misc/teleport_dest.qc @@ -14,10 +14,7 @@ bool teleport_dest_send(entity this, entity to, int sendflags) 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; @@ -31,18 +28,13 @@ void teleport_dest_link(entity this) spawnfunc(info_teleport_destination) { - this.classname = "info_teleport_destination"; - this.mangle = this.angles; this.angles = '0 0 0'; //setorigin(this, this.origin + '0 0 27'); // To fix a mappers' habit as old as Quake setorigin(this, this.origin); - IFTARGETED - { - } - else + if(!this.targetname || this.targetname == "") { objerror (this, "^3Teleport destination without a targetname"); return; // don't link it to CSQC in this case! @@ -75,10 +67,7 @@ NET_HANDLE(ENT_CLIENT_TELEPORT_DEST, bool isnew) 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);