Navigation
Options
Post Reply
Username:
Verification:
Subject:
Message: [quote author=Kolya link=msg=22662 date=1292711601] [color=#FFCC00][html]<a name="automaps">ShockEd Automaps - Zygoptera</a>[/html][/color] [html]<b>Introduction</b><br /> <br /> The original files available with either Shock2 or Thief2are an invaluable resource- They may be found in..\intrface.crf\<EM>LevelName</EM>\<EM>language</EM>\.. as a series of graphics files and .bin files. If something I've written confuses then try looking at them as they may help to illustrate what I'm trying to say.<br /> <br /> <b>Making a Basic Map</b><br /> <br /> Suggested method:<UL> <LI>Enlarge top-down view in ShockEd by dragging the sliders <LI>Select filter and remove lights, objects and rooms. <LI>Zoom out until the map fits onto screen <LI>Use a screen capture program to take a snapshot <LI>Make walls and blank spaces one colour each. It is probably sensible to resize the image at this point so that it fits the map parameters <LI>Erase non-space defining walls. <LI>End image size should be 614x260x8bit. Larger or smaller size will work, but with problems <LI>Save file as Page001.pcx and place in path ..\sshock2\intrface\english\<EM>MyMisName</EM>. If making an automap save as Page001a.pcx </LI></UL>For a really basic map, and if you do not want it to be an automap this should be enough. Getting to this point should take about anhour, depending on competence with the paint programs and size of the level.<br /> <br /> <H4>A few notes and observations on making the basic map:</H4><UL> <LI>If you want to make an automap it is important to resize the map to its correct size at the right time. Writing and thin walls especially may scale oddly or be lost <LI>Palette entry #1 is the transparent colour, which in PSP defaults to pure black. If the "no map data" shows up through your map this is the probable reason. <LI>For insets, use area brushes first to isolate the area for the inset and then use screen capture. It is best to keep all screenshots to the same scale, especially if an automap is planned. <LI>Use the same palette for all files in each folder </LI></UL><b>Making an Automap</b><br /> <UL> <LI>If you find that your level is orientated the wrong way relative to the automap there is a "map rotate hack" under the mission parameters of the editor menu. <LI>Make named room brushes, typically by opening up the object hierachy, selecting rooms from the dd menu, clicking on default room and then new, naming them and clicking create. Each new subtype defines an automap area <LI>Make a "blank" version of the basic map. Save as Page001.pcx <LI><STRONG>Complicated, see examples</STRONG> <UL> <LI>Draw boxes around automap sections as defined by the rooms (alternatively define the rooms based on the automap) using palette entry 254. Best to edit the palette so that colour 254 is an obvious colour, typically either bright green or pink. I used bright yellow. <LI>Fill in the section around the "map parts" with palette entry 1, which makes the surrounding areas transparent. <LI>The fill must go over any bits of the map which are outside the appropriate automap section. <LI>The boxes may not overlap <CENTER><IMG src="https://www.lgclassics.net/sec/images/mapexample.gif" align=absBottom vspace=20 border=1 width="217" height="290"><IMG src="https://www.lgclassics.net/sec/images/map2.gif" align=absBottom vspace=20 border=1 width="223" height="290"> </CENTER> <LI>Save as p001ra.pcx <LI>Repeat steps until all automap sections are defined. Save file as p001ra/b/c.. sequentially. </LI></UL> <LI>Run cutout.exe from the LGS mapping tools (available in the Resources section of ShockEd Central) from either the run dialog or DOS box with the usage "cutout p001ra.pcx ..", with all the p001r_ you made listed after p001ra. <LI>Run makerect.exe (also in LGS mapping tolls) with the same usage. <LI>To make the areas light up as you enter them copy p001ra.bin (made by makerect) and rename to p001xa.bin. Then copy all the files generated by cutout.exe (p001r000.pcx etc.) change as desired and rename to p001x000.pcx) <LI>Add the property gamesys..map loc to the rooms of your level and number them equivalently to the cutout generated versions, for example p001r004 would be map loc 4. </LI></UL><b>Getting the automap to work</b><br /> <UL> <LI>In ShockEd, create two markers at obvious positions, <EM>but not in inset areas</EM> <LI>Find the marker's place on the automap graphic and note their x,y coordinates (at bottom right in PSP for example) <LI>Give the two markers the property obj..map ref info and enter the x,y coordinates into them. Set frame to -1 <LI>To get insets to work, create a single marker in each and give it the map ref info property. Fill in the x,y as appropriate from the graphic and set the frame# to the same as the room number of the inset. </LI></UL>This should give a working automap and allow the player cursor to appear. There are also several Thief based tutorials available at DromEd Central, though not all information is relevant to Shock.<br /> [/html] [b]Addendum[/b] (ZylonBane) If you just need to make an adjustment to an existing automap section's position, it's not necessary to go through the entire process described above. It's fairly easy to hex-edit the generated BIN files directly. The format is very simple: There is one record for every map area in the BIN file, stored sequentially. Each record is 8 bytes, and contains four values, stored as little-endian 16-bit numbers: [list] [li]X coordinate of the upper-left corner[/li] [li]Y coordinate of the upper-left corner[/li] [li]X coordinate of the lower-right corner[/li] [li]Y coordinate of the lower-right corner[/li] [/list] To perform the editing, I recommend [url=http://www.chmaas.handshake.de/delphi/freeware/xvi32/xvi32.htm]XVI32[/url]. For this task it has an essential feature called "Data Inspector" that will display the value of 16-bit numbers. [/quote]
Back to topic
Legal stuff