Jump to content
SubSpace Forum Network

Recommended Posts

Posted

Walltiles are almost done! smile.gif

 

You can now convert a selection to one of the walltiles set you selected (You can create up to 8 sets).

There are options that allow you to allow the conversion to include special tiles, such as doors, flags, safety tiles, goal tiles, fly over tiles, fly under tiles, extra tiles, or small asteroids tiles.

 

You can not yet use any tools with the walltiles, but that should be done soon smile.gif

 

You can use partial sets, which means that if you don't set a tile for every tile of the set, it will not convert any tile to that tile and will just leave it as it is.

 

Feel free to try it out and report problems with it

 

What I would like to do with them next:

  • Use walltiles with any tool
  • Save / Load walltiles configuration
  • Save walltiles configuration when saving the map

As for the walltiles interface, I'm not very sure how to place the things, it just doesnt seem to fit well... if you have any idea on how it could be placed, tell me blum.gif (maybe if I make it able to handle 9 sets, I could place them 3x3... then it might fit....... mmmmm... )

 

[attachment removed , please check 'Latest build' thread]

Posted

wow that definately came out of nowhere ;) , you didn't even tell me blum.gif . And yes tortoise deletes it if it's not on the repository anymore.

 

Do you have any slowdown with it or anything ?

 

 

gah, you screwed up my menu icons.

 

Just checked it, wicked smile.gif good job. (plz ... ... comment, its hard to understand without comments -_-)

Posted

Okies, i did some work on it too ;)

 

I've added a Save and Load walltiles in the edit walltiles menu (still unhandy but at least you can save them)

 

I've added a button to enable/disable walltiles when drawing each tool

(actually pretty easy to do, just did the walltile check at the setTile of the map ^^')

 

Todo: save a copy of the walltile with like Map_walls.wlt in the directory of DCME, and auto-load walltiles if a wlt file exists with the map that is opened.

Also use a default.wlt for the default tileset.

 

Other todo's:

need to fix undo/redo for selection.

Drawing over selection still shows the drawn tiles, although they jump under them after a updatelevel (don't draw any tiles when a selection is active on those tiles and you started drawing outside the selection).

Need to optimize a bit

 

Another bug: when using a secondary walltileset, and you draw with the secondary walltileset, and you hit the first walltileset, it'll change those tiles too :/

 

Also, i can't seem to assign walltiles to the right column :/

 

so sama, before you continue, update from the repository

Posted

yeh.. i wasnt to the 'comment' part yet ;) lol

 

and yes, your menu icons got moved up... didnt know how to fix those

 

so.. er... i'll update.. and comment ;) i don't know if you noticed how I made it check which wall-tile to use... i've had that cool idea and it probably speeds up the process a lot...

i add 1 if a tile is on the right, i add 2 if a tile is over, i add 4 if a tile is on the left, and i add 8 if a tile is under...

when adding these up, you get a number from 0 to 15, corresponding directly to the walltile

of course, when setting the wall-tile, each tile has to be !@#$%^&*igned the correct number.. so.. anyways..

 

and yes, I was tired of having the wall-tiles on the to-do list blum.gif

 

 

Off-topic: I cleaned the suggestions/bugs thread, and I rearranged the 'builds 1.1.*' and 'latest build' threads, so that all the links to the 'latest build' thread still points to that thread... that link was posted on many forums and it might have caused some users to download the 1.1.11 build as the link was heading to that thread...

Posted

i didn't really looked in-depth at your code for walltiles, i just copied the code that generates walltiles from the selection, and changed it a bit when added to setTile. (still need to do a boundary check there too :/)

 

But yeah, 1 2 4 8 is commonly used, like the msgbox vbokcancel+vbexclamation or such is also based on the bit value's of that sum

Posted

yeh... the walltile now propagates to all the tiles it finds... maybe its not a good idea to put that in settile blum.gif

well, 'propagate walltiles' would be a nice option... maybe set a limit to the propagation.. like 1 tile would change the tiles just beside where you put a walltile... hm...

 

we need to be able to make it preview correctly when dragging a rectangle for example.. that might be hard

Posted

it only checks its neighbours when its value has been changed. and when walltiles is off it skips the whole part so there shouldn't be too much slowdown

 

 

Btw: maybe you could stretchblt the walltileset pictures to the tiles on the tileset right of the tile 0.

And when the user select a walltile, then use walltiles automaticly.

Posted

fixed some wall tiles issues... I limited the spreading of walltiles to only one tile, but its still not ideal... it shouldnt change the tiles beside the ones you are currently drawing

 

Applying a selection while using walltiles doesnt change everything to walltiles either

 

Fixed converting a selection to walltiles when your walltiles include special tiles, however, there is still a problem when drawing using special walltiles, as they are considered 'not validforwalltile'

 

To fix these problems we'd need to recode drawbaseline... shouldnt be too hard I guess

 

 

Everything's on the repository

 

Edit: wow.. tortoiseSVN's merging feature is nice... there was something in settile you had done and i hadnt uploaded it... and I changed things in settile as well.. it merged everything nicely..hm

 

And check out this default walltile template I done (!@#$%^&*, that default tileset really sucks, there's not a single 'T' tile...) I checked how they tiled the default map that comes with the server, and came up with these different patterns. 2 of them are used for 2-tiles-large pillars, so if you make walls with them its ugly.

Default_walltiles.zip

I don't know exactly how we could integrate that data in dcme (no we won't ship default.wtl with the editor, its annoying blum.gif ) ... only way I can think of is manually enter each of the values... (or create some leet macro that writes them on an Excel sheet, then we just copy-paste... heh that'd be nice)

 

I'll make an option for 'default walltiles template' , just like the default tileset.

Posted

dunno if i've said this before, but when the map is saved also create a walltile with the map name in the directory where the lvl file is (option to turn that off too).

 

Then when using openmap, check for the wlt file, if there is one, auto-load that walltile too.

 

And yes, limiting is a good idea as else it will give an out of stack space error.

 

 

(did a quick fix on some toolbar buttons and menu items not properly disabled/enabled)

Posted

yes u've said that before :D

 

 

...ooh.. nice sig!!!!.... wha lol......

 

lmao!!!!!1 now you can really map your !@#$%^&* off !!! hahahaha

 

 

the samples are kinda dark though (text and picture) .. should make them with light tiles smile.gif

Posted

won't that be conflicting with continuum ?

 

i mean, continuum reads to the end of the lvl file and interprets every 4 bytes as a tile with its x,y coordinates and its value. Tile 0's arent saved so the lvl file is always variable in size. There isn't an offset that can be used. (The tileset is saved as bmp format in the beginning, and continuum reads the header of the bmp to determine the size of the bmp, then seeks to the first byte after the bmp length and starts reading till the end of the file)

Posted

Well, the answer is right in your post :D

 

continuum reads the header of the bmp to determine the size of the bmp

 

What if you lie in the header? Aha! You can make it skip past some hidden data! Like walltiles! smile.gif

 

(Requires that the map has a tileset, of course. I recommend you simply always include the tileset, even if default, when going this route. Nobody really uses default, so it would not matter to most people.)

Posted

depends if i want to make a DCMEproj from all the stuff, then lvz stuff can be as resources in the directory where the project is, same for walltiles.

 

I'll try putting walltiles in the lvl file, but i hope that doesn't do anything nasty with continuum

Posted

but... if you lie in the bmp header... wont it screw up when importing the lvl file in another map to use its tileset? what will it do when you open the lvl file in an image editor?

 

 

walltiles now work with tools 'almost' perfectly... for now they just don't preview correctly

but it works with rectangle, ellipse, filled rect/ellipse, line, pencil, polyline

i might try to make it work with bucket (after I get the preview to work)

Posted

WOOHOO!

 

Full functionnality of walltiles smile.gif

 

They can now be selected just like any other tile

If you double-click on them on the tileset, it brings you to the Edit walltiles... window

The walltiles button in the top toolbar now brings you to Edit walltiles... instead of toggling use of walltiles (since there are now two booleans indicating use of walltile, one for left tile , and one for right tile)

Therefore, you can select 2 different walltiles set at the same time, and draw one with left button, the other with right button

 

Woot... Bucket fill now works very well with walltiles, when filling a selection or not.

 

Everything also works with different linewidths

 

Things to do eventually:

  • Option for a default walltile template being loaded
  • Load the default tileset's walltile template automatically
  • Clean up the code for walltiles... its kinda spread in the tools classes.. it should be grouped in the walltiles class
  • Make the .wtl save with the map (or into it?)

[attachment removed , please check 'Latest build' thread]

Guest
This topic is now closed to further replies.
×
×
  • Create New...