Author Topic: [FIXED] [GLITCH] [SUGGESTION] [PLAYER] Moving through walls with many builders  (Read 2447 times)

0 Members and 1 Guest are viewing this topic.

Offline Nepster

  • Posts: 1829
    • View Profile
I found two more glitches concerning builders, that might require slight changes in the game physics. Here is the first:

Suggestion:
Disallow assigning builders to lemmings, if their first brick would not add any terrain.

Reason:
1) Repeated assignment of builders allows to move lemmings diagonally through solid walls. Try the attached level or watch the replay.
2) This rule already applies to platformers, so this change would make the game mechanics more consistent.

Moreover I don't think that there are many existing levels/replays where lemmings completely encased in terrain are turned into builders, so this change should not have a huge impact on existing levels/replays.
« Last Edit: June 15, 2016, 05:23:31 PM by Nepster »

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: [GLITCH] [SUGGESTION] [PLAYER] Moving through walls with many builders
« Reply #1 on: February 22, 2016, 05:18:46 PM »
Quote
Disallow assigning builders to lemmings, if their first brick would not add any terrain.

Sounds reasonable and viable (note - my first thought was "wait, that will break every level that involves building against a slope to turn around!" - but in fact, this action does still add one pixel of terrain, so it wouldn't be affected).
My Lemmings projects
2D Lemmings: NeoLemmix (engine) | Lemmings Plus Series (level packs) | Doomsday Lemmings (level pack)
3D Lemmings: Loap (engine) | L3DEdit (level / graphics editor) | L3DUtils (replay / etc utility) | Lemmings Plus 3D (level pack)

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: [GLITCH] [SUGGESTION] [PLAYER] Moving through walls with many builders
« Reply #2 on: February 22, 2016, 05:57:07 PM »
Tried implementing this. One situation that your suggestion does not solve:
My Lemmings projects
2D Lemmings: NeoLemmix (engine) | Lemmings Plus Series (level packs) | Doomsday Lemmings (level pack)
3D Lemmings: Loap (engine) | L3DEdit (level / graphics editor) | L3DUtils (replay / etc utility) | Lemmings Plus 3D (level pack)

Offline Nepster

  • Posts: 1829
    • View Profile
Re: [GLITCH] [SUGGESTION] [PLAYER] Moving through walls with many builders
« Reply #3 on: February 22, 2016, 06:22:09 PM »
I see... What are the precise terrain checks for platformers? Perhaps one can use something similar for builders? I noticed that in your example level, one cannot assign platformers to the trapped lemming.

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: [GLITCH] [SUGGESTION] [PLAYER] Moving through walls with many builders
« Reply #4 on: February 22, 2016, 06:28:11 PM »
The platformer is also prevented from platforming if his first brick would cause him to turn around, even if it would place terrain. For obvious reasons, doing this with the builder would break a lot of levels. Removing such a thing with the platformer is perhaps more viable; it would improve consistency with far less breakage, but still wouldn't really fix the issue at hand.

It's mostly LemCanPlatform and AssignPlatformer that are relevant here, but I've pasted HandlePlatforming too just in case it helps.

TLemmingGame.HandlePlatforming (click to show/hide)

TLemmingGame.LemCanPlatform (click to show/hide)

TLemmingGame.AssignPlatformer (click to show/hide)

One possible solution is simply to disallow both if there's a pixel at (LemX, LemY-1). Generally, in any state where this would be true, it would already be impossible to assign these skills anyway (as the lemming would generally be either climbing or jumping at such a time). The only exceptions are (a) the situation demonstrated in Glitchy Spikes, and (b) if a constructive skill had, in the frame immediately prior, placed a pixel at that location - most likely to happen with a stoner, but could theoretically happen with any of them.
« Last Edit: February 22, 2016, 06:34:41 PM by namida »
My Lemmings projects
2D Lemmings: NeoLemmix (engine) | Lemmings Plus Series (level packs) | Doomsday Lemmings (level pack)
3D Lemmings: Loap (engine) | L3DEdit (level / graphics editor) | L3DUtils (replay / etc utility) | Lemmings Plus 3D (level pack)

Offline Nepster

  • Posts: 1829
    • View Profile
Re: [GLITCH] [SUGGESTION] [PLAYER] Moving through walls with many builders
« Reply #5 on: February 22, 2016, 07:04:33 PM »
One possible solution is simply to disallow both if there's a pixel at (LemX, LemY-1).
Sounds like a good idea.

PS: Your LemCanPlatform causes some irregular behavior as well. Will post a new topic with example map.

Offline ccexplore

  • Posts: 5311
    • View Profile
Re: [GLITCH] [SUGGESTION] [PLAYER] Moving through walls with many builders
« Reply #6 on: February 22, 2016, 07:29:01 PM »
Hmm, it's my understanding that this wouldn't work in vanilla Lemmix (ie. DOS Lemmings mechanics).  The builder does advance horizontally one pixel at the frame it turns around and reverts to walker.  But, the walker then will always move horizontally one pixel (facing opposite direction now) on next frame before turning around again.  So there is no net gain horizontally (vertically of course you do gain one pixel per builder).

If I have to guess, NeoLemmix must have changed the second part ("the walker then will always advance horizontally one pixel...") if it enables horizontal movement through solid wall?  Or maybe if you assign a different skill to the walker that enables the second turnaround without any horizontal movement.

[edit: I should add one more clarification.  If your worker is a climber, then you do get a horizontal gain, because at the second part with the walker, it will trigger the climber to do its "climb and fall" thing which gains you 2 pixels horizontally.  This variation does work in vanilla Lemmix, but is arguably more a side effect of the climber's odd behavior.]
« Last Edit: February 22, 2016, 07:43:14 PM by ccexplore »