Exemple #1
0
/*
==================
Host_Viewnext_f
==================
*/
static void
Host_Viewnext_f(void)
{
    edict_t *e;
    model_t *m;

    e = FindViewthing();
    if (!e)
	return;
    m = cl.model_precache[(int)e->v.modelindex];

    e->v.frame = e->v.frame + 1;
    if (e->v.frame >= m->numframes)
	e->v.frame = m->numframes - 1;

    PrintFrameName(m, e->v.frame);
}
Exemple #2
0
static void
Host_Viewnext_f (void)
{
	edict_t    *e;
	model_t    *m;

	e = FindViewthing ();
	if (!e)
		return;
	m = cl.model_precache[(int) SVfloat (e, modelindex)];

	SVfloat (e, frame) = SVfloat (e, frame) + 1;
	if (SVfloat (e, frame) >= m->numframes)
		SVfloat (e, frame) = m->numframes - 1;

	PrintFrameName (m, SVfloat (e, frame));
}
Exemple #3
0
/*
==================
Host_Viewprev_f
==================
*/
static void
Host_Viewprev_f(void)
{
    edict_t *e;
    model_t *m;

    e = FindViewthing();
    if (!e)
	return;

    m = cl.model_precache[(int)e->v.modelindex];

    e->v.frame = e->v.frame - 1;
    if (e->v.frame < 0)
	e->v.frame = 0;

    PrintFrameName(m, e->v.frame);
}
Exemple #4
0
static void
Host_Viewprev_f (void)
{
	edict_t    *e;
	model_t    *m;

	e = FindViewthing ();
	if (!e)
		return;

	m = cl.model_precache[(int) SVfloat (e, modelindex)];

	SVfloat (e, frame) = SVfloat (e, frame) - 1;
	if (SVfloat (e, frame) < 0)
		SVfloat (e, frame) = 0;

	PrintFrameName (m, SVfloat (e, frame));
}