Jump to content
SubSpace Forum Network

Recommended Posts

Posted

When you get elvl support can you use a script based system for the chunks? This way ASSS module coders can just write a new human readable script to create new custom region types.

 

Example contents of a script file for the existing autowarp region:

rAWP
x:16:X coord in tiles to warp to.
y:16:Y coord in tiles to warp to.
arena:char16:Destination arena or blank for same arena.

 

New custom lvz toggling region:

rTOG
id:16:The ID of the object to toggle.
mode:16:0=Toggle lvz off when you enter the region, 1=Toggle lvz on when you enter the region.

 

The first line will be the region type, all following lines are fields inside the chunk.

field name:field data type:description of field

 

The data types can be:

8,16,32,charN where N is an integer greater than 0,charZ for null terminated strings of varying length.

 

Of course you will have to create the GUI dialog box on the fly to edit these chunks.

Posted

I'll explain in more detail from starting from an ASSS perspective.

 

Abitrary areas can be defined on the map called regions, each one must be named (such as "northbase"). They can be any shape, even multiple shapes that are not linked/touching in the same region.

 

Regions also have a type as well as a name. There are several types that already come with ASSS, for example the autowarp type has the effect of *warpto when you enter it. The destination coord's of the *warpto are encoded inside the lvl file.

 

New types can be created by anyone, for example a lvz object toggling type. So when you enter a region a lvz object will either be turned on (such as an image saying "no antiwarp in this area"), or turned off (such as a roof in battlefield). The problem with creating new types is you need an editor to support them. The lvz object ID needs to be easily configurable from inside the editor and the editor needs to know how to write the encoded region to the lvl file.

 

This is where the script comes in. The script defines the structure of the encoded data and also provides some verbose information to help the editor generated a piece of UI to edit the region's attributes (lvz object id).

 

I already requested this in !@#$%^&* but it never got put in.

Posted

that sounds fun.... as soon as we're done with the standard mapping features, we'll start adding these kind of things

 

and i dont know anything about ASSS either, so we'll have to study some before blum.gif

Posted

I still don't get it. I know about regions but what is this script you mention and how is it related to DCME?

 

Do you want DCME to basically just embed some "scriptfile.!@#$%^&*S" files into the lvl?

Posted

DCME would parse the script to:

1) Generate a UI to edit the attributes the region requires.

2) Write out the region data using structure defined in the script and values which the mapper will have entered into the new piece of UI.

 

DCME will not simply copy/paste this script into a lvl.

 

By structure I mean things like "write the value of the X-Coord using a 32bit integer at offset 2".

Posted
So... you're just saying DCME should support ASSS areas and related functionality?

 

thats what i understood

 

 

 

but at the moment, are these scripts thingys "in" the lvl file? how are they put in there for now? or are they written separatly in some text file, and then some compiler includes them in the lvl? or something?

Posted

Bleh. The script is created by anyone who wants to make a new type of region. DCME can ship with scripts for all the regions that ASSS already supports. What I'm saying is I or anyone else should be able to create a new script/definition file to define a new type of region.

 

If you want to see something like this already have a look at my font sheet maker at http://toktok.sscentral.com/ss-other.html It supports scriptable definition files to change the layout of the generated font sheet. By changing the .def file you can generate the font sheet with all the accented characters or a font sheet suitable for pasting into a tile set.

 

The script does not get put inside the final .lvl file in anyway at all. It merely defines the structure of the region's attributes (a region is just one type of chunk that can be embedded inside an elvl). In hindsight I suppose a better topic !@#$%^&*le would be "Custom region attributes in elvl's via script/definition files".

Posted

i think i should create a DCMEproj file where everything is stored in :/

 

so everything would be

 

- tileset

- lvl

- lvz stuff

- ASSS stuff

- state (like position, bookmarks, and other setted stuff)

 

and then have a "compile lvl file" menu item :/

(or compile lvz or elvl, you know what i mean)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...