Author Topic: extracting Cheapo graphics  (Read 37537 times)

0 Members and 1 Guest are viewing this topic.

Offline mobius

  • Posts: 2752
  • relax.
    • View Profile
extracting Cheapo graphics
« on: December 06, 2014, 09:59:32 PM »
Anyone that knows anything about Cheapo:

I'd like to extract the graphics files. What programs (other than Cheapo) can load them? Is there any way possible to get these and convert them to something like gif or anything normal? Thank you.
everything by me: https://www.lemmingsforums.net/index.php?topic=5982.msg96035#msg96035

"Not knowing how near the truth is, we seek it far away."
-Hakuin Ekaku

"I have seen a heap of trouble in my life, and most of it has never come to pass" - Mark Twain


Offline Crane

  • Posts: 1081
    • View Profile
Re: extracting Cheapo graphics
« Reply #1 on: December 09, 2014, 12:01:21 AM »
The only clue from the little I studied Cheapo years ago is that the files are zlib compressed.  Unfortunately I don't have time myself to revisit it currently, but the first step would be to decompress the files programmatically (zlib is open-source) and see what you can find in the raw data.

I'd like to convert some of the Cheapo styles too... I quite liked the fantasy forest theme, and while not possible to port to Lemmini, the "Original Lemmings" was a clever one (which had the lemmings with grey hair and hunched with walking sticks, and the climber animation was a lemming sitting in a stairlift!)

Offline Prob Lem

  • Posts: 571
    • View Profile
Re: extracting Cheapo graphics
« Reply #2 on: December 09, 2014, 10:16:29 AM »
:o

Do you guys have any pictures of these tilesets, for those of us not familiar with Cheapo, please? They sound pretty cool!

Offline mobius

  • Posts: 2752
  • relax.
    • View Profile
Re: extracting Cheapo graphics
« Reply #3 on: December 09, 2014, 11:15:14 AM »
:o

Do you guys have any pictures of these tilesets, for those of us not familiar with Cheapo, please? They sound pretty cool!

https://dl.dropboxusercontent.com/u/72760678/Cheapo.zip

here's the whole thing :) It should work on Windows though it crashes a lot. I particularly like the "floggings". look at level "the M0nolith" by InsaneSteve
everything by me: https://www.lemmingsforums.net/index.php?topic=5982.msg96035#msg96035

"Not knowing how near the truth is, we seek it far away."
-Hakuin Ekaku

"I have seen a heap of trouble in my life, and most of it has never come to pass" - Mark Twain


Offline mobius

  • Posts: 2752
  • relax.
    • View Profile
Re: extracting Cheapo graphics
« Reply #4 on: December 10, 2014, 01:59:44 AM »
for Prob Lem; here's a screenshot of a Cheapo level to give you an idea. It's actually a surprisingly good game, despite flaws. It has really good graphics which is why I like it quite a bit. and good music
everything by me: https://www.lemmingsforums.net/index.php?topic=5982.msg96035#msg96035

"Not knowing how near the truth is, we seek it far away."
-Hakuin Ekaku

"I have seen a heap of trouble in my life, and most of it has never come to pass" - Mark Twain


Offline Prob Lem

  • Posts: 571
    • View Profile
Re: extracting Cheapo graphics
« Reply #5 on: December 10, 2014, 12:08:15 PM »
Thanks very much, möbius! :thumbsup:

Man, it does look cool. I'll see if I can get it running under WINE when I've got a moment.

Anyway, sorry for going off-topic, there - best of luck in obtaining the tilesets!

Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #6 on: December 11, 2014, 03:04:25 AM »
Hi, I made "Cheapo" and can help with extracting graphics as necessary. My code and tools are on a different computer that I'll be able to use on Friday. I'll look through what I have and see what will be of help. I'll be more available to help starting in January since I'll be on vacation until the end of the year.
Have fun!

Offline mobius

  • Posts: 2752
  • relax.
    • View Profile
Re: extracting Cheapo graphics
« Reply #7 on: December 11, 2014, 08:09:49 PM »
Hi, I made "Cheapo" and can help with extracting graphics as necessary. My code and tools are on a different computer that I'll be able to use on Friday. I'll look through what I have and see what will be of help. I'll be more available to help starting in January since I'll be on vacation until the end of the year.
Have fun!

great, thanks a lot  :thumbsup:
------
I just realized something; not only will this be cool for the custom graphics but [you and/or others] added new graphics to the existing old Lemmings graphics, a lot of useful ones  :thumbsup:
everything by me: https://www.lemmingsforums.net/index.php?topic=5982.msg96035#msg96035

"Not knowing how near the truth is, we seek it far away."
-Hakuin Ekaku

"I have seen a heap of trouble in my life, and most of it has never come to pass" - Mark Twain


Offline chaos_defrost

  • Posts: 908
  • the artist formerly known as Insane Steve
    • View Profile
Re: extracting Cheapo graphics
« Reply #8 on: December 12, 2014, 03:16:19 AM »
Hey, Peter, great to see you back  :thumbsup:

So... while we're discussing Cheapo, is there a quick fix to the framerate issues I have running Cheapo on new-ish machines? I mean, no matter what the settings, my last two computers dating back 4 or so years has run the game at a framerate where an in-game second lasts about 2 seconds, with the animation to boot.

Would be sweet to be able to replay all the Cheapo exclusive levels I have accumulated.  :D
"こんなげーむにまじになっちゃってどうするの"

~"Beat" Takeshi Kitano

Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #9 on: December 12, 2014, 07:00:34 PM »
...is there a quick fix to the framerate issues I have running Cheapo on new-ish machines? I mean, no matter what the settings, my last two computers dating back 4 or so years has run the game at a framerate where an in-game second lasts about 2 seconds, with the animation to boot.

There's no fix as far as I know. The ancient graphics technology used in that game just doesn't work well in Windows.

Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #10 on: December 13, 2014, 11:12:37 PM »
I found the old code that loads style files. It's not very good and needs some work to be usable nowadays. If there is still interest after I come back from vacation (after the new year) I will make a program that extracts the sounds and graphics from a style file. I'd share the source for it too.

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #11 on: January 03, 2015, 03:05:58 PM »
Is there any chance you can provide a tool for extracting the data from level files, or at least describe the format of them? I'd like to create a tool to convert them to NeoLemmix / SuperLemmini formats. :)

Of course, mechanics differences may mean some levels don't work properly (particularly those that rely on glitches), but the only major difference is the fall distance; SuperLemmini supports arbitrary fall distances, while the latest update of NeoLemmix adds an option to use Cheapo's fall distance.
« Last Edit: January 03, 2015, 03:26:38 PM 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 mobius

  • Posts: 2752
  • relax.
    • View Profile
Re: extracting Cheapo graphics
« Reply #12 on: January 03, 2015, 11:29:26 PM »
I'm concerned Essman hasn't made an account here yet. Though visiting the old website, he'd see the notice but he might forget and not visit any time soon. Is there some other way to contact him?
everything by me: https://www.lemmingsforums.net/index.php?topic=5982.msg96035#msg96035

"Not knowing how near the truth is, we seek it far away."
-Hakuin Ekaku

"I have seen a heap of trouble in my life, and most of it has never come to pass" - Mark Twain


Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #13 on: January 04, 2015, 01:23:36 AM »
Could possibly try contacting him by email. However, the last time he was active on the old forums was before the move, so he hasn't "not seen" the notices; he just hasn't been on the site at all it'd seem.
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 Proxima

  • Posts: 4569
    • View Profile
Re: extracting Cheapo graphics
« Reply #14 on: January 04, 2015, 04:10:07 PM »
I don't see how that could ever work. Cheapo has a similar interface for selecting graphics from a fixed tileset and placing them on a level, but once placed the terrain is stored as a bitmap. This adds flexibility (you can mix terrain from any number of styles, or paste in graphics from any source) but should make it impossible to go backwards. I suppose it's possible the bitmaps could be treated like the "special graphics" levels in Lemmings.

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #15 on: January 04, 2015, 04:11:46 PM »
I suppose it's possible the bitmaps could be treated like the "special graphics" levels in Lemmings.

My plan exactly. :)
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 mobius

  • Posts: 2752
  • relax.
    • View Profile
Re: extracting Cheapo graphics
« Reply #16 on: January 10, 2015, 08:30:36 PM »
I suppose it's possible the bitmaps could be treated like the "special graphics" levels in Lemmings.

My plan exactly. :)

this is all that's necessary if I remake the few special levels for Revenge of the Lemmings like Lemmings of Persia.

I'm still interested but if no one can do anything soon, I'll be finishing that levelpack without these special levels.
everything by me: https://www.lemmingsforums.net/index.php?topic=5982.msg96035#msg96035

"Not knowing how near the truth is, we seek it far away."
-Hakuin Ekaku

"I have seen a heap of trouble in my life, and most of it has never come to pass" - Mark Twain


Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #17 on: January 16, 2015, 06:45:02 AM »
OK it took me a while, but I found out about this new forum site. I usually just looked at the RSS feed rather than going to the old site.

Anyway... I am currently working on a little program that will extract all data from style files. It'll be an open source C# project when it's done. I'm working on it during my lunch hour a couple times a week though, so it'll take a little while to write.

Is there any chance you can provide a tool for extracting the data from level files, or at least describe the format of them? I'd like to create a tool to convert them to NeoLemmix / SuperLemmini formats. :)

Sure thing, once the style extraction program is complete (enough) then I can make an open source project that extracts data from level and set files. Then all the style and level formats will be out in the open and easy for people to figure out.

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #18 on: January 16, 2015, 07:26:51 AM »
On that note - is there much difference between that and the formats for your first game? Wouldn't hurt to be able to work with those too...
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 #19 on: January 16, 2015, 08:25:31 AM »
On that note - is there much difference between that and the formats for your first game? Wouldn't hurt to be able to work with those too...

I think the second game's level editor can open up the original level files and save them in the newer format.

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #20 on: January 16, 2015, 08:42:06 AM »
On that note - is there much difference between that and the formats for your first game? Wouldn't hurt to be able to work with those too...

I think the second game's level editor can open up the original level files and save them in the newer format.

Even the default levels? It'd be quite nice to get them on a newer engine, seeing how Copycat / Cheapo don't perform well on newer systems. (Also, aren't all the custom levels stored in a single file?)
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 #21 on: January 16, 2015, 04:29:35 PM »
Even the default levels? It'd be quite nice to get them on a newer engine, seeing how Copycat / Cheapo don't perform well on newer systems. (Also, aren't all the custom levels stored in a single file?)

In the past I converted all 120 of the default levels from the first copycat game. There are set files OldFun.set, ..., OldMayhem.set that contain them. Those should be included with the second game.

I remember working on all of those levels and having people contribute some levels. I felt like they were cool at the time, but I know people make much better custom levels nowadays for Lemmini and such.

Offline mobius

  • Posts: 2752
  • relax.
    • View Profile
Re: extracting Cheapo graphics
« Reply #22 on: January 18, 2015, 10:22:21 PM »
I suppose it's possible the bitmaps could be treated like the "special graphics" levels in Lemmings.

My plan exactly. :)

this is all that's necessary if I remake the few special levels for Revenge of the Lemmings like Lemmings of Persia.

I'm still interested but if no one can do anything soon, I'll be finishing that levelpack without these special levels.

I didn't mean for this to sound inconsiderate, if it did.

Glad you've found time to work on it  :thumbsup:
Can you give me any detail? I'm assuming you'll be able to convert "regular" tilesets into actual tiles? With the exception of the special levels like Lemmings of Persia. But what about the Mario levels will they be able to have individual tiles?  On the mario thing--I don't mind if the blue background is not converted; I actually don't really care for that a whole lot. On the other hand if that is somehow permanently  attached to that whole graphic style I won't be too upset either.

What type of images you'll be able to convert them to? I'd prefer gif or png if it's possible, but it's not a big deal. [I have photoshop and other programs myself]
everything by me: https://www.lemmingsforums.net/index.php?topic=5982.msg96035#msg96035

"Not knowing how near the truth is, we seek it far away."
-Hakuin Ekaku

"I have seen a heap of trouble in my life, and most of it has never come to pass" - Mark Twain


Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #23 on: January 18, 2015, 11:40:57 PM »
Even the default levels? It'd be quite nice to get them on a newer engine, seeing how Copycat / Cheapo don't perform well on newer systems. (Also, aren't all the custom levels stored in a single file?)

In the past I converted all 120 of the default levels from the first copycat game. There are set files OldFun.set, ..., OldMayhem.set that contain them. Those should be included with the second game.

I remember working on all of those levels and having people contribute some levels. I felt like they were cool at the time, but I know people make much better custom levels nowadays for Lemmini and such.

IIRC, I haven't seen these in either the version of Cheapo floating around the web, or a copy that you yourself sent me at one point (this was a very long time ago, it may have been before you converted those 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 mobius

  • Posts: 2752
  • relax.
    • View Profile
Re: extracting Cheapo graphics
« Reply #24 on: January 19, 2015, 12:07:42 AM »
I guess it's worth noting/asking: Can you upload this default version somewhere?

The version I have is what geoo gave me here on the forum and it has a ton of levels but by random people over years. And I didn't understand why there are two separate Cheapo exe's. I have no idea how old/which version this is
everything by me: https://www.lemmingsforums.net/index.php?topic=5982.msg96035#msg96035

"Not knowing how near the truth is, we seek it far away."
-Hakuin Ekaku

"I have seen a heap of trouble in my life, and most of it has never come to pass" - Mark Twain


Offline geoo

  • Administrator
  • Posts: 1475
    • View Profile
Re: extracting Cheapo graphics
« Reply #25 on: January 19, 2015, 06:25:27 AM »
I believe one of them is ccexplore's update that allow also tracker modules (mod/xm/it/s3m I presume) instead of just midis as background music. The physics and everything else between the two should still be the same iirc.

Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #26 on: January 19, 2015, 06:51:31 PM »
In the past I converted all 120 of the default levels from the first copycat game. There are set files OldFun.set, ..., OldMayhem.set that contain them. Those should be included with the second game.

I remember working on all of those levels and having people contribute some levels. I felt like they were cool at the time, but I know people make much better custom levels nowadays for Lemmini and such.

IIRC, I haven't seen these in either the version of Cheapo floating around the web, or a copy that you yourself sent me at one point (this was a very long time ago, it may have been before you converted those sets).

Those four set file should've been included. But anyway here they are as an attachment to this reply.
This zip file contains the 120 levels that I made long long ago for the DOS copycat clone (actually 8 of them were made by someone who went by BlurNM). Then I converted them for the newer clone.

Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #27 on: January 19, 2015, 07:03:50 PM »
Over the weekend I worked on the style extractor tool and got it to extract graphics from .sty files as .png files. Next I want to extract more data like sounds, music, and object info.

For people who can get by with only graphics extraction, the current version of the tool will help.
Here is a zip file that will always contain the latest version:
https://github.com/spadapet/cheapstyle/blob/master/Publish/CheapStyle.zip?raw=true

The .exe runs in Windows. The code is open source on Github if anybody cares about that:
https://github.com/spadapet/cheapstyle/

More to come. (like, for example, a level data extractor after the style extractor is complete)

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #28 on: January 20, 2015, 02:31:44 AM »
Alright! :) I'll have a look at the output from this later on today, and see what I can do about making a tool to convert the output to NeoLemmix / SuperLemmini styles. Of course, keep in mind that objects that don't exist in these versions can't be transferred (which is pretty much any Cheapo-exclusive object, with the exception (only in NeoLemmix) of the teleporters).
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 #29 on: January 20, 2015, 03:32:55 AM »
Alright! :) I'll have a look at the output from this later on today, and see what I can do about making a tool to convert the output to NeoLemmix / SuperLemmini styles. Of course, keep in mind that objects that don't exist in these versions can't be transferred (which is pretty much any Cheapo-exclusive object, with the exception (only in NeoLemmix) of the teleporters).

I just updated the zip file link so that it extracts music (.midi) and sound (.wav) files.
The only thing left is object info. Is that even useful to know? I'd have to make a list of objects, and write out the position of each sprite that it uses for each frame. Before I make up a format for extracted objects, I'll wait to see if anyone has any requirements. Otherwise I'll just make up an XML or JSON text format.

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #30 on: January 20, 2015, 07:01:44 AM »
Simple is always good. If you could at least document the format, I could look at doing something with it...
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 mobius

  • Posts: 2752
  • relax.
    • View Profile
Re: extracting Cheapo graphics
« Reply #31 on: January 20, 2015, 10:14:06 PM »
 :thumbsup: thanks big time. This is really cool.

Alright! :) I'll have a look at the output from this later on today, and see what I can do about making a tool to convert the output to NeoLemmix / SuperLemmini styles. Of course, keep in mind that objects that don't exist in these versions can't be transferred (which is pretty much any Cheapo-exclusive object, with the exception (only in NeoLemmix) of the teleporters).

I just updated the zip file link so that it extracts music (.midi) and sound (.wav) files.
The only thing left is object info. Is that even useful to know? I'd have to make a list of objects, and write out the position of each sprite that it uses for each frame. Before I make up a format for extracted objects, I'll wait to see if anyone has any requirements. Otherwise I'll just make up an XML or JSON text format.

I'd be interested in objects but not sure about requirements or how high of a priority it is, considering I'm not even sure how to create new objects in Lemmini/SuperLemmini. [what I would be doing this for right now that is]
« Last Edit: January 20, 2015, 10:20:44 PM by möbius »
everything by me: https://www.lemmingsforums.net/index.php?topic=5982.msg96035#msg96035

"Not knowing how near the truth is, we seek it far away."
-Hakuin Ekaku

"I have seen a heap of trouble in my life, and most of it has never come to pass" - Mark Twain


Offline mobius

  • Posts: 2752
  • relax.
    • View Profile
Re: extracting Cheapo graphics
« Reply #32 on: January 21, 2015, 01:33:42 AM »
It works great so far except I get an error when I try to extract the Mario (SMB) set. It says invalid style file. Any ideas [the style works fine in-game...]

This was the one style I really wanted above all the others  :'(
everything by me: https://www.lemmingsforums.net/index.php?topic=5982.msg96035#msg96035

"Not knowing how near the truth is, we seek it far away."
-Hakuin Ekaku

"I have seen a heap of trouble in my life, and most of it has never come to pass" - Mark Twain


Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #33 on: January 21, 2015, 01:43:06 AM »
It works great so far except I get an error when I try to extract the Mario (SMB) set. It says invalid style file. Any ideas [the style works fine in-game...]

This was the one style I really wanted above all the others  :'(

I don't have a copy of that Mario style file. If you get a copy to me then I'll debug the extractor and see what's wrong.

Edit: I think I found the SMB.sty file online so I'll check it out later. Thanks for the info.

Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #34 on: January 21, 2015, 04:33:20 AM »
It works great so far except I get an error when I try to extract the Mario (SMB) set. It says invalid style file. Any ideas [the style works fine in-game...]

This was the one style I really wanted above all the others  :'(

I ran the extractor on smb.sty and it worked fine. I added an attachment of the files that were extracted.
Try downloading the style extractor zip file again, I've been updating it as I make fixes. Or maybe you have a corrupt copy of smb.sty. Either way, hopefully the attached zip file has what you want.

Offline mobius

  • Posts: 2752
  • relax.
    • View Profile
Re: extracting Cheapo graphics
« Reply #35 on: January 21, 2015, 10:09:15 PM »
It works great so far except I get an error when I try to extract the Mario (SMB) set. It says invalid style file. Any ideas [the style works fine in-game...]

This was the one style I really wanted above all the others  :'(

I ran the extractor on smb.sty and it worked fine. I added an attachment of the files that were extracted.
Try downloading the style extractor zip file again, I've been updating it as I make fixes. Or maybe you have a corrupt copy of smb.sty. Either way, hopefully the attached zip file has what you want.

 :thumbsup: exactly what I wanted thanks a million.
So far this is the only time I've had a problem everything else extracted fine.

Do you have documentation or know who created each style?
everything by me: https://www.lemmingsforums.net/index.php?topic=5982.msg96035#msg96035

"Not knowing how near the truth is, we seek it far away."
-Hakuin Ekaku

"I have seen a heap of trouble in my life, and most of it has never come to pass" - Mark Twain


Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #36 on: January 21, 2015, 10:16:15 PM »
Do you have documentation or know who created each style?

Nope, not unless the creator included a readme file with the style. For SMB.sty, the readme says "Insane Steve" created it.

Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #37 on: January 27, 2015, 03:13:05 AM »
One last update for the style extractor: All information about sprites and objects are written to XML files.
https://github.com/spadapet/cheapstyle/blob/master/Publish/CheapStyle.zip?raw=true

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #38 on: January 27, 2015, 05:51:24 AM »
Working on a LemSet update that can take these files as input. :)
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 #39 on: January 27, 2015, 06:09:57 AM »
Working on a LemSet update that can take these files as input. :)

Cool, if you're using the files, let me know if I can change the file format to make them easier to use.

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #40 on: January 27, 2015, 06:49:15 AM »
It's manageable as it is. :) I already modified LemSet to accept PNG (and GIF) files before I saw this post, and that's probably the only major obstacle that existed.

However, two pieces of info that could be useful:
- How exactly does Cheapo calculate a circle trigger area? NeoLemmix doesn't support this, so I'd have to approximate it with a square (or add support for it, in which case knowing the algorithm would be useful).
- What sound effects correspond to what traps?
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 #41 on: January 27, 2015, 07:22:46 AM »
However, two pieces of info that could be useful:
- How exactly does Cheapo calculate a circle trigger area? NeoLemmix doesn't support this, so I'd have to approximate it with a square (or add support for it, in which case knowing the algorithm would be useful).
- What sound effects correspond to what traps?

I forgot about circle triggers for objects. Now I added support for them, but it's not well tested since I couldn't find any objects that have circle triggers. But I think it works. You would've seen negative rectangle sizes before I added circle support.

I attached a text file here that lists all of the sound effect numbers.

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #42 on: February 06, 2015, 09:13:33 PM »
Just for record, I haven't forgotten about this. But I am going to have to make some adjustments to NeoLemmix, to support having more than one window in the same graphic set, as even some of the official Cheapo styles use this, let alone fan-made ones.

EDIT: I have support for it implemented in LemSet, and I have it functionally (but not yet graphically) working in NeoLemmix (ie: they function as windows, but don't yet follow the rules for how windows are meant to animate).

EDIT: Fully implemented now.


There are some types of objects in Cheapo that NeoLemmix doesn't support (basically anything that doesn't appear in the official games, except for Teleporters; also NoSplats are virtually the same as NeoLemmix's updrafts so those could be used as a substitute; also it doesn't support triggered harmless animations (only constant ones) or exits, or SingleTele / TwoWayTele). Most likely, I'll just convert the unsupported ones to objects that do nothing.
« Last Edit: February 07, 2015, 12:01:12 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 #43 on: February 07, 2015, 02:16:12 AM »
Alright, I just took this for its first test run. Results:

- Terrain is converted PERFECTLY. :)
- Objects, not so well yet. Some types seem to not function even when they should, the spawn point for windows is a bit off fixed and fixed, and most of all, the graphic is entirely missing the graphics are fine now.
- NeoLemmix also seems to have a weird issue when a graphic set has a window as the first object. Fixed this one.
- Objects don't have sound linked to them yet, but after intensively examining the code, I have determined that this is because I haven't written any code to handle doing so yet - important parts first. :P


EDIT: By any chance, does the window spawn position (HitPointX and HitPointY) refer to the lemming's top-left rather than it's foot position? No worries, through trial-and-error I worked out the correct relative position to use.

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.
« Last Edit: February 07, 2015, 03:24:00 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 #44 on: February 07, 2015, 03:43:20 AM »
Things are looking good. There's one small snag of what to do about one-way arrows; as you probably know, Cheapo doesn't consider them "objects", but treats them more like how steel areas are handled (or at least, how they were prior to autosteel's existance). Since the sizing of them is very flexible, unlike in other engines where they're restricted by the size of the object, this could be problematic when converting levels (of course, in all but the very best of cases, 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).
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 #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.

Offline namida

  • Administrator
  • Posts: 12399
    • View Profile
    • NeoLemmix Website
Re: extracting Cheapo graphics
« Reply #60 on: February 17, 2015, 05:27:27 AM »
Also - what's the correct behaviour in cases of "extra data" conflicts? (eg: two windows, two teleporters, or two receivers, with the same ID number)

Depending on what's meant to happen, I may have to implement additional handling for them, or it might be possible to just emulate it with a combination of re-ordering and marking some objects as fake. This is because NeoLemmix doesn't store extra data numbers to determine these effects like Cheapo does; rather, window order is based on a list (this is actually a somewhat unknown feature as the editor doesn't support it yet; but it's a list of windows, in which the same window can also be listed more than once), while teleporters just work on "go to the first receiver in the object list, starting from the object after the teleporter, and wrapping around if the end of the list is reached without finding one".


This shouldn't matter for your levels I'd assume, but it might come up when converting other levels in general. As far as a test run goes - if possible, I'll try to have a NeoLemmix Player of the Copycat Lemmings levels out later tonight. :)

EDIT: Everything for it, other than converting the levels (which to be fair, is the most important part), has been done, assuming no problems relating to the code come up. By this I mean - nessecary styles are converted, the skeleton player has been made (just without the actual levels inserted into it yet), etc.


EDIT: Another issue I can see potentially arising; and this is more likely to occur on the various fanmade levels than the "official" Copycat Lemmings levels, is excessive numbers of objects, steel areas and one way fields. As far as Cheapo conversions go, NeoLemmix is only able to support up to 128 objects, and up to 128 steels and one-ways combined. Furthermore, I don't think Cheapo has (within practical limitations) any size limits on these, whereas NeoLemmix's areas are limited to 256x256 - of course, it's possible to just divide larger areas up into smaller ones, but that also means the limit will be reached quicker. At some point, I might look into the possibility of combining multiple adjacent areas into one where possible. If nessecary, a modified level format that can handle more could be created (though I would rather avoid this); there's no reason the engine can't handle it, it's only the level format that has this limitation.
« Last Edit: February 17, 2015, 08:42:27 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 #61 on: February 17, 2015, 09:10:13 AM »
I've written the conversion app. So far, only one-level-at-a-time, but once I confirm that's working, mass conversion is the next step, and it won't be a huge task.

I haven't tested it yet (about to do so, compiling as I write this); it's rare for something I write to work perfectly the first time, so let's see how long it takes to get it right...

Test run 1 results
- Worked fine up until processing objects. At this point, crashed because the XML file was no longer open; I forgot to re-open it after closing it at an earlier point. I since realised there's no need to close it in the first place, and have adjusted the code accordingly.

Test run 2 results
- Processed objects fine. Hung upon attempting to process steel/oneway areas, due to the level I'm testing first not having any, yet the code specifically looking for the </Boxes> tag in order to process to the next part.

Test run 3 results
- Program exited before any conversion attempt due to me accidentally pushing "Exit" instead of "Convert single level" at the main menu.

Test run 4 results
- Program executed successfully. Will now attempt to play level in NeoLemmix and add results of such.
- Result: NeoLemmix gives an error upon attempting to load the level.
- Attempted using an Orig VGASPEC in place of the generated one. Error no longer occurs, so it can definitely be traced to VGASPEC code.
- This aside; some stats were not converted correctly. Time limit and skillset are wrong; lemming count, save requirement and possibly release rate are fine. Level title is missing, level author is present and correct. Level is in the correct graphic set. Objects are in incorrect places or missing entirely. Level dimensions are incorrect, as is screen start position. (Can't say for sure about release rate, as the level's RR is 1, which is what shows up; but NeoLemmix also defaults to 1 if an invalid release rate is provided. EDIT: By checking with a hex editor, I can confirm that the RR is indeed correctly converted.)

Test run 5
- TARGETS: Attempted to fix all level stats, apart from time limit and quantities of skills (but did attempt to fix types of skills).
- RESULTS: All attempted goals were successful.

Test run 6
- TARGETS: Attempted to fix time limit and skill quantities.
- RESULTS: Appears to be successful! Have noticed another issue - music number is not being converted properly; I missed this detail before. On closer (ie: hex editor) inspection of objects, it appears the only thing it's actually getting is that the object exists; all other values are being converted to zero (or "off" in the case of flags).

Test run 7
- TARGETS: Music number and objects fixed.
- RESULTS: Appears to be succesful! :D
- On closer examination: One detail with objects isn't fixed; the flags (such as flip, no overwrite, and fake). Made one minor change and re-tested; they are now working.

Time to take a break for 5-10 mins or so. I'll continue with the updates when I'm back. :P

Test run 8, 9, 10, who knows how many
- TARGET: Fix the damn VGASPECs!
- RESULTS: Fail. Fail fail fail. Fail.

Test run Infinity+1
- TARGET: Still fix the damn VGASPECs!
- RESULTS: Success! I thought the fault was in my RLE compression algorithm, but it turned out it was as simple as the wrong sizes being written to the file! Who knows how many of my attempted rewrites of the RLE were actually spot-on; the one I had at the moment didn't compress correctly, but the faux-compression version of it worked fine. Need to improve this of course and use proper compression. (Of course, it still has DAT compression, just not RLE.) However, while that tweak is needed to minimize filesizes (which, make no mistakes, are going to be HUGE for converted Cheapo levels, even after this is fixed, due to the way they work combined with the DAT and RLE algorithms not being intended for 18-bit color images), I can now say I have successfully imported a Cheapo level into NeoLemmix! I'd say I'm well on track to my goal of having a (beta) NeoLemmix version of "Copycat Lemmings" released later tonight.

Test run Infinity+2
- TARGET: VGASPECs working with proper RLE compression.
- RESULTS: Mission accomplished.


I need to run the convertor on some more-complex levels next (namely, those with steel and/or one-ways); that's pretty much the only thing remaining untested that'll matter for this first release. If that works out, I'll write the code to mass-convert and pack into LEVELxxx.DAT files (which should take about 5 minutes; the underlying code is already there, I just need to specifically tell it what files to convert and then pack into LEVELxxx.DAT files), and we should have the NeoLemmix player I promised very soon. :)
« Last Edit: February 17, 2015, 11:40:59 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 #62 on: February 17, 2015, 12:12:12 PM »
At this point, all seems to be going very well. I'm about to run the first attempt at converting the whole bunch instead of just testing the odd semi-randomly picked level. If all goes well, you'll all be playing Copycat Lemmings on NeoLemmix very soon. Well, except for those of you who don't want to play it, I guess. :P

EDIT: First batch-convert test run. No major errors; some very slight ones that'll take a few seconds to fix (specifically, it was naming the level files "011.lvl", "012.lvl" etc instead of "0101.lvl", "0102.lvl", etc. However, it was expecting the latter when it then went to pack them into DATs, meaning it thought no level files existed. The only other issue was that it didn't report which level it was up to in the conversion progress, meaning it was a bit of guesswork how far along it was at any given point. It was easy enough to rename the faulty-named ones then use QuikPack to pack these ones; so I'm now running the (hopefully) fixed version on Tricky, and we'll see how that goes. :P
« Last Edit: February 17, 2015, 12:26:32 PM 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 #63 on: February 17, 2015, 12:57:38 PM »
http://www.lemmingsforums.net/index.php?topic=2039.0

Here's the first release. I haven't tested this very in-depth yet, but at a quick glance, it does seem to work. Let me know of any issues you find, so I can fix them up in either the convertor or NeoLemmix (whichever is causing them).
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 #64 on: February 17, 2015, 05:29:00 PM »
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).

The style extractor now supports command line parameters and not showing any UI:
https://github.com/spadapet/cheapstyle/blob/master/Publish/CheapStyle.zip?raw=true

Run it like:
CheapStyle.exe c:\styles\foo.sty c:\styles\foo

Offline Essman

  • Posts: 139
    • View Profile
    • Ferret Face Games
Re: extracting Cheapo graphics
« Reply #65 on: February 19, 2015, 07:28:29 PM »
Also - what's the correct behaviour in cases of "extra data" conflicts? (eg: two windows, two teleporters, or two receivers, with the same ID number)

The sort order for windows takes the "extra data" into account first, then it takes the object order into account. That's it. If there are four windows with a data of 1, then the order is simply the order they are specified in the object list.

For teleporters (one and two way), they find a matching receiver by going through the objects in order, looking for a matching "extra data". The first match wins. The matching object type must be either a "receiver" or "two-way-tele", it doesn't matter.