Showing image instead of map

I am trying to disable the map on my game for certain rooms and I have this figured out but it leaves a half the screen completely blank and unusable for the game script to display in, either I want this to be removed so the full page can be displayed or that I can display a specific image on it instead.

So this is for the Game "Script when entering a room" to disable the map I'm currently using.

JS.eval ("$('#gridPanel').css('display', 'none');")

It might be possible to do something like:

JS.ShowGrid(0)

(using the built-in function to hide the map and resize the text area)

Or :

JS.eval ("$('#gridPanel,#gamePanelSpacer').css('display', 'none');")

(hides both the map canvas, and the spacer that prevents text overlapping it)

Or:

JS.ShowGrid (0)
SetFramePicture("some picture.jpg")

which displays a picture in the frame. There's actually an option on a room to specify a room picture which is displayed while the player is in the room; but it will only work if the grid has been disabled using ShowGrid (0) because it uses that to check whether there is space or if it's taken up by the map.


I keep seeing this error everywhere, I have non-directional exits but is it because I'm using MoveObject() to move the player around that's causing me to see this because I'm not using the Exit itself for navigation?
Error running script: Error evaluating expression 'DictionaryItem(coordinates, coordinate)': The given key was not present in the dictionary


I keep seeing this error everywhere, I have non-directional exits but is it because I'm using MoveObject() to move the player around that's causing me to see this because I'm not using the Exit itself for navigation?
Error running script: Error evaluating expression 'DictionaryItem(coordinates, coordinate)': The given key was not present in the dictionary

The map works out the coordinates of each room using directional exits. If it doesn't have any, it doesn't know where to put rooms on the map.

If you don't want exits but you want to use the map, there's 2 ways to do it:

  1. Make directional exits, and make them invisible
    (The player can't see or go through an invisible exit, but the map will still use it for working out where to draw any adjacent rooms)

  2. Manually set the coordinates of each room using commands before you move the player there
    Something like:
    Grid_SetGridCoordinateForPlayer (game.pov, room name, "x", 12)
    For each room you need to set x (1 is east of 0), y (1 is south of 0), and z (1 is up from 0).


This topic is now closed. Topics are closed after 60 days of inactivity.

Support

Forums