Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Kira

Discovering the BEX format

Recommended Posts

I'd like to toy with Whacked2 but don't know what really is possible.

Can I make a walking Pain Elemental spawning Demons and reviving people? Can I make a flying archvile that only attack? Can I make a double pistol and gatling firing missiles (thus replacing bullets)? Can I make an object giving a random bonus?

I am discovering the interface and am a bit lost (there are easy tasks, like checking gravity or pick-up stuff for things though). Looked at batman.deh too but it's a bit confusing as for now.

Share this post


Link to post
K!r4 said:

Can I make a walking Pain Elemental spawning Demons and reviving people?

1. Change Lost Soul's stats and frames so it looks and acts like a Demon.
2. Change the Pain Elemental walking frames codepointers from Chase into VileChase

Can I make a flying archvile that only attack?

Give the archvile the "FLOAT" and "NOGRAVITY" flags. Change its walking frames codepointers from VileChase to Chase.

Can I make a double pistol and gatling firing missiles (thus replacing bullets)?

Use two FirePistol codepointers instead of one, during pistol's shooting sequence. Use FireMissile instead of FireCGun on chaingun's shooting sequence.

Can I make an object giving a random bonus?

Yes! You can make an object cycle its sprite between several item aspects. In Doom the pick-up item effect depends on its sprite!

Share this post


Link to post
K!r4 said:

Can I make a walking Pain Elemental spawning Demons and reviving people? Can I make a flying archvile that only attack? Can I make a double pistol and gatling firing missiles (thus replacing bullets)? Can I make an object giving a random bonus?


Once you make this, be sure to give a copy to me. Sounds awesome!!

Share this post


Link to post

printz: You are awesome, thank you very much!
Archy: sure thing, I'll contact you if it works well.

Share this post


Link to post

Just FYI, shooting a weapon with 2 "firepistols" will cause your ammo to drop to -1 if you have only 1 bullet remaining. You can use FireCGun for the second shot to prevent this but it's a bit hacky, frames won't always display properly in non-ZDoom based ports.

Share this post


Link to post

Shouldn't happen if ammo are always at even numbers? Like if I make the ammo clips give 10 bullets instead of 5.

The flying vile works like a charm, but the Pain Elemental does not revive monsters (all walking frames (A to C) pointing at Vilechase)... Worst, when he spawns demons they telefrag between themselves if the first pinky isn't fast enough...

Share this post


Link to post
K!r4 said:

Shouldn't happen if ammo are always at even numbers? Like if I make the ammo clips give 10 bullets instead of 5.


You could edit clips to give 20. AFAIK individual ammo units can't be changed, any ammo dropped by a monster will give you half of a normal pickup's worth.

Share this post


Link to post
printz said:

Yes! You can make an object cycle its sprite between several item aspects. In Doom the pick-up item effect depends on its sprite!

Could you give me more details please? Looking at batman.deh I have found that the "random bonus" use the XXXXB0 sprite of each item but I didn't find what the guys could have done on the dehacked side...

Share this post


Link to post

It's mostly a question of getting each state to go to a different state.

So if you have BON1 B which is followed by BON2 B, and BON2 B which is followed by BON1 B, you have a bonus item that alternates between health and armor bonus.

You need to simply find out which state corresponds to which sprite and frame, and change their next states to make the loop you want.

Share this post


Link to post

I don't know what Batman did, but I know that you can make an object that looks like the Supercharger (same sprite) have the next frame of an Invisibility, which is followed by Invulnerability, which is followed by Megasphere. In-game, it will look like a sphere that cycles graphics. When you touch it, it has the effect of the sprite it currently uses at that exact moment.

Share this post


Link to post

How can I change their states with Whacked2? I don't find ARM1A on the states screen for exemple (or I am blind).

printz: It's still a bit foggy in my head, but from what I see on the case of Batman Doom:

ARM1A -> Green armor.
ARM1B -> Cash Machine.
ARM2A -> Blue Armor.
ARM2B -> Cash Machine again.
...

The Cash Machine is completely independent.

Share this post


Link to post

You won't find ARM1A because it'd be too convenient that's the sprite name and frame, not the state name. You first have to find out a state which uses that sprite and that frame.

Share this post


Link to post

If you have the Things tab and States tab both open, go to the item in the Things tab and click one of the state numbers on the right side, it will go to that state in the States tab automatically. You can change the "next state" in the States tab too (as well as duration), have the item cycle through states of various items and make the last state go back to the first state.

Share this post


Link to post

Thanks TimeOfDeath! It's a lot more clear and I see what I can do now. I wasn't really familiar with all the tabs.

Gez is right, this software could have been a lot more convenient. The things tab is especially annoying.

Edit: When will Slade integrate DEH/BEX utilities? :-)

Share this post


Link to post

It's not planned (beyond the text editor, if you're crazy enough to write dehacked code by hand).

I've kinda thought about it, but there are several unfun things to code first before it works. A complete mobj/state management system; a good UI for dealing with the gratuitous complexity of dehacked (born from incorrect assumptions about the Doom engine); and a parser that can handle the wildly divergent syntaxes of DEH and BEX.

The former might happen to some extent so that the map editor can parse DECORATE code like Doom Builder 2 does. Very handy to have custom actors without having to write custom configurations.

The latter... Well. I'll see if the former happens.

Share this post


Link to post

I must be crazy then. :p

I pretty much only ever use WhackEd anymore as a reference to look up default frame/thing states/properties. I write everything by hand, most of the time. Having some useful sort of environment to avoid having to constantly look up stuff would be nice, but is mostly just a pipe dream. I'm interested in lending a hand, but sadly I don't think I can offer much as I'm a pretty terrible programmer.

Share this post


Link to post

I just wanted to throw an idea I had into here. If you want to make this random pickup look like just one particular object (like say, I dunno, those spinning [?] boxes from Mario Kart) and not cycle through the items, but still give random stuff, you can try this. Create a new, previously nonexistent frame of whatever item you want it to give the player at that particular state. For example, CLIPB0 doesn't exist, so make a new graphic named CLIPB0 that looks however you want your randomizer item to look. Then you can have your next frame something like BON1E0, as that didn't already exist, but it still gives you a health bonus, and doesn't necessarily look like one.

Also, K!r4, when you're done with whatever this thing is, could you release it, or at least send it to me? It sounds interesting. :)

EDIT: Oh, and if you don't want individual Lost Souls being replaced with Demons in the maps, make sure that you swap the Demon and Lost Souls Thing IDs as well.

Share this post


Link to post

It's an interesting idea but I guess I will use the second sprite of each item that interest me. Thus sacrificing the animated part but it won't hurt I think.

More info soon, don't worry! It's a matter of weeks though.

Share this post


Link to post
printz said:

Does anyone have the source code of Dehacked?

Heh, funny you should ask; it's at idgames...

Share this post


Link to post

Interesting that it's not GPL; if I want to modify it I'd have to contact Tree. His email address there has a university suffix, so I think it's dead. (just why the heck did people have to rely on _universities_ to host their email servers?)

EDIT: He has a webpage with a newer email address. Fair enough. But since it's copyrighted (as in not copyleft), I won't tamper with Dehacked too much.

Share this post


Link to post

When you're a student, you get an email address at the university where you are studying. Since you tend to go there for long studies -- five years or more -- it seems enough.

Back in the days, you often also only had internet access at the university. Heck, Doom was originally first released on an university's FTP server.

Share this post


Link to post

Heh, even now I'm having a university address, for life. I'm going to use it to register to diehardwolfers.areyep.com, which has douchebag administration which forbids people with yahoo, hotmail or gmail from registering.

Share this post


Link to post

His documentation (NOTE.TXT) appears to give permission for people to modify the source and release new versions; he asks not that people ask him for permission, just that they let him know and credit him. The difference is subtle but significant. If you've made an honest effort to let him know, then you've done your duty in that respect.

Of course, since he acknowledges the borderline (il)legality of hacking id's executable in the first place, he probably didn't feel he could place too stringent a license on the software, even if he had wanted to.

If you do made a modified version, one thing you could fix is this bug. The bug affects Batman Doom, Arctic Wolf, and any other dehacked patch that edits Frame 966:

From vbatman.deh
# This is a small fix for Batman Doom. Under most source ports it runs
# fine (this patch is not needed). However, when playing under DOS with
# Vanilla Doom there is a problem caused by a limitation in DOS dehacked.
# batman.deh edits Frame 966, which is the last frame in the Doom frame
# table. However, dehacked internally allocates an array which has one
# element less than Doom itself. Therefore, editing Frame 966 overflows
# dehacked's internal array. The data instead overwrites the weaponinfo
# array.

Share this post


Link to post

Eh, I was simply thinking of looking through the useful Dehacked UI stuff that's lacking in Whacked2, such as the thing copy feature (I think).

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
×