Author |
Message |
Chris
DieHard Wolfer


Joined: 11 Mar 2003
Last Visit: 14 Feb 2019
Topics: 55
Posts: 2169
Location: Canada

|
Posted: Mon Sep 21, 2009 5:46 pm
Subject: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

 
|
|
I noticed that with the factory settings of SDL, most things are very easy to adjust (like MAXACTORS, MAXSTATS, MAPSHIFT, NUMFLOORS, NUMVISABLE, etc.) just by changing the number in the define, which is pretty cool.
One area that is still not so easy to change though, is MAXWALLTILES and MAXDOORS.
Currently, the walls and wall sides use up to bit6 (1<<6), and the doors use up to bit7 (1<<7.). The most practical way around this restriction, in my opinion, would be to change tilemap from a byte to an int and get rid of the "magic numbers" (0x40, 0x80, 0x7f, etc.) for the 'tilemap bit separation' by using an adjustable #define to control the bits used instead.
Here's some new MAXDOORS/MAXWALLS options that this method would open up:
::: CODE :::
WALLBIT MAXDOORS/MAXWALLS BINARY HEX
6 doors 128, walls 64 0000 0000 dw00 0000 Dx0080, Wx0040
7 doors 256, walls 128 0000 000d w000 0000 Dx0100, Wx0080
8 doors 512, walls 256 0000 00dw 0000 0000 Dx0200, Wx0100
9 doors 1024, walls 512 0000 0dw0 0000 0000 Dx0400, Wx0200
10 doors 2048, walls 1024 0000 dw00 0000 0000 Dx0800, Wx0400
11 doors 4096, walls 2048 000d w000 0000 0000 Dx1000, Wx0800
12 doors 8192, walls 4096 00dw 0000 0000 0000 Dx2000, Wx1000
13 doors 16384, wall 8192 0dw0 0000 0000 0000 Dx4000, Wx2000
I threw together a patch for WolfSDL_v1.6 that uses this idea, if anyone wants to try it:
http://chokfiles.webs.com/bitshift.rar
The default is #define WALLSHIFT 10, which lets you use up to 1024 walls and 2048 doors.
To restore it back to the default amount of walls/doors, just change it to use #define WALLSHIFT 6.
p.s. How is everyone currently getting extra walls into their addons (and how many textures do you use)? Just curious.
Here's the actual code adjustments I did in the SDL source for this idea to work...
* The code in blue denotes stuff for changing TILEMAP to an int.
* The code in red denotes stuff for replacing the "magic numbers" with defines.
* The code in purple denotes an example of how to load the newtiles from the gamemaps file.
(all the walls can be loaded into the level using mapdefs 1001+ (0x3E9), as shown in the included map/list for WDC.)
In WL_DEF.H:
::: CODE :::
#define MAXTICS 10
#define DEMOTICS 4
#define WALLSHIFT 10
#define BIT_WALL (1<<WALLSHIFT)
#define BIT_DOOR (1<<(WALLSHIFT+1))
#define BIT_ALLTILES (1<<(WALLSHIFT+2))
#define LAST_WALLNUM BIT_WALL-1
#define LAST_DOORNUM BIT_DOOR-1
#define MAXACTORS 150 // max number of nazis, etc / map
#define MAXSTATS 400 // max number of lamps, bonus, etc
#define MAXDOORS BIT_DOOR // max number of sliding doors
#define MAXWALLTILES BIT_WALL // max number of wall tiles
::: CODE :::
extern uint16_t tilemap[MAPSIZE][MAPSIZE]; // wall values only
::: CODE :::
extern word pwalldir,pwalltile;
In WL_ACT1.CPP:
1. SpawnStatic()
::: CODE :::
case block:
actorat[tilex][tiley] = (objtype *) BIT_WALL; // consider it a blocking tile
2. SpawnDoor()
::: CODE :::
actorat[tilex][tiley] = (objtype *)(uintptr_t)(doornum | BIT_DOOR); // consider it a solid wall
//
// make the door tile a special tile, and mark the adjacent tiles
// for door sides
//
tilemap[tilex][tiley] = doornum | BIT_DOOR;
map = mapsegs[0] + (tiley<<mapshift) +tilex;
if (vertical)
{
*map = *(map-1); // set area number
tilemap[tilex][tiley-1] |= BIT_WALL;
tilemap[tilex][tiley+1] |= BIT_WALL;
}
else
{
*map = *(map-mapwidth); // set area number
tilemap[tilex-1][tiley] |= BIT_WALL;
tilemap[tilex+1][tiley] |= BIT_WALL;
}
3. CloseDoor()
::: CODE :::
//
// make the door space solid
//
actorat[tilex][tiley] = (objtype *)(uintptr_t)(door | BIT_DOOR);
4. DoorClosing()
::: CODE :::
if ( ((int)(uintptr_t)actorat[tilex][tiley] != (door | BIT_DOOR))
|| (player->tilex == tilex && player->tiley == tiley) )
5. Above PushWall()
::: CODE :::
word pwalldir,pwalltile;
6. PushWall()
::: CODE :::
pwalltile = tilemap[pwallx][pwally];
tilemap[pwallx][pwally] = BIT_WALL;
tilemap[pwallx+dx][pwally+dy] = BIT_WALL;
7. MovePWalls()
::: CODE :::
actorat[pwallx+dx][pwally+dy] = (objtype *)(uintptr_t) (tilemap[pwallx+dx][pwally+dy] = oldtile);
tilemap[pwallx+dx][pwally+dy] = BIT_WALL;
In WL_AGENT.CPP:
1. Cmd_Use()
::: CODE :::
else if (!buttonheld[bt_use] && doornum & BIT_DOOR)
{
buttonheld[bt_use] = true;
OperateDoor (doornum & ~BIT_DOOR);
}
In WL_DEBUG.CPP:
1. BasicOverhead()
::: CODE :::
else if (MAPSPOT(x,y,1) == PUSHABLETILE) color = 171; // pushwall
else if (tile == BIT_WALL) color = 158; // solid obj
else if (tile < BIT_DOOR) color = 154; // walls
else if (tile < BIT_ALLTILES) color = 146; // doors
2. DebugKeys (Keyboard[sc_F])
::: CODE :::
US_Print (" 3:");
if ((unsigned)(uintptr_t)actorat[player->tilex][player->tiley] < BIT_ALLTILES)
In WL_DRAW.CPP:
1. HitVertWall()
::: CODE :::
if(lastside==1 && lastintercept==xtile && lasttilehit==tilehit && !(lasttilehit & BIT_WALL))
::: CODE :::
if (tilehit & BIT_WALL)
{ // check for adjacent doors
ytile = (short)(yintercept>>TILESHIFT);
if ( tilemap[xtile-xtilestep][ytile]&BIT_DOOR )
wallpic = DOORWALL+3;
else
wallpic = vertwall[tilehit & ~BIT_WALL];
2. HitHorizWall()
::: CODE :::
if(lastside==0 && lastintercept==ytile && lasttilehit==tilehit && !(lasttilehit & BIT_WALL))
::: CODE :::
if (tilehit & BIT_WALL)
{ // check for adjacent doors
xtile = (short)(xintercept>>TILESHIFT);
if ( tilemap[xtile][ytile-ytilestep]&BIT_DOOR)
wallpic = DOORWALL+2;
else
wallpic = horizwall[tilehit & ~BIT_WALL];
3. HitHorizDoor()
::: CODE :::
doornum = tilehit&LAST_DOORNUM;
texture = ((xintercept-doorposition[doornum])>>TEXTUREFROMFIXEDSHIFT)&TEXTUREMASK;
4. HitVertDoor()
::: CODE :::
doornum = tilehit&LAST_DOORNUM;
texture = ((yintercept-doorposition[doornum])>>TEXTUREFROMFIXEDSHIFT)&TEXTUREMASK;
5. HitHorizPWall()
::: CODE :::
wallpic = horizwall[pwalltile&BIT_WALL];
6. HitVertPWall()
::: CODE :::
wallpic = vertwall[pwalltile&BIT_WALL];
7. DrawScaleds()
::: CODE :::
void DrawScaleds (void)
{
int i,least,numvisable,height;
byte *visspot;
uint16_t *tilespot;
unsigned spotloc;
8. AsmRefresh()
::: CODE :::
int32_t xstep,ystep;
longword xpartial,ypartial;
boolean playerInPushwallBackTile = tilemap[focaltx][focalty] == BIT_WALL;
::: CODE :::
tilehit=((uint16_t *)tilemap)[xspot];
if(tilehit)
{
if(tilehit&BIT_DOOR)
{
int32_t yintbuf=yintercept+(ystep>>1);
if((yintbuf>>16)!=(yintercept>>16))
goto passvert;
if((word)yintbuf<doorposition[tilehit&LAST_DOORNUM])
goto passvert;
::: CODE :::
if(tilehit==BIT_WALL)
{
if(pwalldir==di_west || pwalldir==di_east)
::: CODE :::
tilehit=((uint16_t *)tilemap)[yspot];
if(tilehit)
{
if(tilehit&BIT_DOOR)
{
int32_t xintbuf=xintercept+(xstep>>1);
if((xintbuf>>16)!=(xintercept>>16))
goto passhoriz;
if((word)xintbuf<doorposition[tilehit&LAST_DOORNUM])
goto passhoriz;
::: CODE :::
if(tilehit==BIT_WALL)
{
if(pwalldir==di_north || pwalldir==di_south)
In WL_GAME.CPP:
1. SetupGameLevel()
::: CODE :::
//
// copy the wall data to a data segment array
//
#define NEWTILE_OFFSET 1000
memset (tilemap,0,sizeof(tilemap));
memset (actorat,0,sizeof(actorat));
map = mapsegs[0];
for (y=0;y<mapheight;y++)
{
for (x=0;x<mapwidth;x++)
{
tile = *map++;
if (tile<AREATILE)
{
// solid wall
tilemap[x][y] = (byte) tile;
actorat[x][y] = (objtype *)(uintptr_t) tile;
}
else if (tile>=NEWTILE_OFFSET && tile < (NEWTILE_OFFSET+MAXWALLTILES))
{
tilemap[x][y] = tile - NEWTILE_OFFSET;
actorat[x][y] = (objtype *)(uintptr_t) (tile - NEWTILE_OFFSET);
}
else
{
// area floor
tilemap[x][y] = 0;
actorat[x][y] = 0;
}
}
}
In WL_PLAY.CPP:
::: CODE :::
uint16_t tilemap[MAPSIZE][MAPSIZE]; // wall values only
In WL_STATE.CPP:
1. Above TryWalk()
::: CODE :::
#define CHECKDIAG(x,y) \
{ \
temp=(uintptr_t)actorat[x][y]; \
if (temp) \
{ \
if (temp<BIT_ALLTILES) \
return false; \
if (((objtype *)temp)->flags&FL_SHOOTABLE) \
return false; \
} \
}
#ifdef PLAYDEMOLIKEORIGINAL
#define DOORCHECK \
if(DEMOCOND_ORIG) \
doornum = temp&63; \
else \
{ \
doornum = (int) temp & LAST_DOORNUM; \
OpenDoor(doornum); \
ob->distance = -doornum - 1; \
return true; \
}
#else
#define DOORCHECK \
doornum = (int) temp & LAST_DOORNUM; \
OpenDoor(doornum); \
ob->distance = -doornum - 1; \
return true;
#endif
#define CHECKSIDE(x,y) \
{ \
temp=(uintptr_t)actorat[x][y]; \
if (temp) \
{ \
if (temp<BIT_DOOR) \
return false; \
if (temp<BIT_ALLTILES) \
{ \
DOORCHECK \
} \
else if (((objtype *)temp)->flags&FL_SHOOTABLE) \
return false; \
} \
}
2. CheckLine()
::: CODE :::
if (value<BIT_DOOR || value>BIT_ALLTILES)
return false;
//
// see if the door is open enough
//
value &= ~BIT_DOOR;
intercept = yfrac-ystep/2;
::: CODE :::
if (value<BIT_DOOR || value>BIT_ALLTILES)
return false;
//
// see if the door is open enough
//
value &= ~BIT_DOOR;
intercept = xfrac-xstep/2;
Looks like a lot of editing... but that's only because there was many hard coded numbers in there!  |
|
|
 |
Tricob
Moderator


Joined: 14 Mar 2005
Last Visit: 12:29 ago.
Topics: 165
Posts: 8327
Location: Neo-traditions, Inc.

|
|
 |
Dean
Moderator

Joined: 10 Jan 2006
Last Visit: 6:27 ago.
Topics: 54
Posts: 2215
Location: Australia

|
Posted: Tue Sep 22, 2009 6:00 am
Subject: Re: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

  
|
|
Outstanding work as usual Chris! Thanks for taking the time to look at the SDL code and share this with everyone.  |
_________________ ... Still alive
|
|
 |
Chris
DieHard Wolfer


Joined: 11 Mar 2003
Last Visit: 14 Feb 2019
Topics: 55
Posts: 2169
Location: Canada

|
Posted: Tue Sep 22, 2009 11:36 am
Subject: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

  
|
|
Cool. It's nice that Brothertank ported a lot of his features and structural ideas from Wolf Advanced over!
I thought the original demos would act differently from this (and that more adjustments would have to be made to get them to play correctly again), but it looks like changing the tilemap size doesn't affect the behavior of the random tables at all!
Another interesting thing, is that, using RLEW and Carmack compression on a 16-bit tilemap when saving your game (like they did for the gamemaps data) would technically work much better now. Although maybe that's being a little overzealous.  |
|
|
 |
Airslide
Don't Hurt Me

Joined: 08 Aug 2005
Last Visit: 02 Jan 2011
Topics: 8
Posts: 60

|
Posted: Wed Sep 23, 2009 8:51 pm
Subject: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

  
|
|
I thought of this just a few days ago, didn't think it'd take that many changes though
Good job  |
|
|
 |
Tricob
Moderator


Joined: 14 Mar 2005
Last Visit: 12:29 ago.
Topics: 165
Posts: 8327
Location: Neo-traditions, Inc.

|
Posted: Thu Sep 24, 2009 8:27 pm
Subject: Re: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

  
|
|
How will this code react if the 90 Walls code from BT's Bunker source is already enabled?  |
|
|
 |
RichterBelmont12
DieHard Wolfer


Joined: 14 Aug 2004
Last Visit: 15 Feb 2019
Topics: 98
Posts: 1516
Location: New Jersey

|
|
 |
Chris
DieHard Wolfer


Joined: 11 Mar 2003
Last Visit: 14 Feb 2019
Topics: 55
Posts: 2169
Location: Canada

|
Posted: Tue May 10, 2011 10:05 pm
Subject: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

  
|
|
Hey Richter,
To get the door number from a tile, you should use tile&LAST_DOORNUM (tile%BIT_DOOR works too).
I modified your code a bit, let me know how it works now...
::: CODE :::
if (tilehit & BIT_WALL)
{ // check for adjacent doors
ytile = (short)(yintercept>>TILESHIFT);
if ( tilemap[xtile-xtilestep][ytile] & BIT_DOOR )
{
switch(doorobjlist[tilemap[xtile-xtilestep][ytile] & LAST_DOORNUM].lock)
{
case dr_lock1:
wallpic = DOORWALL+5;
break;
case dr_lock2:
wallpic = DOORWALL+7;
break;
case dr_lock3:
wallpic = DOORWALL+9;
break;
case dr_lock4:
wallpic = DOORWALL+11;
break;
case dr_lock5:
wallpic = DOORWALL+13;
break;
case dr_lock6:
wallpic = DOORWALL+15;
break;
default:
wallpic = DOORWALL+3;
break;
}
}
else
wallpic = vertwall[tilehit & ~BIT_WALL];
}
else
wallpic = vertwall[tilehit];
::: CODE :::
if (tilehit & BIT_WALL)
{ // check for adjacent doors
xtile = (short)(xintercept>>TILESHIFT);
if ( tilemap[xtile][ytile-ytilestep] & BIT_DOOR)
{
switch(doorobjlist[tilemap[xtile][ytile-ytilestep] & LAST_DOORNUM].lock)
{
case dr_lock1:
wallpic = DOORWALL+5;
break;
case dr_lock2:
wallpic = DOORWALL+7;
break;
case dr_lock3:
wallpic = DOORWALL+9;
break;
case dr_lock4:
wallpic = DOORWALL+11;
break;
case dr_lock5:
wallpic = DOORWALL+13;
break;
case dr_lock6:
wallpic = DOORWALL+15;
break;
default:
wallpic = DOORWALL+3;
break;
}
}
else
wallpic = horizwall[tilehit & ~BIT_WALL];
}
else
wallpic = horizwall[tilehit];
|
|
|
 |
RichterBelmont12
DieHard Wolfer


Joined: 14 Aug 2004
Last Visit: 15 Feb 2019
Topics: 98
Posts: 1516
Location: New Jersey

|
|
 |
ThunderEnema
I am Death Incarnate

Joined: 05 Jul 2012
Last Visit: 17 Feb 2019
Topics: 4
Posts: 195
Location: Washington

|
Posted: Mon Dec 05, 2016 12:59 am
Subject: Re: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

  
|
|
I am sorry to bump an old thread, but I ran into a really strange problem related to this code recently.
I am using wall values 1,000 and up for my walls; I noticed that when I place a deaf guard next to one of these walls, the guard turns into a statue and does not move until it is attacked. This never used to happen before I implemented this code and was just using the normal 1-64 wall values (it didn't even happen when I used values 1-90). I have tried changing the newtile_offset to use a different wall value (144,200,400), I still get the same result where the wall turns a nearby deaf guard into a statue.
Is there something about this code that conflicts with the ambush tile? |
_________________ "When I see someone wearing crocs in public, I have all the information I need to know that I will never get along with that person." -Me
|
|
 |
AlumiuN
DieHard Wolfer

Joined: 29 Nov 2007
Last Visit: 16 Feb 2019
Topics: 38
Posts: 2536
Location: Christchurch, New Zealand

|
Posted: Mon Dec 05, 2016 1:54 am
Subject: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

  
|
|
Ah, yep, there's a problem with it in SpawnStand where it only checks if a floor code is high enough to be a floor code, never if it's low enough to be not one of the new walls. Find this section:
::: CODE :::
map = mapsegs[0]+(tiley<<mapshift)+tilex;
tile = *map;
if (tile == AMBUSHTILE)
{
tilemap[tilex][tiley] = 0;
if (*(map+1) >= AREATILE)
tile = *(map+1);
if (*(map-mapwidth) >= AREATILE)
tile = *(map-mapwidth);
if (*(map+mapwidth) >= AREATILE)
tile = *(map+mapwidth);
if ( *(map-1) >= AREATILE)
tile = *(map-1);
*map = tile;
newobj->areanumber = tile-AREATILE;
newobj->flags |= FL_AMBUSH;
}
And change it to this:
::: CODE :::
map = mapsegs[0]+(tiley<<mapshift)+tilex;
tile = *map;
if (tile == AMBUSHTILE)
{
tilemap[tilex][tiley] = 0;
if (*(map+1) >= AREATILE && *(map+1) < AREATILE + NUMAREAS)
tile = *(map+1);
if (*(map-mapwidth) >= AREATILE && *(map-mapwidth) < AREATILE + NUMAREAS)
tile = *(map-mapwidth);
if (*(map+mapwidth) >= AREATILE && *(map+mapwidth) < AREATILE + NUMAREAS)
tile = *(map+mapwidth);
if ( *(map-1) >= AREATILE && *(map-1) < AREATILE + NUMAREAS)
tile = *(map-1);
*map = tile;
newobj->areanumber = tile-AREATILE;
newobj->flags |= FL_AMBUSH;
}
That should hopefully fix it. |
|
|
 |
Chris
DieHard Wolfer


Joined: 11 Mar 2003
Last Visit: 14 Feb 2019
Topics: 55
Posts: 2169
Location: Canada

|
Posted: Mon Dec 05, 2016 8:22 am
Subject: Re: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

  
|
|
Thanks AlumiuN. I posted about it here too (purple code near the bottom) but have been pro-Dos lately and never got around to trying it out. Thanks ThunderEnema for confirming that the problem does indeed exist.  |
|
|
 |
ThunderEnema
I am Death Incarnate

Joined: 05 Jul 2012
Last Visit: 17 Feb 2019
Topics: 4
Posts: 195
Location: Washington

|
Posted: Mon Dec 05, 2016 4:53 pm
Subject: Re: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

  
|
|
Thanks AlumiuN. I will test out the code tonight and report the results. I appreciate your help! |
_________________ "When I see someone wearing crocs in public, I have all the information I need to know that I will never get along with that person." -Me
|
|
 |
Tricob
Moderator


Joined: 14 Mar 2005
Last Visit: 12:29 ago.
Topics: 165
Posts: 8327
Location: Neo-traditions, Inc.

|
|
 |
Chris
DieHard Wolfer


Joined: 11 Mar 2003
Last Visit: 14 Feb 2019
Topics: 55
Posts: 2169
Location: Canada

|
Posted: Tue Dec 06, 2016 9:54 am
Subject: Re: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

  
|
|
In the link I posted, there's also a fix for the deaf guard code in WL_GAME (first purple code). This situation is less obvious: if you have a Death Incarnate or Bring Em On enemy on a deaf guard floor beside a 144+ wall in certain direction(s) and play the game on a lower skill level than what skill the enemy is, SpawnStand will not be called and this code will instead when it sees the deaf floorcode, and without the fix it can make the floorcode for that square and possibly subsequent ones beside it invalid.
Though if anyone wants to do it the "move floorcodes up past all the walls" way instead (red code idea) I'll still take offers to convert the floorcodes in the maps to higher values, because I like that idea better and then no purple code is needed.  |
|
|
 |
Barry
DieHard Officer


Joined: 27 Aug 2008
Last Visit: 14 Dec 2018
Topics: 64
Posts: 566

|
|
 |
AlumiuN
DieHard Wolfer

Joined: 29 Nov 2007
Last Visit: 16 Feb 2019
Topics: 38
Posts: 2536
Location: Christchurch, New Zealand

|
Posted: Tue Dec 06, 2016 1:38 pm
Subject: Re: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

  
|
|
I avoided this issue by just shoving the doors and floorcodes further down the list :3 |
|
|
 |
ThunderEnema
I am Death Incarnate

Joined: 05 Jul 2012
Last Visit: 17 Feb 2019
Topics: 4
Posts: 195
Location: Washington

|
Posted: Tue Dec 06, 2016 1:42 pm
Subject: Re: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

  
|
|
AlumiuN: The code worked like a charm! Thanks.
Chris: Thanks for updating the info in your tutorial for the WL_Game ambush tile code. I would have missed that.
I think both the red and the purple versions of the code are useful. I, personally, would not want to use the red version of the code in this instance because I've mapped about 20 levels for my mod using the old floor values.
Anyway, thanks for the help guys! |
_________________ "When I see someone wearing crocs in public, I have all the information I need to know that I will never get along with that person." -Me
|
|
 |
Barry
DieHard Officer


Joined: 27 Aug 2008
Last Visit: 14 Dec 2018
Topics: 64
Posts: 566

|
|
 |
AlumiuN
DieHard Wolfer

Joined: 29 Nov 2007
Last Visit: 16 Feb 2019
Topics: 38
Posts: 2536
Location: Christchurch, New Zealand

|
|
 |
Chris
DieHard Wolfer


Joined: 11 Mar 2003
Last Visit: 14 Feb 2019
Topics: 55
Posts: 2169
Location: Canada

|
Posted: Tue Feb 21, 2017 8:10 pm
Subject: Re: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

  
|
|
The red and blue code is now included in AlumiuN's repository: https://github.com/AlumiuN/Wolf4SDL
If you download that base, all you have to do is adjust WALLSHIFT, MAXWALLTILES and MAXDOORS in wl_def.h to your liking and add the purple code (or another idea like this). It even knows to compile tilemap as a byte or word automagically (cool! ). |
|
|
 |
Aryan_Wolf3D
DieHard Guard

Joined: 21 Jul 2011
Last Visit: 17 Feb 2019
Topics: 6
Posts: 212

|
|
 |
AlumiuN
DieHard Wolfer

Joined: 29 Nov 2007
Last Visit: 16 Feb 2019
Topics: 38
Posts: 2536
Location: Christchurch, New Zealand

|
Posted: Wed Feb 22, 2017 1:09 am
Subject: Re: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

  
|
|
Fixed, thanks  |
|
|
 |
Chris
DieHard Wolfer


Joined: 11 Mar 2003
Last Visit: 14 Feb 2019
Topics: 55
Posts: 2169
Location: Canada

|
Posted: Thu Feb 23, 2017 8:20 am
Subject: Re: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

  
|
|
Nice catch Aryan_Wolf3D! |
|
|
 |
fraggeur
DieHard Guard


Joined: 31 Dec 2012
Last Visit: 12:04 ago.
Topics: 12
Posts: 284

|
Posted: Thu Feb 23, 2017 1:04 pm
Subject: Re: MAXWALLTILES/MAXDOORS - Removing the hard coded limits
[ IP : Logged ]
|

 
|
|
Wow I had carried this bug in my mod and didn't really notice. I just tried now before/after, I prefer with the fix  |
|
|
 |
|