Last Sunset for Lattica

edited June 2011 in Support files
Here's a rough first draft of the Lattica map, just to demonstrate that [strike]it's possible to get to all the screens and the game can be completed[/strike] this is only the first of an as yet undetermined number of impending maps.

As can be seen, some screens have open tracks which disappear off the map, but with the layout as shown it's not possible to get to them. I haven't determined yet if the map tiles get rearranged at all (although it seems likely); the map has had the same layout every time I've played it so far, anyway. I'll check the code later, and I've just bought a copy of the game as well so I can check the inlay instructions, as they're not on WoS.

Another point is that some tracks don't have the striped edges all the way along them; eg. 3rd tile top row. Moving off one of these open edges into a wall on the adjacent tile will temporarily display that tile and then bounce back to the previous tile. So that seems to be working OK, although I haven't checked every place where this is possible.

Finally, the striped edges flash continuously and it was doing my head in. If you don't want to suffer a bilious attack every time you play it, then these changes will stop the flashing:
        org $A214                ; turn off flashing edges
        LD HL, $0032             ; A214 21 32 00
        org $A8F3
        LD HL, $0032             ; A8F3 21 32 00
        org $AF36
        LD HL, $0032             ; AF36 21 32 00
        org $B4AC
        LD HL, $0032             ; B4AC 21 32 00
Post edited by Battle Bunny on

Comments

  • edited June 2011
    Flip! That's only the map for the first level! After getting the lock & key it starts a new map. Cripe knows how many there are after that. Hi de hi.
  • edited June 2011
    Hey ... here is one thing I do remember from mapping the game. The tiles are different for the levels BUT I honestly don't remember if the levels map logically around each other. I.e. the edges of each map might/might not connect the maps together (don't remember).

    Make sense? Anywho.
  • edited June 2011
    Well, I've completed Lattica (using infy lives and enhanced infy time POKEs as detailed below - Tipshop advised):
    lattica-bomb.gif

    There's a message "CORRECT - YOU HAVE SAVED LATTICA" after the bomb is defused, but it doesn't stay on the screen for very long. There are three levels; the three maps do not connect together. Once I've removed the score bars and reassembled them I'll upload them to WoS. I'll send the instructions when I get the tape.

    I've tried bouncing off blocked connection points between screens all over the place, but I haven't as yet been able to reproduce the error described elsewhere, so I haven't been able to do anything about fixing it. I'll do a bit more experimenting to see if I can get it to go wrong. In normal play the game is quite OK to play & finish as it is.

    Here's the infy POKEs; 4-7 are not currently on Tipshop, but they're all needed. Some of the time POKEs disable the screen countdown whereas the others disable the actual check. They do rather spoil the game, though. The screens seem pretty chaotic at first, but there are patterns to the movement of the hazards so they can be avoided a lot of the time.
    infy lives
    POKE 45148,42  ($B05C,$2A)
    POKE 48671,42  ($BE1F,$2A)
    infy time
    POKE 44132,175 ($AC64,$AF)
    POKE 45789,175 ($B2DD,$AF)
    POKE 49999,175 ($C34F,$AF)
    POKE 50175,175 ($C3FF,$AF)
    POKE 50271,175 ($C45F,$AF)
    
  • edited June 2011
    Found my old map! Sent it in to WoS.

    Here is further of what I remember:

    Start point, key and lock are fixed, no matter which difficulty level is selected, they can be counted on being in the same place.

    The only thing different per difficulty level is the speed of characters and movement of self (iIRC).

    Code for the bomb is random. It is a super easy thing to clear though, as you're given ample time (iIrc).
    You are given a hint (HIGHER/LOWER). Start with thousands, then hundreds, etc, etc.
  • edited June 2011
    OK, here's the bouncing off walls fix for Lattica. I've tried going into blocked space in all 24 possible movement directions on various screens and it always bounces back into the screen it just came from, at the same coordinates, even if I'm right in a corner. I've checked both the TZX and TAP on WoS and this works with both of them.

    The program had some complicated formula for calculating connections between map segments based upon which keys had been pressed, which obviously didn't work properly for reverse diagonals. It was too much palaver working out why it was going wrong, so I just ignored that and instead I saved the current & previous segment addresses, as bouncing back off a wall should always go back to where it just came from regardless of which keys were pressed.

    There's a major stack creep problem with the original program. I thought that it looked a little large, so I checked my saved games and by the end of level 3 the machine stack was 3,232 bytes! There's still 12k before it hits STKEND, so I'm not going to bother about it.

    I got my Lattica tape this morning, so I'll send off the instructions to WoS, although they don't add anything to what we already know, apart from the scenario narrative - apparently it's necessary to "diffuse" the bomb.
                                     ; Last Sunset for Lattica
            org  $9D3F               ; bouncing off walls fix
            call PSAVE               ; 9D3F CD 34 F8
            org  $A2BA
            call PLOAD               ; A2BA CD 53 F8
            org  $A30A
            call PLOAD               ; A30A CD 53 F8
            org  $B318
            call PSAVE               ; B318 CD 34 F8
            org  $B353
            call PSAVE               ; B318 CD 34 F8
    
            org  $F834
    PSAVE:  PUSH HL                  ; F834 E5
            LD HL, ($D1A5)           ; F835 2A A5 D1
            LD (ROWNUM), HL          ; F838 22 88 F8
            LD HL, ($D1A9)           ; F83B 2A A9 D1
            LD (COLNUM), HL          ; F83E 22 8A F8
            LD HL, (THISAD)          ; F841 2A 83 F8
            LD (PREVAD), HL          ; F844 22 85 F8
            POP HL                   ; F847 E1
            LD ($D1A1), HL           ; F848 22 A1 D1
            LD (THISAD), HL          ; F84B 22 83 F8
            XOR A                    ; F84E AF
            LD (FLAGAD), A           ; F84F 32 87 F8
            RET                      ; F852 C9
    
    PLOAD:  LD A, (FLAGAD)           ; F853 3A 87 F8
            AND A                    ; F856 A7
            JR NZ, NOSWAP            ; F857 20 17
            LD HL, (PREVAD)          ; F859 2A 85 F8
            LD ($D1A1), HL           ; F85C 22 A1 D1
            PUSH HL                  ; F85F E5
            LD HL, (THISAD)          ; F860 2A 83 F8
            LD (PREVAD), HL          ; F863 22 85 F8
            POP HL                   ; F866 E1
            LD (THISAD), HL          ; F867 22 83 F8
            INC A                    ; F86A 3C
            LD (FLAGAD), A           ; F86B 32 87 F8
            JR ROWCOL                ; F86E 18 06
    NOSWAP: LD HL, (THISAD)          ; F870 2A 83 F8
            LD ($D1A1), HL           ; F873 22 A1 D1
    ROWCOL: LD HL, (ROWNUM)          ; F876 2A 88 F8
            LD ($D1A5), HL           ; F879 22 A5 D1
            LD HL, (COLNUM)          ; F87C 2A 8A F8
            LD ($D1A9), HL           ; F87F 22 A9 D1
            RET                      ; F882 C9
    
    THISAD: defw $0000               ; F883 00 00
    PREVAD: defw $0000               ; F885 00 00
    FLAGAD: defb $00                 ; F887
    ROWNUM: defw $0000               ; F888 00 00
    COLNUM: defw $0000               ; F88A 00 00
    
  • edited June 2011
    Hey Battle Bunny ... do not NOT send in your map for the game, as yours is easier to read screen-wise.

    When I found my map the other day, I noticed I had made each screen the same colour, so it's not easy to distinguish where one screen starts and where the next one ends, etc.

    So ... the more (maps), the merrier (WoSsers!)
  • edited June 2011
    OK, I've now uploaded the three maps and the instructions.
  • edited June 2011
    OK, here's the bouncing off walls fix for Lattica.

    Great work!

    I just added this fix to the list in the "known errors" thread and I will upload it to WoS later today.
    Creator of ZXDB, BIFROST/NIRVANA, ZX7/RCS, etc. I don't frequent this forum anymore, please look for me elsewhere.
  • edited June 2011
    OK, I've now uploaded the three maps and the instructions.

    Perhaps it would look better if you removed the green and blue bars you had at the bottom of each screen here, but keeping the white space you already had between different screens.

    That's just a suggestion, your map looks great anyway!
    Creator of ZXDB, BIFROST/NIRVANA, ZX7/RCS, etc. I don't frequent this forum anymore, please look for me elsewhere.
  • edited June 2011
    Perhaps it would look better if you removed the green and blue bars you had at the bottom of each screen here, but keeping the white space you already had between different screens.

    I did. This is how the map for Level 1 now looks, for example.

    I'll probably make a start on Bride of Frankenstein tomorrow.
  • edited June 2011
    Say, I forgot about something.

    I know the startpoint, key and lock are fixed but I seem to have forgotten to keep account of the potion(s) ... I see only one in the first level (on my map) but didn't think about it for the other ones.

    I'm not going to check it out, if the potions are fixed ... will leave that one up to you guys.
  • edited June 2011
    Potions are assigned randomly on entering a screen. They won't appear if there's already four extra lives and they'll disappear after a while if they're not picked up. Once a potion has been collected then no more will appear on that level.

    I found this logo embedded in the Lattica code:
    lattlogo.gif
    Anyone know to what or whom it refers?
  • edited June 2011
    I found this logo embedded in the Lattica code:
    lattlogo.gif
    Anyone know to what or whom it refers?

    The DC 4?

    THEoDore CIVilian?

    Err ... no clue.
  • edited June 2011
    I found a way to escape from the map.

    There are a few "out of reach" corridors visible along the borders of each level. However in 3 different places they are close enough to the regular passages, that it's possible to reach them moving in diagonal:
    • lower left corner in level 2
    • right side border in level 3
    • lower side border in level 3

    It's easy to identify these areas in this map, which I suppose was provided by ZnorXman (thanks!)

    The first 2 corridors are dead-ends, but the last one connects into a large maze that finally leads into a large empty space (certainly some empty area in memory).

    It could be interesting to investigate if these areas are fixed or random (i.e. if they are mapped from a memory area that only contains static code or also contains variables). If fixed, can it be mapped or is this new area too large? Perhaps the existing game maps could be updated to include this new area also...


    EDIT: BTW I don't think this "new area" should be classified as a critical bug since it doesn't interfere with regular gameplay. It only allows the player to intentionally escape from the map, so it's more like an "eastern egg" instead of a bug. As such, I don't think it should be bugfixed (unlike the bouncing off walls bug). Actually it's kinda fun to explore outside the map...

    However if this new area is coincidentally mapped from the memory area where the bouncing off walls fix is located, it may be worth it to move the fix code somewhere else, so the "eastern egg" area remains the same in both original and bugfixed versions... But I have no idea if this is the case or not, it still requires further investigation. Is anybody up to the task?
    Creator of ZXDB, BIFROST/NIRVANA, ZX7/RCS, etc. I don't frequent this forum anymore, please look for me elsewhere.
  • edited June 2011
    I remember noticing those open corners but I forgot to check them out. The walls could just be moved slightly to block them off.

    You can tell where you are in memory from these three coordinates:

    D1A1+1 = map segment
    D1A5+1 = current row
    D1A9+1 = current col

    The bugfix patch is situated at $F834 above the compiler code, whereas the map definitions are below the compiler code, so there'd be no overlap.

    I'll be incommunicado for a while as I'm off to have a hernia operation. Cheerio.
  • edited June 2011
    I could only play with level 3 last night, and this is what I discovered:

    LastSunsetForLattica-MAPworking-LEVEL3.png
  • edited June 2011
    What's that wrap-around method called again?

    Archimedian or Euclidian ? ... for some reason I want to have it named after the guy with the screwy water-screw ... and it's exactly because of that why I want to call it Archimedian ... because of the screw ... and it just makes sense in my head. Because I mean, the screw is screwy and so is the map ... err.
    ( No, it's you who is screwy! -Ed )
  • edited June 2011
    I remember noticing those open corners but I forgot to check them out. The walls could just be moved slightly to block them off.

    You can tell where you are in memory from these three coordinates:

    D1A1+1 = map segment
    D1A5+1 = current row
    D1A9+1 = current col

    The bugfix patch is situated at $F834 above the compiler code, whereas the map definitions are below the compiler code, so there'd be no overlap.

    Great, thanks for the information.

    I'll be incommunicado for a while as I'm off to have a hernia operation. Cheerio.

    Good luck!
    Creator of ZXDB, BIFROST/NIRVANA, ZX7/RCS, etc. I don't frequent this forum anymore, please look for me elsewhere.
  • edited June 2011
    ZnorXman wrote: »
    I could only play with level 3 last night, and this is what I discovered:

    Good work!

    I'm just afraid it's not clear how exactly the map wraps around. Instead of a text explanation, I suggest something more "visual" like this:

    6pb289.png
    Creator of ZXDB, BIFROST/NIRVANA, ZX7/RCS, etc. I don't frequent this forum anymore, please look for me elsewhere.
  • edited June 2011
    ZnorXman wrote: »
    What's that wrap-around method called again?

    Archimedian or Euclidian ? ... for some reason I want to have it named after the guy with the screwy water-screw ... and it's exactly because of that why I want to call it Archimedian ... because of the screw ... and it just makes sense in my head. Because I mean, the screw is screwy and so is the map ... err.
    ( No, it's you who is screwy! -Ed )

    It seems you refer to the Archimedean screw which is basically a water pump. However this invention is not directly related to the wrap-around concept so I'm not sure this is what you are looking for.

    Your sentence "the guy with the screwy water-screw" could also refer to Escher's graphical representations of waterfalls in a loop due to optical illusion, as if each waterfall was wrapping around.

    You also mentioned "Euclidian" which may refer to "Euclidian 2-torus", which is the most accurate term for the wrap-around used in games (left edge connects with right edge, south edge connects with north edge).

    For some reason, the first name that came to mind when I read your question was Moebius, regarding the Moebius ring concept that is a simple representation of this idea. Perhaps this is the name you are looking for?
    Creator of ZXDB, BIFROST/NIRVANA, ZX7/RCS, etc. I don't frequent this forum anymore, please look for me elsewhere.
  • edited June 2011
    It seems you refer to the Archimedean screw which is basically a water pump.

    That's exactly what I was thinking of! :-) (but I was also wrong in thinking that it was Archimedes.)
    You also mentioned "Euclidian" which may refer to "Euclidian 2-torus", which is the most accurate term for the wrap-around used in games (left edge connects with right edge, south edge connects with north edge).

    Yeah, I looked it up and the proper term I had in mind, once I found it, is:
    "Euclidian geometry"
  • edited June 2011
    Good work!

    I'm just afraid it's not clear how exactly the map wraps around. Instead of a text explanation, I suggest something more "visual" like this:
    [snip]

    Thanks, will put that in the update version.

    PS.
    I did check level 2 and saw that the player is bumped back in, so there is nothing new to be seen there. Interesting thing is that if you go SOUTH (of the far-left room in lvl 2) then you're bumped back from the room at the top of your position (the start room). While in lvl 3 if you do the same you get a larger area.

    Also ... was wondering if level three would have different mapping after those 11 screens on the bottom ... that is, if the game is played on different models (if possible), and also if it's random or not.

    Am checking that out now.
    More later as the news develop.
  • edited June 2011
    ZnorXman wrote: »
    Thanks, will put that in the update version.

    You are welcome!

    ZnorXman wrote: »
    Interesting thing is that if you go SOUTH (of the far-left room in lvl 2) then you're bumped back from the room at the top of your position (the start room).

    No, you are actually bumped back from the room at the top of level 3 (as expected).

    ZnorXman wrote: »
    Also ... was wondering if level three would have different mapping after those 11 screens on the bottom ... that is, if the game is played on different models (if possible), and also if it's random or not.

    Am checking that out now.
    More later as the news develop.

    Frankly I'm finding these flaws more interesting than the game itself. I can't remember any other Spectrum game with an "outside the map" area large enough to explore like this one. Can you?
    Creator of ZXDB, BIFROST/NIRVANA, ZX7/RCS, etc. I don't frequent this forum anymore, please look for me elsewhere.
  • I love this game and as an 11 year old spent many a rainy afternoon after a visit to the swimming pool with a packet of Salt and Vinegar Crisps, a Mars Bar, milky coffee (as we used to call it), and this game. Escaping the map was often fun, but often you get yourself in to a situation where there was no way back.

    Seeing this thread on Sinclair Computing: https://spectrumcomputing.co.uk/index.php?cat=96&id=2830
    I see that Einar has developed a patch to stop diagonal moves taking you to impossible locations.

    How does one apply this patch to the game to fix that bug. I am a purist when it comes to my ZX Spectrum and still load my games from tape. I'd like to apply a patch and then create a new tape.
    Calling all ASCII Art Architects Visit the WOS Wall of Text and contribute: https://www.yourworldoftext.com/wos
  • Scottie_uk wrote: »
    How does one apply this patch to the game to fix that bug. I am a purist when it comes to my ZX Spectrum and still load my games from tape. I'd like to apply a patch and then create a new tape.
    If you scroll down that page you will find a TZX file of a bug-fixed version. Just record it to a tape (or play the file from a PC/multimedia device) and load it into your Spectrum.
Sign In or Register to comment.