Author Topic: extracting Cheapo graphics  (Read 37605 times)

0 Members and 1 Guest are viewing this topic.

Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #45 on: February 07, 2015, 06:46:18 AM »
Also, I notice that the extracted width/height of images are 1 higher than the actual width/height (eg: for a terrain piece that's 32 pixels wide, the width in the XML file will be listed as 33). This applies to both terrain pieces and object frames; not sure about anything else.

Oops! I can fix that bug in the style extractor soon, you shouldn't have to deal with that bug. Sorry.

Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #46 on: February 07, 2015, 06:52:41 AM »
...Cheapo level conversions are going to require some manual touching-up anyway - NeoLemmix is probably the closest currently-used engine to Cheapo mechanics-wise, but there are still a lot of differences).

But, to show that I'm getting somewhere; here's a saved gameplay image showing a Cheapo graphic set being used in NeoLemmix (note the Swimmer, which is not found in Cheapo).

That is really cool!

By the way, I started on a level/set data extractor program that will act like the style extractor program. It will extract all of the levels into .png files and all of the level data into an .xml file (the data is the release rate, tool count, object placement, etc).

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #47 on: February 07, 2015, 09:58:07 AM »
Awesome! Will it also work on compiled sets?
My Lemmings projects
2D Lemmings: NeoLemmix (engine) | Lemmings Plus Series (level packs) | Doomsday Lemmings (level pack)
3D Lemmings: Loap (engine) | L3DEdit (level / graphics editor) | L3DUtils (replay / etc utility) | Lemmings Plus 3D (level pack)

Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #48 on: February 07, 2015, 02:04:08 PM »
Awesome! Will it also work on compiled sets?

Yes

Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #49 on: February 10, 2015, 04:47:54 AM »
Also, I notice that the extracted width/height of images are 1 higher than the actual width/height (eg: for a terrain piece that's 32 pixels wide, the width in the XML file will be listed as 33). This applies to both terrain pieces and object frames; not sure about anything else.

Oops! I can fix that bug in the style extractor soon, you shouldn't have to deal with that bug. Sorry.

I think I fixed the bug. You can download the style extractor again and the sprite sizes should be correct.

Offline Wafflem

  • Posts: 943
    • View Profile
Re: extracting Cheapo graphics
« Reply #50 on: February 13, 2015, 03:34:40 AM »
But, to show that I'm getting somewhere; here's a saved gameplay image showing a Cheapo graphic set being used in NeoLemmix (note the Swimmer, which is not found in Cheapo).

Sorry if this is off-topic but Cheapo-related, but will this become a level for one of your future packs?
YouTube: www.tinyurl.com/YTWafflem
Twitch: www.twitch.tv/Wafflem467

Have level designer's block right now? Have some of my incomplete levels for LOTS of ideas!

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #51 on: February 13, 2015, 04:08:26 AM »
But, to show that I'm getting somewhere; here's a saved gameplay image showing a Cheapo graphic set being used in NeoLemmix (note the Swimmer, which is not found in Cheapo).

Sorry if this is off-topic but Cheapo-related, but will this become a level for one of your future packs?

Nope, I just made it to test the graphic set's functionality. I would upload the level, except that it relies on a feature which isn't implemented in current versions of NeoLemmix (specifically, having multiple window objects in a single graphic set). Before I release the update with this, I want to make sure everything needed for Cheapo is supported; in turn this will most likely mean it won't happen until after the level extractor is done, and I make a convertor.
My Lemmings projects
2D Lemmings: NeoLemmix (engine) | Lemmings Plus Series (level packs) | Doomsday Lemmings (level pack)
3D Lemmings: Loap (engine) | L3DEdit (level / graphics editor) | L3DUtils (replay / etc utility) | Lemmings Plus 3D (level pack)

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #52 on: February 13, 2015, 05:02:51 AM »
To give an update on the one-way arrow situation: I'm still not entirely sure how I'm going to handle it in levels. Functionality-wise, it's as simple as a modification to steel areas to also allow them being set as one-way areas; graphically might be a bit trickier to implement.

However, as far as making them exist in graphic sets go, I've added code which generates them from the images in the Standards.png file. This provides left and right one-way arrows. I'm still working on some code to also create one-way down arrows. (For those who aren't familiar with NeoLemmix, one-way down arrows can't be bashed, but can be dug, or mined in either direction.)

EDIT: One-way downs are now created properly too. One thing I did have to take into account is that a Cheapo graphic set can have a (virtually) unlimited number of object types, whereas NeoLemmix is limited to 32. So, LemSet will only convert the first 32 objects of a graphic set. If there's at least two spaces left, it'll make one-way left and one-way right arrows too; and if there's still one space left, it'll also make one-way down arrows.

EDIT: At a functional level, I have the arbitrary one-ways working. They're currently invisible, though - that's the next thing to work on.
« Last Edit: February 13, 2015, 06:11:50 AM by namida »
My Lemmings projects
2D Lemmings: NeoLemmix (engine) | Lemmings Plus Series (level packs) | Doomsday Lemmings (level pack)
3D Lemmings: Loap (engine) | L3DEdit (level / graphics editor) | L3DUtils (replay / etc utility) | Lemmings Plus 3D (level pack)

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #53 on: February 13, 2015, 06:55:13 AM »
Okay, I'd say NeoLemmix is ready to accept Cheapo input! :D (Of course, not directly; it'll have to be first extracted with Essman's tool then run through a special conversion tool - both of which have yet to be made. Even after this, I suspect many levels will need manual touching up. But, it'll make the process a LOT easier. The point is; the NeoLemmix engine is now in a state of being able to accept converted Cheapo levels as close to their original form as possible.)

One drawback of the arbitrary one-way walls is that using actual objects for them would be almost impossible; rather, it just sets a one-way wall trigger area on the affected pixels, and hard-draws the one-way arrows onto the terrain there (it won't draw them in thin air of course, only on pixels that are actually terrain). The main effect of this is that the one-way walls set this way won't be animated. This won't matter much when using Cheapo styles, as the one way arrows don't animate there anyway; but for this reason I'll recommend continuing to use the objects rather than the arbitrary areas when making new levels.


For the record, it'll be (obviously) just as compatible with custom Cheapo styles as official ones, as long as they don't use any of the following types of objects:
- Triggered exits (these will work, but won't have the one-lemming-at-a-time effect)
- Two-way teleporters
- Single-object teleporters (teleporter and receiver in one)
- Splat pad
- Gravity changers

Additionally, levels with upside down entrances won't work properly (as NeoLemmix doesn't support inverted gravity).

Teleporters, Receivers and Anti-Splat Pads are fine; NeoLemmix supports the first two properly, and Updrafts are similar enough to the last one to replace them for most purposes.
« Last Edit: February 13, 2015, 07:01:02 AM by namida »
My Lemmings projects
2D Lemmings: NeoLemmix (engine) | Lemmings Plus Series (level packs) | Doomsday Lemmings (level pack)
3D Lemmings: Loap (engine) | L3DEdit (level / graphics editor) | L3DUtils (replay / etc utility) | Lemmings Plus 3D (level pack)

Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #54 on: February 13, 2015, 07:47:46 PM »
Okay, I'd say NeoLemmix is ready to accept Cheapo input! :D (Of course, not directly; it'll have to be first extracted with Essman's tool then run through a special conversion tool - both of which have yet to be made. Even after this, I suspect many levels will need manual touching up. But, it'll make the process a LOT easier. The point is; the NeoLemmix engine is now in a state of being able to accept converted Cheapo levels as close to their original form as possible.)

I'm almost done with my level & set extractor. It works just like the style extractor.
Here is the latest version that just extracts level maps, not objects or other stats yet:

https://github.com/spadapet/cheaplevel/blob/master/Publish/CheapLevel.zip?raw=true
(the latest version will always be at that link)

And also, the source code is on github for anyone that cares:
https://github.com/spadapet/cheaplevel

Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #55 on: February 17, 2015, 02:53:40 AM »
I'm almost done with my level & set extractor. It works just like the style extractor.
Here is the latest version that just extracts level maps, not objects or other stats yet:

https://github.com/spadapet/cheaplevel/blob/master/Publish/CheapLevel.zip?raw=true
(the latest version will always be at that link)

And also, the source code is on github for anyone that cares:
https://github.com/spadapet/cheaplevel

OK I'm done with the set/level extractor now (download from the previous link above).
It extracts all of the level graphics into .png files and the level and set info into .xml files. The level info includes all of the object and box locations. The set info is just the name and list of levels.

This is all done through UI, but if anybody needs a different way to extract the info (like command line or .NET API), I can help.

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #56 on: February 17, 2015, 03:26:59 AM »
I'll take a look at this when I get home and let you know if there's any changes that'd help, though it should be fine (unless its bugfixes that are needed).

EDIT: Checking it out now.

EDIT: (Still assuming a lack of any needed bugfixes), I'd say this will be more than adequate. :)

I'll probably do a test run of converting a few levels, then release a player with those and give people a chance to test it out and see if any issues stand out. If you don't mind, I'd like to use your converted levels from your first clone for this purpose - it gives a good number of levels that are fairly standard (before worrying about more advanced things).

One thing that would help, though I can live without if need be (and this might have to be the case depending on the level format) - is there any chance that the level XML files could contain info on what *type* of object each object is? If this can't be done, I can always get around this by asking for a copy of the style to also be present in the folder when running a conversion, and checking the object indexes against that. It's just that this may be nessecary to get proper functioning of certain objects, in particular windows and teleporters.

EDIT: One minor detail - is it possible to have an option to *not* open the folder after extracting, and perhaps also to not auto-close the app? This would be useful when wanting to extract multiple styles / level sets at a time.
« Last Edit: February 17, 2015, 04:37:48 AM by namida »
My Lemmings projects
2D Lemmings: NeoLemmix (engine) | Lemmings Plus Series (level packs) | Doomsday Lemmings (level pack)
3D Lemmings: Loap (engine) | L3DEdit (level / graphics editor) | L3DUtils (replay / etc utility) | Lemmings Plus 3D (level pack)

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #57 on: February 17, 2015, 04:42:06 AM »
Okay, I found one bug so far just by looking through extracted XML files - it doesn't seem to extract the starting Y position properly; instead it sets it to the same as the starting X position.
My Lemmings projects
2D Lemmings: NeoLemmix (engine) | Lemmings Plus Series (level packs) | Doomsday Lemmings (level pack)
3D Lemmings: Loap (engine) | L3DEdit (level / graphics editor) | L3DUtils (replay / etc utility) | Lemmings Plus 3D (level pack)

Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #58 on: February 17, 2015, 05:01:04 AM »
Okay, I found one bug so far just by looking through extracted XML files - it doesn't seem to extract the starting Y position properly; instead it sets it to the same as the starting X position.

Poop. I'll fix that....

Ok I fixed it.

Yes you can use my original levels as test levels, that would be cool and I'd like to play them again someday with a clone that actually works.

As for not showing UI, I made a solution for that:
With the level extractor program, use the command line to pass in two parameters: The level/set file and the output directory. If they are both set, then no UI will be shown.
The level/set extractor download has been updated, but I didn't do the command line option for the style extractor yet (that'll be tomorrow at the latest).

Thanks

Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #59 on: February 17, 2015, 05:03:39 AM »
One thing that would help, though I can live without if need be (and this might have to be the case depending on the level format) - is there any chance that the level XML files could contain info on what *type* of object each object is? If this can't be done, I can always get around this by asking for a copy of the style to also be present in the folder when running a conversion, and checking the object indexes against that. It's just that this may be nessecary to get proper functioning of certain objects, in particular windows and teleporters.

Yes I can do that by loading the styles along with the levels to know about all the object types. I'll try to get to that in the upcoming days.

Thanks for trying this out.