Index: src/Makefile ================================================================== --- src/Makefile +++ src/Makefile @@ -40,11 +40,10 @@ ${SDL_CFLAGS} \ ${GL_CFLAGS} \ ${GLU_CFLAGS} \ ${X11_CFLAGS} \ ${ZLIB_CFLAGS} -CXXFLAGS += -fpermissive LIBS += -L../enet -lenet \ ${SDL_LIBS} \ ${GL_LIBS} \ ${GLU_LIBS} \ ${X11_LIBS} \ Index: src/clientextras.cxx ================================================================== --- src/clientextras.cxx +++ src/clientextras.cxx @@ -16,18 +16,18 @@ renderclient(dynent *d, bool team, char *mdlname, bool hellpig, float scale) { int n = 3; float speed = 100.0f; float mz = d->o.z - d->eyeheight + 1.55f * scale; - int basetime = -((int)d & 0xFFF); + int basetime = -((intptr_t)d & 0xFFF); if (d->state == CS_DEAD) { int r; if (hellpig) { n = 2; r = range[3]; } else { - n = (int)d % 3; + n = (intptr_t)d % 3; r = range[n]; }; basetime = d->lastaction; int t = lastmillis - d->lastaction; if (t < 0 || t > 20000) Index: src/clients2c.cxx ================================================================== --- src/clients2c.cxx +++ src/clients2c.cxx @@ -271,11 +271,12 @@ case SV_ITEMSPAWN: { uint i = getint(p); setspawn(i, true); if (i >= (uint)ents.length()) break; - vec v = {ents[i].x, ents[i].y, ents[i].z}; + vec v = {(float)ents[i].x, (float)ents[i].y, + (float)ents[i].z}; playsound(S_ITEMSPAWN, &v); break; }; case SV_ITEMACC: // server acknowledges that I picked up this Index: src/console.cxx ================================================================== --- src/console.cxx +++ src/console.cxx @@ -245,11 +245,11 @@ }; default: resetcomplete(); if (cooked) { - char add[] = {cooked, 0}; + char add[] = {(char)cooked, 0}; strcat_s(commandbuf, add); }; }; } else { if (code == SDLK_RETURN) { Index: src/entities.cxx ================================================================== --- src/entities.cxx +++ src/entities.cxx @@ -315,11 +315,12 @@ continue; if (!ents[i].spawned && e.type != TELEPORT && e.type != JUMPPAD) continue; if (OUTBORD(e.x, e.y)) continue; - vec v = {e.x, e.y, S(e.x, e.y)->floor + player1->eyeheight}; + vec v = {(float)e.x, (float)e.y, + (float)S(e.x, e.y)->floor + player1->eyeheight}; vdist(dist, t, player1->o, v); if (dist < (e.type == TELEPORT ? 4 : 2.5)) pickup(i, player1); }; }; Index: src/monster.cxx ================================================================== --- src/monster.cxx +++ src/monster.cxx @@ -376,11 +376,11 @@ entity &e = ents[i]; if (e.type != TELEPORT) continue; if (OUTBORD(e.x, e.y)) continue; - vec v = {e.x, e.y, S(e.x, e.y)->floor}; + vec v = {(float)e.x, (float)e.y, (float)S(e.x, e.y)->floor}; loopv(monsters) if (monsters[i]->state == CS_DEAD) { if (lastmillis - monsters[i]->lastaction < 2000) { monsters[i]->move = 0; moveplayer(monsters[i], 1, false); Index: src/renderextras.cxx ================================================================== --- src/renderextras.cxx +++ src/renderextras.cxx @@ -182,11 +182,11 @@ loopv(ents) { entity &e = ents[i]; if (e.type == NOTUSED) continue; - vec v = {e.x, e.y, e.z}; + vec v = {(float)e.x, (float)e.y, (float)e.z}; particle_splash(2, 2, 40, v); }; int e = closestent(); if (e >= 0) { entity &c = ents[e]; Index: src/server.cxx ================================================================== --- src/server.cxx +++ src/server.cxx @@ -458,22 +458,22 @@ send_welcome(lastconnect = &c - &clients[0]); break; } case ENET_EVENT_TYPE_RECEIVE: brec += event.packet->dataLength; - process(event.packet, (int)event.peer->data); + process(event.packet, (intptr_t)event.peer->data); if (event.packet->referenceCount == 0) enet_packet_destroy(event.packet); break; case ENET_EVENT_TYPE_DISCONNECT: - if ((int)event.peer->data < 0) + if ((intptr_t)event.peer->data < 0) break; printf("disconnected client (%s)\n", - clients[(int)event.peer->data].hostname); - clients[(int)event.peer->data].type = ST_EMPTY; - send2(true, -1, SV_CDIS, (int)event.peer->data); + clients[(intptr_t)event.peer->data].hostname); + clients[(intptr_t)event.peer->data].type = ST_EMPTY; + send2(true, -1, SV_CDIS, (intptr_t)event.peer->data); event.peer->data = (void *)-1; break; }; if (numplayers > maxclients) { Index: src/world.cxx ================================================================== --- src/world.cxx +++ src/world.cxx @@ -254,11 +254,11 @@ loopv(ents) { entity &e = ents[i]; if (e.type == NOTUSED) continue; - vec v = {e.x, e.y, e.z}; + vec v = {(float)e.x, (float)e.y, (float)e.z}; vdist(dist, t, player1->o, v); if (dist < bdist) { best = i; bdist = dist; }; @@ -314,11 +314,12 @@ entity * newentity(int x, int y, int z, char *what, int v1, int v2, int v3, int v4) { int type = findtype(what); - persistent_entity e = {x, y, z, v1, type, v2, v3, v4}; + persistent_entity e = {(short)x, (short)y, (short)z, (short)v1, + (uchar)type, (uchar)v2, (uchar)v3, (uchar)v4}; switch (type) { case LIGHT: if (v1 > 32) v1 = 32; if (!v1) Index: src/worldlight.cxx ================================================================== --- src/worldlight.cxx +++ src/worldlight.cxx @@ -224,12 +224,12 @@ if (b.ys + b.y > ssize - 2) b.ys = ssize - 2 - b.y; dlights.add(blockcopy(b)); // backup area before rendering in dynlight - persistent_entity l = { - (int)v.x, (int)v.y, (int)v.z, reach, LIGHT, strength, 0, 0}; + persistent_entity l = {(short)v.x, (short)v.y, (short)v.z, (short)reach, + LIGHT, (uchar)strength, 0, 0}; calclightsource(l); postlightarea(b); }; // utility functions also used by editing code Index: src/worldocull.cxx ================================================================== --- src/worldocull.cxx +++ src/worldocull.cxx @@ -152,11 +152,11 @@ } // D } else { h = ca(cy + csize - vy, -(cx + csize - vx)) + 2; l = ca(cy - vy, -(cx - vx)) + 2; }; // F - } else // BG + } else // BG { if (cy <= vy) { if (cy + csize < vy) { h = ma(-(cy + csize - vy), cx - vx) + 6; l = ma(-(cy + csize - vy),