diff --git a/nzportable.3dsx b/nzportable.3dsx index ba2f5e1..a34367a 100644 Binary files a/nzportable.3dsx and b/nzportable.3dsx differ diff --git a/nzportable.elf b/nzportable.elf index ab4ec8d..f14e512 100755 Binary files a/nzportable.elf and b/nzportable.elf differ diff --git a/source/cl_hud.c b/source/cl_hud.c index 9819ec3..a903f44 100644 --- a/source/cl_hud.c +++ b/source/cl_hud.c @@ -1388,6 +1388,10 @@ void HUD_Draw (void) Draw_String (vid.width - 304, 48, "Press reload to make special waypoint"); return; } + + char stuff[1024]; + sprintf(stuff, "fov: %f", scr_fov.value); + Draw_String(0, 32, stuff); /* if (cl.stats[STAT_HEALTH] <= 0) { diff --git a/source/cl_input.c b/source/cl_input.c index f75e3c6..370f384 100644 --- a/source/cl_input.c +++ b/source/cl_input.c @@ -570,16 +570,40 @@ void CL_SendMove (usercmd_t *cmd) // send button bits // bits = 0; - - if ( in_attack.state & 3 ) + + if (in_attack.state & 3 ) bits |= 1; in_attack.state &= ~2; - + if (in_jump.state & 3) bits |= 2; in_jump.state &= ~2; + + if (in_grenade.state & 3) + bits |= 8; + in_grenade.state &= ~2; + + if (in_switch.state & 3) + bits |= 16; + in_switch.state &= ~2; + + if (in_reload.state & 3) + bits |= 32; + in_reload.state &= ~2; + + if (in_knife.state & 3) + bits |= 64; + in_knife.state &= ~2; - MSG_WriteByte (&buf, bits); + if (in_use.state & 3) + bits |= 128; + in_use.state &= ~2; + + if (in_aim.state & 3) + bits |= 256; + in_aim.state &= ~2; + + MSG_WriteLong (&buf, bits); MSG_WriteByte (&buf, in_impulse); in_impulse = 0; diff --git a/source/gl_screen.c b/source/gl_screen.c index ddde568..0f8f3ee 100644 --- a/source/gl_screen.c +++ b/source/gl_screen.c @@ -82,7 +82,7 @@ float scr_conlines; // lines of console to display float oldscreensize, oldfov; cvar_t scr_viewsize = {"viewsize","100", true}; -cvar_t scr_fov = {"fov","80", qtrue}; // 10 - 170 +cvar_t scr_fov = {"fov","80"}; // 10 - 170 cvar_t scr_conspeed = {"scr_conspeed","300"}; cvar_t scr_centertime = {"scr_centertime","2"}; cvar_t scr_showram = {"showram","1"}; @@ -499,9 +499,9 @@ float CalcFov (float fov_x, float width, float height) if (fov_x < 1 || fov_x > 179) Sys_Error ("Bad fov: %f", fov_x); - x = width/tan(fov_x/360*M_PI); + x = width/tanf(fov_x/360*M_PI); - a = atan (height/x); + a = atanf (height/x); a = a*360/M_PI; @@ -1196,7 +1196,7 @@ void SCR_UpdateScreen (void) GL_BeginRendering (&glx, &gly, &glwidth, &glheight); -// + // // determine size of refresh window // if (cl.stats[STAT_ZOOM] == 1) @@ -1270,9 +1270,9 @@ void SCR_UpdateScreen (void) vid.recalc_refdef = qtrue; } - if (oldscreensize != 120) + if (oldscreensize != scr_viewsize.value) { - oldscreensize = 120; + oldscreensize = scr_viewsize.value; vid.recalc_refdef = qtrue; } diff --git a/source/host_cmd.c b/source/host_cmd.c index 64e6dda..278b9bf 100644 --- a/source/host_cmd.c +++ b/source/host_cmd.c @@ -97,7 +97,6 @@ void Host_Status_f (void) } else hours = 0; - print ("#%-2u %-16.16s %3i %2i:%02i:%02i\n", j+1, client->name, (int)client->edict->v.frags, hours, minutes, seconds); print (" %s\n", client->netconnection->address); } } diff --git a/source/net_dgrm.c b/source/net_dgrm.c index a293b77..160ae3a 100644 --- a/source/net_dgrm.c +++ b/source/net_dgrm.c @@ -912,7 +912,7 @@ static qsocket_t *_Datagram_CheckNewConnections (void) MSG_WriteByte(&net_message, playerNumber); MSG_WriteString(&net_message, client->name); MSG_WriteLong(&net_message, client->colors); - MSG_WriteLong(&net_message, (int)client->edict->v.frags); + MSG_WriteLong(&net_message, 0); MSG_WriteLong(&net_message, (int)(net_time - client->netconnection->connecttime)); MSG_WriteString(&net_message, client->netconnection->address); *((int *)net_message.data) = BigLong(NETFLAG_CTL | (net_message.cursize & NETFLAG_LENGTH_MASK)); diff --git a/source/progdefs.h b/source/progdefs.h index d90f26b..523b9d8 100644 --- a/source/progdefs.h +++ b/source/progdefs.h @@ -110,7 +110,8 @@ typedef struct float nextthink; int groundentity; float health; - float frags; + float points; + float kills; float weapon; string_t weaponmodel; float weaponframe; @@ -125,6 +126,12 @@ typedef struct float button0; float button1; float button2; + float button3; + float button4; + float button5; + float button6; + float button7; + float button8; float impulse; float fixangle; vec3_t v_angle; @@ -143,6 +150,9 @@ typedef struct float ideal_yaw; float yaw_speed; int aiment; + int head; + int larm; + int rarm; int goalentity; float spawnflags; string_t target; @@ -159,6 +169,8 @@ typedef struct string_t noise2; string_t noise3; vec3_t ADS_Offset; + vec3_t Flash_Offset; + float Flash_Size; string_t Weapon_Name; string_t Weapon_Name_Touch; float maxspeed; diff --git a/source/sv_main.c b/source/sv_main.c index 8318725..3fe3c65 100644 --- a/source/sv_main.c +++ b/source/sv_main.c @@ -760,19 +760,7 @@ void SV_UpdateToReliableMessages (void) // check for changes to be sent over the reliable streams for (i=0, host_client = svs.clients ; iold_frags != host_client->edict->v.frags) - { - for (j=0, client = svs.clients ; jactive) - continue; - MSG_WriteByte (&client->message, svc_updatefrags); - MSG_WriteByte (&client->message, i); - MSG_WriteShort (&client->message, host_client->edict->v.frags); - } - host_client->old_frags = host_client->edict->v.frags; - } } for (j=0, client = svs.clients ; jupmove = MSG_ReadShort (); // read buttons - bits = MSG_ReadByte (); + bits = MSG_ReadLong (); host_client->edict->v.button0 = bits & 1; host_client->edict->v.button2 = (bits & 2)>>1; + host_client->edict->v.button1 = (bits & 4)>>1; + host_client->edict->v.button3 = (bits & 8)>>1; + host_client->edict->v.button4 = (bits & 16)>>1; + host_client->edict->v.button5 = (bits & 32)>>1; + host_client->edict->v.button6 = (bits & 64)>>1; + host_client->edict->v.button7 = (bits & 128)>>1; + host_client->edict->v.button8 = (bits & 256)>>1; i = MSG_ReadByte (); if (i) diff --git a/source/view.c b/source/view.c index d09f226..6c5d64f 100644 --- a/source/view.c +++ b/source/view.c @@ -338,7 +338,7 @@ cshift_t cshift_water = { {130,80,50}, 128 }; cshift_t cshift_slime = { {0,25,5}, 150 }; cshift_t cshift_lava = { {255,80,0}, 150 }; -cvar_t v_gamma = {"gamma", "1", true}; +cvar_t v_gamma = {"gamma", "2", true}; byte gammatable[256]; // palette is sent through this @@ -630,11 +630,6 @@ void V_UpdatePalette (void) cl.prev_cshifts[i].destcolor[j] = cl.cshifts[i].destcolor[j]; } } - -// drop the damage value - cl.cshifts[CSHIFT_DAMAGE].percent -= host_frametime*150; - if (cl.cshifts[CSHIFT_DAMAGE].percent <= 0) - cl.cshifts[CSHIFT_DAMAGE].percent = 0; // drop the bonus value cl.cshifts[CSHIFT_BONUS].percent -= host_frametime*100;