From: havoc Date: Thu, 19 Apr 2012 11:48:07 +0000 (+0000) Subject: changed PRVM_ValueString (used by prvm_global, prvm_globals, prvm_edict, X-Git-Tag: xonotic-v0.8.0~96^2~238 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=4af0644b31b021c55c1b2a4fe4760b2377cd4387;p=xonotic%2Fdarkplaces.git changed PRVM_ValueString (used by prvm_global, prvm_globals, prvm_edict, prvm_edicts) to print floats and vectors with more precision (using the FLOAT_LOSSLESS_FORMAT and VECTOR_LOSSLESS_FORMAT macros previously added) git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@11800 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/prvm_edict.c b/prvm_edict.c index 82392bbf..307f3129 100644 --- a/prvm_edict.c +++ b/prvm_edict.c @@ -442,11 +442,11 @@ static char *PRVM_ValueString (prvm_prog_t *prog, etype_t type, prvm_eval_t *val break; case ev_float: // LordHavoc: changed from %5.1f to %10.4f - dpsnprintf (line, linelength, "%10.4f", val->_float); + dpsnprintf (line, linelength, FLOAT_LOSSLESS_FORMAT, val->_float); break; case ev_vector: // LordHavoc: changed from %5.1f to %10.4f - dpsnprintf (line, linelength, "'%10.4f %10.4f %10.4f'", val->vector[0], val->vector[1], val->vector[2]); + dpsnprintf (line, linelength, "'" VECTOR_LOSSLESS_FORMAT "'", val->vector[0], val->vector[1], val->vector[2]); break; case ev_pointer: dpsnprintf (line, linelength, "pointer");