From f71b2cd2d9dc648e8c1631d29a01973249b70ae0 Mon Sep 17 00:00:00 2001 From: terminx Date: Thu, 30 Nov 2006 23:53:44 +0000 Subject: [PATCH] updatesector() -> updatesectorz() I have no clue if this breaks anything. git-svn-id: https://svn.eduke32.com/eduke32@372 1a8010ca-5511-0410-912e-c29ae57300e0 --- polymer/eduke32/source/actors.c | 20 ++++++++++---------- polymer/eduke32/source/game.c | 20 ++++++++++---------- polymer/eduke32/source/gameexec.c | 4 ++-- polymer/eduke32/source/player.c | 6 +++--- polymer/eduke32/source/premap.c | 2 +- polymer/eduke32/source/sector.c | 10 +++++----- 6 files changed, 31 insertions(+), 31 deletions(-) diff --git a/polymer/eduke32/source/actors.c b/polymer/eduke32/source/actors.c index 9b99f2193..990ddc890 100644 --- a/polymer/eduke32/source/actors.c +++ b/polymer/eduke32/source/actors.c @@ -480,7 +480,7 @@ SKIPWALLCHECK: ps[p].posy = ps[p].oposy; ps[p].posz = ps[p].oposz; ps[p].ang = ps[p].oang; - updatesector(ps[p].posx,ps[p].posy,&ps[p].cursectnum); + updatesectorz(ps[p].posx,ps[p].posy,ps[p].posz,&ps[p].cursectnum); setpal(&ps[p]); k = headspritestat[1]; @@ -809,7 +809,7 @@ void movefta(void) { px = ps[p].oposx+64-(TRAND&127); py = ps[p].oposy+64-(TRAND&127); - updatesector(px,py,&psect); + updatesectorz(px,py,ps[p].oposz,&psect); if (psect == -1) { i = nexti; @@ -817,7 +817,7 @@ void movefta(void) } sx = s->x+64-(TRAND&127); sy = s->y+64-(TRAND&127); - updatesector(px,py,&ssect); + updatesectorz(px,py,ps[p].oposz,&ssect); if (ssect == -1) { i = nexti; @@ -4127,7 +4127,7 @@ void moveactors(void) ps[p].posz = ps[p].oposz; ps[p].ang = ps[p].oang; - updatesector(ps[p].posx,ps[p].posy,&ps[p].cursectnum); + updatesectorz(ps[p].posx,ps[p].posy,ps[p].posz,&ps[p].cursectnum); setpal(&ps[p]); j = headspritestat[1]; @@ -5719,7 +5719,7 @@ void moveeffectors(void) //STATNUM 3 if (sprite[ps[p].i].extra > 0) { k = ps[p].cursectnum; - updatesector(ps[p].posx,ps[p].posy,&k); + updatesectorz(ps[p].posx,ps[p].posy,ps[p].posz,&k); if ((k == -1 && ud.clipping == 0) || (k == s->sectnum && ps[p].cursectnum != s->sectnum)) { ps[p].posx = s->x; @@ -5801,7 +5801,7 @@ void moveeffectors(void) //STATNUM 3 if (sprite[ps[p].i].extra > 0) { k = ps[p].cursectnum; - updatesector(ps[p].posx,ps[p].posy,&k); + updatesectorz(ps[p].posx,ps[p].posy,ps[p].posz,&k); if ((k == -1 && ud.clipping == 0) || (k == s->sectnum && ps[p].cursectnum != s->sectnum)) { ps[p].oposx = ps[p].posx = s->x; @@ -5820,7 +5820,7 @@ void moveeffectors(void) //STATNUM 3 if (sprite[j].statnum == 1 && badguy(&sprite[j]) && sprite[j].picnum != SECTOREFFECTOR && sprite[j].picnum != LOCATORS) { k = sprite[j].sectnum; - updatesector(sprite[j].x,sprite[j].y,&k); + updatesectorz(sprite[j].x,sprite[j].y,sprite[j].z,&k); if (sprite[j].extra >= 0 && k == s->sectnum) { gutsdir(&sprite[j],JIBS6,72,myconnectindex); @@ -5900,7 +5900,7 @@ void moveeffectors(void) //STATNUM 3 if (sprite[ps[p].i].extra > 0) { k = ps[p].cursectnum; - updatesector(ps[p].posx,ps[p].posy,&k); + updatesectorz(ps[p].posx,ps[p].posy,ps[p].posz,&k); if ((k == -1 && ud.clipping == 0) || (k == s->sectnum && ps[p].cursectnum != s->sectnum)) { ps[p].posx = s->x; @@ -5969,7 +5969,7 @@ void moveeffectors(void) //STATNUM 3 if (sprite[ps[p].i].extra > 0) { k = ps[p].cursectnum; - updatesector(ps[p].posx,ps[p].posy,&k); + updatesectorz(ps[p].posx,ps[p].posy,ps[p].posz,&k); if ((k == -1 && ud.clipping == 0) || (k == s->sectnum && ps[p].cursectnum != s->sectnum)) { ps[p].posx = s->x; @@ -5994,7 +5994,7 @@ void moveeffectors(void) //STATNUM 3 // if(sprite[j].sectnum != s->sectnum) { k = sprite[j].sectnum; - updatesector(sprite[j].x,sprite[j].y,&k); + updatesectorz(sprite[j].x,sprite[j].y,sprite[j].z,&k); if (sprite[j].extra >= 0 && k == s->sectnum) { gutsdir(&sprite[j],JIBS6,24,myconnectindex); diff --git a/polymer/eduke32/source/game.c b/polymer/eduke32/source/game.c index 00a4f9f62..394273a04 100644 --- a/polymer/eduke32/source/game.c +++ b/polymer/eduke32/source/game.c @@ -4673,16 +4673,16 @@ short spawn(short j, short pn) short s1; s1 = sp->sectnum; - updatesector(sp->x+108,sp->y+108,&s1); + updatesectorz(sp->x+108,sp->y+108,sp->z,&s1); if (s1 >= 0 && sector[s1].floorz == sector[sp->sectnum].floorz) { - updatesector(sp->x-108,sp->y-108,&s1); + updatesectorz(sp->x-108,sp->y-108,sp->z,&s1); if (s1 >= 0 && sector[s1].floorz == sector[sp->sectnum].floorz) { - updatesector(sp->x+108,sp->y-108,&s1); + updatesectorz(sp->x+108,sp->y-108,sp->z,&s1); if (s1 >= 0 && sector[s1].floorz == sector[sp->sectnum].floorz) { - updatesector(sp->x-108,sp->y+108,&s1); + updatesectorz(sp->x-108,sp->y+108,sp->z,&s1); if (s1 >= 0 && sector[s1].floorz != sector[sp->sectnum].floorz) { sp->xrepeat = sp->yrepeat = 0; @@ -4904,16 +4904,16 @@ short spawn(short j, short pn) short s1; s1 = sp->sectnum; - updatesector(sp->x+84,sp->y+84,&s1); + updatesectorz(sp->x+84,sp->y+84,sp->z,&s1); if (s1 >= 0 && sector[s1].floorz == sector[sp->sectnum].floorz) { - updatesector(sp->x-84,sp->y-84,&s1); + updatesectorz(sp->x-84,sp->y-84,sp->z,&s1); if (s1 >= 0 && sector[s1].floorz == sector[sp->sectnum].floorz) { - updatesector(sp->x+84,sp->y-84,&s1); + updatesectorz(sp->x+84,sp->y-84,sp->z,&s1); if (s1 >= 0 && sector[s1].floorz == sector[sp->sectnum].floorz) { - updatesector(sp->x-84,sp->y+84,&s1); + updatesectorz(sp->x-84,sp->y+84,sp->z,&s1); if (s1 >= 0 && sector[s1].floorz != sector[sp->sectnum].floorz) { sp->xrepeat = sp->yrepeat = 0; @@ -10621,7 +10621,7 @@ void fakedomovethings(void) x = myx+(sintable[(myang+512)&2047]>>5); y = myy+(sintable[myang&2047]>>5); tempsect = psect; - updatesector(x,y,&tempsect); + updatesectorz(x,y,myz,&tempsect); if (tempsect >= 0) { k = getflorzofslope(psect,x,y); @@ -10672,7 +10672,7 @@ void fakedomovethings(void) clipmove(&myx,&myy,&myz,&mycursectnum,0,0,164L,(4L<<8),(4L<<8),CLIPMASK0); } - updatesector(myx,myy,&mycursectnum); + updatesectorz(myx,myy,myz,&mycursectnum); pushmove(&myx,&myy,&myz,&mycursectnum,128L,(4L<<8),(20L<<8),CLIPMASK0); myhoriz = 100; diff --git a/polymer/eduke32/source/gameexec.c b/polymer/eduke32/source/gameexec.c index 6620c02b4..a89df5a13 100644 --- a/polymer/eduke32/source/gameexec.c +++ b/polymer/eduke32/source/gameexec.c @@ -4129,7 +4129,7 @@ SKIPJIBS: ps[g_p].posy = ps[g_p].oposy; ps[g_p].posz = ps[g_p].oposz; ps[g_p].ang = ps[g_p].oang; - updatesector(ps[g_p].posx,ps[g_p].posy,&ps[g_p].cursectnum); + updatesectorz(ps[g_p].posx,ps[g_p].posy,ps[g_p].posz,&ps[g_p].cursectnum); setpal(&ps[g_p]); j = headspritestat[1]; @@ -5245,7 +5245,7 @@ SKIPJIBS: g_sp->x = hittype[g_i].bposx = ps[g_p].bobposx = ps[g_p].oposx = ps[g_p].posx; g_sp->y = hittype[g_i].bposy = ps[g_p].bobposy = ps[g_p].oposy =ps[g_p].posy; g_sp->z = hittype[g_i].bposy = ps[g_p].oposz =ps[g_p].posz; - updatesector(ps[g_p].posx,ps[g_p].posy,&ps[g_p].cursectnum); + updatesectorz(ps[g_p].posx,ps[g_p].posy,ps[g_p].posz+PHEIGHT,&ps[g_p].cursectnum); setsprite(ps[g_p].i,ps[g_p].posx,ps[g_p].posy,ps[g_p].posz+PHEIGHT); g_sp->cstat = 257; diff --git a/polymer/eduke32/source/player.c b/polymer/eduke32/source/player.c index b5ffa4da4..f88064702 100644 --- a/polymer/eduke32/source/player.c +++ b/polymer/eduke32/source/player.c @@ -3352,7 +3352,7 @@ void processinput(short snum) x = p->posx+(sintable[(p->ang+512)&2047]>>5); y = p->posy+(sintable[p->ang&2047]>>5); tempsect = psect; - updatesector(x,y,&tempsect); + updatesectorz(x,y,p->posz,&tempsect); if (tempsect >= 0) { k = getflorzofslope(psect,x,y); @@ -3698,7 +3698,7 @@ void processinput(short snum) p->horiz = 100; p->horizoff = 0; - updatesector(p->posx,p->posy,&p->cursectnum); + updatesectorz(p->posx,p->posy,p->posz,&p->cursectnum); pushmove(&p->posx,&p->posy,&p->posz,&p->cursectnum,128L,(4L<<8),(20L<<8),CLIPMASK0); @@ -4434,7 +4434,7 @@ HORIZONLY: j = 0; p->posx += p->posxv>>14; p->posy += p->posyv>>14; - updatesector(p->posx,p->posy,&p->cursectnum); + updatesectorz(p->posx,p->posy,p->posz,&p->cursectnum); changespritesect(pi,p->cursectnum); } else diff --git a/polymer/eduke32/source/premap.c b/polymer/eduke32/source/premap.c index 466346c01..1c8166081 100644 --- a/polymer/eduke32/source/premap.c +++ b/polymer/eduke32/source/premap.c @@ -1341,7 +1341,7 @@ void resetpspritevars(char g) hittype[i].bposz = ps[j].oposz = ps[j].posz = s->z; ps[j].oang = ps[j].ang = s->ang; - updatesector(s->x,s->y,&ps[j].cursectnum); + updatesectorz(s->x,s->y,s->z+PHEIGHT,&ps[j].cursectnum); j = connectpoint2[j]; diff --git a/polymer/eduke32/source/sector.c b/polymer/eduke32/source/sector.c index 3cac16d87..36f7e67f5 100644 --- a/polymer/eduke32/source/sector.c +++ b/polymer/eduke32/source/sector.c @@ -1673,7 +1673,7 @@ void checkhitwall(short spr,short dawallnum,long x,long y,long z,short atwith) //case W_FORCEFIELD+2: wal->extra = 1; // tell the forces to animate case BIGFORCE__STATIC: - updatesector(x,y,&sn); + updatesectorz(x,y,z,&sn); if (sn < 0) return; if (atwith == -1) @@ -1706,7 +1706,7 @@ void checkhitwall(short spr,short dawallnum,long x,long y,long z,short atwith) return; case GLASS__STATIC: - updatesector(x,y,&sn); + updatesectorz(x,y,z,&sn); if (sn < 0) return; wal->overpicnum=GLASS2; lotsofglass(spr,dawallnum,10); @@ -1722,7 +1722,7 @@ void checkhitwall(short spr,short dawallnum,long x,long y,long z,short atwith) spritesound(GLASS_BREAKING,i); return; case STAINGLASS1__STATIC: - updatesector(x,y,&sn); + updatesectorz(x,y,z,&sn); if (sn < 0) return; lotsofcolourglass(spr,dawallnum,80); wal->cstat = 0; @@ -2472,7 +2472,7 @@ void checkhitsprite(short i,short sn) ps[p].posz = ps[p].oposz; ps[p].ang = ps[p].oang; - updatesector(ps[p].posx,ps[p].posy,&ps[p].cursectnum); + updatesectorz(ps[p].posx,ps[p].posy,ps[p].posz,&ps[p].cursectnum); setpal(&ps[p]); j = headspritestat[1]; @@ -3458,7 +3458,7 @@ CLEARCAMERAS: p->ang = p->oang; p->newowner = -1; - updatesector(p->posx,p->posy,&p->cursectnum); + updatesectorz(p->posx,p->posy,p->posz,&p->cursectnum); setpal(p);