Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
fiend-o-hell

EDGE: how do I align PNG sprites?

Recommended Posts

Hope there is somebody out there familiar enough with EDGE to help me out on this. I'm currently designing a wad for the last official EDGE build (v1.35) and testing with default settings. I would post a picture, but I have yet to figure out how to take screenshots in EDGE (what is that -screenshot <rate> cmd about?).

I have provided a test wad at the bottom to better demonstrate the issues I have been having.

SETUP:
I have defined TWO identical DDF defined weapons which replace the fist and pistol in doom. The sprites and palette are borrowed from Hexen.
-Slot 1: png version.
-Slot 2: doom format version

THE PROBLEM:
No matter how how much I change the PNG version's offset of the image in SLADE, the PNG sprites remain unmoved in game. On top of that they are completely out of place. Doom format images on the other hand act as expected.

I am aware of this statement on the EDGE website regarding S_START png entries:

For PNG format, offsets are inside the PNG itself (using a special tool to modify), but have a reasonable default: centered horizontally and standing on the ground.

What special tool?

TEST WAD DOWNLOAD

Share this post


Link to post
fiend-o-hell said:

I would post a picture, but I have yet to figure out how to take screenshots in EDGE (what is that -screenshot <rate> cmd about?).


Hit F1. Takes a shot and places it in the auto-generated subdirectory 'screenshots.'

fiend-o-hell said:

No matter how how much I change the PNG version's offset of the image in SLADE, the PNG sprites remain unmoved in game. On top of that they are completely out of place. Doom format images on the other hand act as expected.


EDGE doesn't handle PNGs with offsets set in a WAD editor like Zdoom does. It is a bit annoying. You have to define the offsets in IMAGES.ddf, OR use the mentioned...

fiend-o-hell said:

...special tool


I think you're looking for SetPNG. Here's a wiki page on it, and there's a download at the bottom.

Good to see people still developing for EDGE :)
I know the engine almost inside out but switched off it recently. If you have any more questions on EDGE feel free to post here or PM me.

Share this post


Link to post

Hey, thanks for the help Nick.

I tried using SetPNG to modify the offsets of some of the SLADE converted Hexen sprites and came up with CRC errors. I have no idea what that is and I figured SLADE's internal PNG converters had something to do with it, so I re-saved the images in PS and tried it again with success using the -grab cmd. Unfortunately the offsets were still wrong in EDGE.

I looked around for documentation on images.ddf without much luck. The only thing I know how to do from looking at other EDGE projects is how to define a new entry:

[spr:FSRDA0]
IMAGE_DATA=LUMP:PNG:"FSRDA0";

How do i define the image properties?

Share this post


Link to post
Nick Perrin said:

EDGE doesn't handle PNGs with offsets set in a WAD editor like Zdoom does. It is a bit annoying. You have to define the offsets in IMAGES.ddf, OR use the mentioned...

I think you're looking for SetPNG.

Problem, SetPNG does the same thing as SLADE and others: it changes the grAb chunk.

If EDGE doesn't handle the grAb chunk, it'd be a nice suggestion for 3DGE.

fiend-o-hell said:

I tried using SetPNG to modify the offsets of some of the SLADE converted Hexen sprites and came up with CRC errors.


There was a bug where SLADE would write incorrect CRC in PNGs; but I fixed that long ago. If you're using beta 3.0.2, you should update to an SVN build.

Share this post


Link to post
Gez said:

If EDGE doesn't handle the grAb chunk, it'd be a nice suggestion for 3DGE.

I guess it doesn't use it (at least not from my experience). I never actually tried SetPNG, always manually entered offsets in the image definition file so that was just based on old threads I dug up (from my own questions on the same issue!). Certainly a good idea for 3DGE if not already implemented.

fiend-o-hell said:

How do i define the image properties?

Using your example, here are some additional properties you can add:

[spr:FSRDA0]
IMAGE_DATA=LUMP:PNG:"FSRDA0";
SCALE=##; (float)
X_OFFSET=##; (int)
Y_OFFSET=##; (int)
FIX_TRANS=BLACKEN;

The last one changes the alpha channel to black, useful as EDGE seems to like to make white borders visible around PNGs with alpha channel transparency, where other ports do not. This fixes that well enough. For a standard sprite like the ones in your example wad, you don't need that line.

Remember that with EDGE all your data (DDF, sounds, music, images, etc.) can be in folders, doesn't have to be in a WAD file. Personally I found that much easier than working with a WAD while developing as I use a multitude of programs to edit the variety of files involved. Then on release you can pack everything into a WAD and use "find and replace" to fix the definitions in your DDF. Or you can simple include the folder structure intact, and it will work too.

Instead of IMAGE_DATA=LUMP you would write E.G.

IMAGE_DATA=FILE:"weapons/sword/FSRDA0.png";

Share this post


Link to post
Gez said:

There was a bug where SLADE would write incorrect CRC in PNGs; but I fixed that long ago. If you're using beta 3.0.2, you should update to an SVN build.


That's good to know! I'll go ahead and update right now.

@Nick Perrin: Thanks again for sharing your know-how on EDGE. It's a bummer that images.ddf doesn't have a nice SLADE GUI like zdoom's TEXTURES lump. I decided to just make my weapon sprites into full 320x240 screen sprites so I wouldn't have to manually offset (Yikes!). After I imported the sprites, all I had to do was define the image and offset it to 0. Wallah!

After working on this EDGE project for a month now, I've really grown to like the limited feature set (relatively speaking of course). I have yet to really start the nitty-gritty RTS programming & mapping, but so far, defining stuff through DDF files seems simple and intuitive enough.

Hopefully with 3DGE, there will be better support and documentation in the future to ease other's into mapping for this awesome port!

Share this post


Link to post
fiend-o-hell said:

After working on this EDGE project for a month now, I've really grown to like the limited feature set (relatively speaking of course). I have yet to really start the nitty-gritty RTS programming & mapping, but so far, defining stuff through DDF files seems simple and intuitive enough.

Hopefully with 3DGE, there will be better support and documentation in the future to ease other's into mapping for this awesome port!


EDGE still has a lot of tricks up its sleeve, once you learn RTS it certainly opens things up. If you're clever you can use many workarounds to achieve cool effects. Plus the engine supports models and slopes so it can look cool too.

There IS a resource that can help you in the meantime. It's not totally up to date (and remember that as you work, so if you think something's impossible be sure to ask first), but it has the majority of EDGE's functionality described inside.

EMUS v2.0

Basically it has tools to help with EDGE mod creation, but most importantly it has a DDF Help section that explains what everything does in each DDF file, and it has an RTS section that does the same for RTS. Think of it as the equivalent of the Zdoom wiki. Once again, it's not 100% up to date, but it's 90% there.

*** BTW, you should post about your new project on the EDGE forum in the Projects section, a few old EDGE modders recently posted there for the first time in a while, and it would be cool to see what your new project is all about (even if it's just description and no screenshots yet).

Share this post


Link to post

>>>EMUS v2.0<<<----For Realzies! I had no idea this tool set existed. I'll go try it out as soon as I can!

As for my project, I'm still gathering and making the early game resources (weapons, enemies, textures, etc), so I really don't consider it announcement worthy at this point. I have a pretty good idea of what I want to make, but I just don't want to post up a block of text. I'll keep your suggestion in mind though about posting it up over at the EDGE forum when I arrive at that point.

I will say that it is the next level for my Standalone project, so look forward to it sooner rather than later.

Share this post


Link to post
fiend-o-hell said:

I really don't consider it announcement worthy at this point. I have a pretty good idea of what I want to make, but I just don't want to post up a block of text.

I would never normally encourage someone to post an announcement thread with nothing far-along to show, but it's the EDGE forum, there's only one big project left in development for EDGE (or rather its follow-up 3DGE) and it's so inactive lately that even a block of text would be a welcome post.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×