RV-007 wrote: I might need such a thing for some of the more translucent/additive sprites.
Could you clarify? The sprites that have translucency/additive effect are as far as I know only projectiles (for which brightmaps are unnecessary as they are whole fullbright) - of course I may be mistaken since most of the time I play with r_drawtrans set to 0 (I don't like the effect myself, at least not on the original doom sprites)
Nash wrote:
Whoa whoa whoa hang on there, I wasn't implying any of that!
I personally find that I am always finding very awkward ways to bend ZDoom to my will so I guess we're in the same boat.
Okay, sorry for the misunderstanding.
Nash wrote:I think it's a cool thing that you did there - I just asked because I wanted clarification based on how I *think* it's done. If you're having fun modding, and if you can finish the entire pack - hey, go for it! It'll be interesting to see how you do a full implementation. I am especially interested in seeing how you are handling the relationships between the original copy of the actor and the separate brightmap pieces.
First, thanks for the kind words, and yes, you are absolutely right. I cut out the portions of the sprite meant to be fullbright (in caco's case, BHEDD1 on the right) and replaced the original caco sprite with the one with the fullbright portions missing (HEADD1 on the left)
Now I haven't done any new brightmaps since my last post because I have been wrestling with a bug, which if it persist will make further work pointless. The bug is that when I send the caco flying through the air with the SSG during its attack sequence, the brightmaps don't follow and stick to the caco itself, they stay floating in the air while the caco floats away (I couldn't capture this with the screenshot because it happens too fast but I hope you can understand what I mean)
Now, here is how I handle the relation between the caco and its brightmap effects. I simply don't understand what's wrong with the code and why the brightmaps refuse to stick to the caco. If you (or anyone) might be able to take a look at the code and lend a helping hand I would be most grateful.
Code: Select all
ACTOR BMapEffect
{
+BRIGHT
+NOGRAVITY
}
ACTOR BMapCacodemon : Cacodemon replaces Cacodemon
{
Health 10000
Mass 1
States
{
Missile:
HEAD B 0 A_SpawnItemEx("CacoEffectB", 0, 0, 0, 0, 0, 0, 0, SXF_SETMASTER)
HEAD B 5 A_FaceTarget
HEAD C 0 A_SpawnItemEx("CacoEffectC", 0, 0, 0, 0, 0, 0, 0, SXF_SETMASTER)
HEAD C 5 A_FaceTarget
HEAD D 0 A_SpawnItemEx("CacoEffectD", 0, 0, 0, 0, 0, 0, 0, SXF_SETMASTER)
HEAD D 5 //A_HeadAttack
Goto See
}
}
ACTOR CacoEffectB : BMapEffect
{
States
{
Spawn:
BHED B 1 A_Warp(AAPTR_MASTER, 0,0,0, 0, WARPF_NOCHECKPOSITION|WARPF_STOP)
BHED B 1 A_Warp(AAPTR_MASTER, 0,0,0, 0, WARPF_NOCHECKPOSITION|WARPF_STOP)
BHED B 1 A_Warp(AAPTR_MASTER, 0,0,0, 0, WARPF_NOCHECKPOSITION|WARPF_STOP)
BHED B 1 A_Warp(AAPTR_MASTER, 0,0,0, 0, WARPF_NOCHECKPOSITION|WARPF_STOP)
BHED B 1 A_Warp(AAPTR_MASTER, 0,0,0, 0, WARPF_NOCHECKPOSITION|WARPF_STOP)
BHED B 1 A_Warp(AAPTR_MASTER, 0,0,0, 0, WARPF_NOCHECKPOSITION|WARPF_STOP)
stop
}
}
It's pretty straightforward so I didn't comment it, but in case something's not clear:
BMapEffect is the parent actor for all brightmap effects. For test purposes I commented out the attack and set the mass to 1 so I could blow the caco away more easily and observe the bug effect mentioned, and high health so I don't kill it. It will spawn the relevant effect in the correct frame and position, making itself the master for the effect actor. This I have done so I could make the effect stick using A_Warp. I am unsure whether this works but isn't fast enough (in which case calling the action more than once a tic should help I think?) or whether it doesn't work at all. The other brightmap effects for the caco, and the effects for the armor bonus are all done in the same way so I didn't post them.
Also since this workaround heavily relies on decorate it will obviously break compability with any other mods modifying the monsters/decorations, so I still have doubts whether such a thing would have it's usefulness. And since actually making the "brightmap" sprites would be such a chore (and I am a lazy procrastinator) I doubt the complete version will ever see the light of day, so this will probably merely be a learning exercise- and that's why I haven't made a new thread yet.
Edit: Started thread for project
http://forum.zdoom.org/viewtopic.php?f=19&t=44901