Jump to content

Photo

Minimap after getting map item on overworld


  • Please log in to reply
19 replies to this topic

#1 Twilight Knight

Twilight Knight

    Tell all with glee, Argon's on PureZC

  • Members
  • Real Name:Sven
  • Location:Rotterdam, NL

Posted 23 December 2020 - 11:50 AM

Hi everyone,

 

What I would really like is the minimap in the passive subscreen to show up only after collecting the map item on an overworld dmap. This normally works in dungeon and interior dmap types, but not on overworld dmaps it appears.

 

I am using a level number on the overworld dmap. If I change the type to interior or dungeon, the minimap does show after collecting the map item. So the issue really seems to be the overworld dmap type.

 

 

I did some searching on the forums and it seems that this is an intentional thing (but why?).

 

Does anyone know of some other possibility, such as changing the tile of the minimap via scripts?

 

 

I'm using the latest version of 2.55.

 

 

Thanks in advance,
TK


  • Lightwulf and Bagu like this

#2 Bagu

Bagu

    Fandomizer

  • Members
  • Real Name:A.I. Bot Bottomheimer
  • Location:Germany

Posted 23 December 2020 - 12:42 PM

What if you make a current item "dummy minimap" (not placed in active subscreen slot but on the passive subscreen).
Chose minimap tiles in the item editor and modify the item size, than use itembundle script to add the minimap dummy
when you pick up the map, you can get on the OW map.

Just an idea

It should work if properly placed under a true, transparent minimap


Edited by Bagu, 23 December 2020 - 12:44 PM.

  • Twilight Knight and Lightwulf like this

#3 Bagu

Bagu

    Fandomizer

  • Members
  • Real Name:A.I. Bot Bottomheimer
  • Location:Germany

Posted 23 December 2020 - 01:41 PM

Just checked it out, works fine.


  • Lightwulf likes this

#4 Twilight Knight

Twilight Knight

    Tell all with glee, Argon's on PureZC

  • Members
  • Real Name:Sven
  • Location:Rotterdam, NL

Posted 23 December 2020 - 01:45 PM

Hey, that's not a bad idea!

If I just use a certain item class for all the overworld maps I can give & take the appropriate item for the appropriate dmap.

 

That should work, thank you :-)


  • Lightwulf and Bagu like this

#5 Bagu

Bagu

    Fandomizer

  • Members
  • Real Name:A.I. Bot Bottomheimer
  • Location:Germany

Posted 23 December 2020 - 01:52 PM

Best is, to use position -1 for the current dummy map item, in the subscreen editor, otherwise zq will display the map on button item B...
(this will only appear in zq editor, not in zc player, but it's annoying. so, yeah... use position -1)


Edited by Bagu, 23 December 2020 - 02:17 PM.

  • Twilight Knight and Lightwulf like this

#6 Twilight Knight

Twilight Knight

    Tell all with glee, Argon's on PureZC

  • Members
  • Real Name:Sven
  • Location:Rotterdam, NL

Posted 23 December 2020 - 02:25 PM

Thank you, that was annoying me indeed!

But I just fully tested and implemented it

For others, these are the scripts I made for this:

dmapdata script add_overworld_minimap {
  void run() {
	RemoveOverworldMinimaps();
  
	if(Game->LItems[Game->GetCurLevel()] & LI_MAP) {
		AddOverworldMinimap();
	}
  }
}

const int O_MAP_DEFAULT = 181;
const int O_MAP_W1 = 180;

const int O_LVL_W1 = 14;


void RemoveOverworldMinimaps()
{
	Link->Item[O_MAP_W1] = false;
	
	Link->Item[O_MAP_DEFAULT] = true;
}

void AddOverworldMinimap()
{
	Link->Item[O_MAP_DEFAULT] = false;
	
	if (Game->GetCurLevel() == O_LVL_W1) {
		Link->Item[O_MAP_W1] = true;
	}
}

In my case I also have a default map background for the overworld.

Then like Bagu said, create items sharing the same item class (in my example the IDs of said items are 180 and 181). Make their tilewidth 5 and tileheight 3 and pick the tiles for the map. Place that item class as a Current Item on your passive subscreen under your minimap (by placing it underneath, you still get the Link & compass markers) and you should be done.


Thanks again Bagu it was a great idea.


  • Lightwulf and Bagu like this

#7 Bagu

Bagu

    Fandomizer

  • Members
  • Real Name:A.I. Bot Bottomheimer
  • Location:Germany

Posted 23 December 2020 - 02:34 PM

Thank you, too.
btw, intressting script  :thumbsup:


Edited by Bagu, 23 December 2020 - 02:35 PM.

  • Twilight Knight and Lightwulf like this

#8 Emily

Emily

    Scripter / Dev

  • ZC Developers

Posted 23 December 2020 - 08:23 PM

Would setting these not work?

unknown.png

If these are tile 0, it uses a default; if you set one of these to any other tile, it should forcibly use that. So, setting the `Without Minimap` to a blank set of tiles should remove the map without a minimap.


  • Twilight Knight and Lightwulf like this

#9 Twilight Knight

Twilight Knight

    Tell all with glee, Argon's on PureZC

  • Members
  • Real Name:Sven
  • Location:Rotterdam, NL

Posted 24 December 2020 - 06:08 AM

Hmm, that would also be a possibility.

Your suggested approach is to have a default minimap which is the actual map graphic & set the "Without map" to a blank set of tiles which should disappear once the player gets the map, right?

I don't think it will work, since that "Without map" minimap does not disappear once you get the map item. Also I (will) have many overworld maps in my quest so I'd need to create many different passive subscreens to make it work. Unless I don't fully understand what you are saying.

 

But thank you for the help!


The solution Bagu proposed is working very well though.

By now I simply draw the default overworld map on the passive subscreen, and I set the dummy item with a dmap script like described above. If you also set the default minimap with a dummy item, like I did before, it could look weird on screen transitions.

 

And the dungeon and interior minimaps are still working as normal


Edited by Twilight Knight, 24 December 2020 - 06:09 AM.

  • Lightwulf and Bagu like this

#10 Emily

Emily

    Scripter / Dev

  • ZC Developers

Posted 24 December 2020 - 10:40 AM

I don't think it will work, since that "Without map" minimap does not disappear once you get the map item. Also I (will) have many overworld maps in my quest so I'd need to create many different passive subscreens to make it work. Unless I don't fully understand what you are saying.

You don't fully understand.

You set this for each DMap, not each Passive Subscreen.

Under "Without Map", you set "Minimap" to blank tiles (which are NOT tile 0).

Under "With Map", you set "Minimap" to what you want the minimap background to look like.

The passive subscreen should just do what it has always done, with the Minimap object just on the subscreen.


  • Lightwulf and Bagu like this

#11 Bagu

Bagu

    Fandomizer

  • Members
  • Real Name:A.I. Bot Bottomheimer
  • Location:Germany

Posted 24 December 2020 - 11:02 AM

Would setting these not work?

unknown.png

If these are tile 0, it uses a default; if you set one of these to any other tile, it should forcibly use that. So, setting the `Without Minimap` to a blank set of tiles should remove the map without a minimap.

Just checked it out, the minimap didn't change after getting the Map on OW (set to Lvl 1).


  • Lightwulf likes this

#12 Emily

Emily

    Scripter / Dev

  • ZC Developers

Posted 25 December 2020 - 11:48 PM

Really? Even when you set the minimap under both "Without Map" and "With Map" tabs?


  • Lightwulf and Bagu like this

#13 NoeL

NoeL

    Legend

  • Members
  • Real Name:Jerram

Posted 26 December 2020 - 01:38 AM

Does the ow subscreen need a slot to display the map to register that Link HAS the map? That could be why, or maybe maps just don't work on overworlds.
  • Lightwulf and Bagu like this

#14 Lüt

Lüt

    Germanize

  • Members
  • Real Name:Steve
  • Location:Chicago

Posted 26 December 2020 - 03:01 AM

I could never get the overworld minimap to change the last time I tried, whether using subscreen defaults or custom dmap settings.

 

Which, admittedly, was over a year ago.

 

But I was also led to the same conclusion, that it was intentional, perhaps in the same way that you can't click the on-map squares for an overworld dmap type like how you can click them for a dungeon dmap type, so I never made a bug report out of it.

 

It would be nice if the custom with/without map selection would work, though. It would be good for illustrated minimaps.

 

Also, I'm not sure it has anything to do with the subscreen having a map slot, because the large map will change on an overworld dmap if you pick up the map item after defining custom with/without map selections for that dmap, so the subscreen will process the map item without having a slot for it. But somehow that processing stops with the large map and doesn't reach the minimap, so maybe there's a split between active and passive subscreen item processing, and adding the item slot to the active subscreen would cause it to filter down to the passive subscreen? It's really just conjecture, and I suppose somebody could experiment, but it's probably best for somebody familiar with the code to have a look and give an exact explanation.


  • Lightwulf and Bagu like this

#15 Emily

Emily

    Scripter / Dev

  • ZC Developers

Posted 26 December 2020 - 04:02 AM

This sounds like a bug report waiting to happen to me.

I feel like it's more likely just a hardcoded bug with minimaps.

 

EDIT: Yes, it's a hardcoded bug with minimaps.


  • Lightwulf and Bagu like this


0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users