string function cleanups

git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@4714 e016b1c5-ed68-44aa-a2f7-31cac88cffde
This commit is contained in:
Lee Salzman
2009-11-07 22:44:32 +00:00
parent 9e817de2c8
commit e725e5ed8c
38 changed files with 423 additions and 420 deletions
+3 -3
View File
@@ -416,13 +416,13 @@ void renderbounceents()
switch(p->bouncetype)
{
case BT_NADE:
s_strcpy(model, "weapons/grenade/static");
copystring(model, "weapons/grenade/static");
break;
case BT_GIB:
default:
{
uint n = (((4*(uint)(size_t)p)+(uint)p->timetolive)%3)+1;
s_sprintf(model)("misc/gib0%u", n);
formatstring(model)("misc/gib0%u", n);
int t = lastmillis-p->millis;
if(t>p->timetolive-2000)
{
@@ -646,7 +646,7 @@ void weapon::renderhudmodel(int lastaction, int index)
weaponmove wm;
if(!intermission) wm.calcmove(unitv, lastaction);
s_sprintfd(path)("weapons/%s", info.modelname);
defformatstring(path)("weapons/%s", info.modelname);
bool emit = (wm.anim&ANIM_INDEX)==ANIM_GUN_SHOOT && (lastmillis - lastaction) < flashtime();
int rindex = (righthanded) ? index : (index ? 0 : 1);
rendermodel(path, wm.anim|ANIM_DYNALLOC|(rindex ? ANIM_MIRROR : 0)|(emit ? ANIM_PARTICLE : 0), 0, -1, wm.pos, player1->yaw+90, player1->pitch+wm.k_rot, 40.0f, wm.basetime, NULL, NULL, 1.28f);