From: Samual Date: Tue, 3 May 2011 16:53:36 +0000 (-0400) Subject: Add some extra information to a few of the CSQC prints to better help with debugging X-Git-Tag: xonotic-v0.5.0~263^2~9^2~3 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=e2008ef2693090f60d41afbf65a176951d1fb28a;p=xonotic%2Fxonotic-data.pk3dir.git Add some extra information to a few of the CSQC prints to better help with debugging --- diff --git a/qcsrc/client/Main.qc b/qcsrc/client/Main.qc index 81a713c32..6bd6b7bdb 100644 --- a/qcsrc/client/Main.qc +++ b/qcsrc/client/Main.qc @@ -717,7 +717,8 @@ void Ent_ReadPlayerScore() #ifdef DP_CSQC_ENTITY_REMOVE_IS_B0RKED if(!isNew && n != self.sv_entnum) { - print(_("A CSQC entity changed its owner!\n")); + //print(_("A CSQC entity changed its owner!\n")); + print(sprintf(_("A CSQC entity changed its owner! (edict: %d, classname: %s)\n"), num_for_edict(self), self.classname)); isNew = true; Ent_Remove(); self.enttype = ENT_CLIENT_SCORES; @@ -931,7 +932,8 @@ void(float bIsNewEntity) CSQC_Ent_Update = if(self.enttype) if(t != self.enttype) { - print(_("A CSQC entity changed its type!\n")); + //print(_("A CSQC entity changed its type!\n")); + print(sprintf(_("A CSQC entity changed its type! (edict: %d, classname: %s)\n"), num_for_edict(self), self.classname)); Ent_Remove(); bIsNewEntity = 1; } @@ -968,7 +970,8 @@ void(float bIsNewEntity) CSQC_Ent_Update = case ENT_CLIENT_GAUNTLET: Ent_ReadHook(bIsNewEntity, ENT_CLIENT_GAUNTLET); break; case ENT_CLIENT_ACCURACY: Ent_ReadAccuracy(); break; default: - error(strcat(_("unknown entity type in CSQC_Ent_Update: %d\n"), self.enttype)); + //error(strcat(_("unknown entity type in CSQC_Ent_Update: %d\n"), self.enttype)); + error(sprintf(_("Unknown entity type in CSQC_Ent_Update (enttype: %d, edict: %d, classname: %s)\n"), self.enttype, num_for_edict(self), self.classname)); break; } diff --git a/qcsrc/client/movetypes.qc b/qcsrc/client/movetypes.qc index 1d6a6e393..9a17dea35 100644 --- a/qcsrc/client/movetypes.qc +++ b/qcsrc/client/movetypes.qc @@ -156,10 +156,10 @@ float _Movetype_UnstickEntity() // SV_UnstickEntity if(!_Movetype_TestEntityPosition('0 0 -1' * i)) goto success; if(!_Movetype_TestEntityPosition('0 0 1' * i)) goto success; } - dprint("Some entity is stuck\n"); + dprint(sprintf(_("Can't unstick an entity (edict: %d, classname: %s, origin: %s)\n"), num_for_edict(self), self.classname, vtos(self.move_origin))); return FALSE; :success - dprint("Unstuck some entity\n"); + dprint(sprintf(_("Sucessfully unstuck an entity (edict: %d, classname: %s, origin: %s)\n"), num_for_edict(self), self.classname, vtos(self.move_origin))); _Movetype_LinkEdict(TRUE); return TRUE; }