dregs Posted February 1, 2022 Has this been done before? Is this the right place for it? Dehacked uses MISC1 and MISC2 for some actor functions. but not weapons because of how some ports render the weapon. Some ports treat the misc values as offsets. My proposal changes the order of how misc is handled It's just a if action else offsets I have written some example functions that i would like seen in Dehacked one day. I have also created a test wad and .bex file to showcase it. - JumpIfAmmoMod Jumps to MISC1 if ammo is modulo to MISC2. unfortunatly this means that you are restricted to factors of 5 or 2 for most weapons -JumpIfBezerk Jumps to MISC1 if bezerk is active, for alternative attacks -RefireJump Unlike A_Refire, this allows you to jump to any state via MISC1. The example wad uses the plasma gun and gives it a windup time -PRandomJump A port of RandomJump for actors. misc's are the same but for weapons -FireProjectile Fires a custom projectile defined in MISC1. the example adds a "grenade" launcher without affecting the cyberdemons rockets. -CheckReload2 checks if ammo is less than MISC1 or zero. jumps to lower state. -CustomBulletsBasic This is the start of my worries, since yes you *can* cram multiple values into one space and take them out via bitwising. but since long types are dependent on the system it would need to be only as big as the smallest possible size, which is 32-bits(?). its what i used MISC1 is divided into three bytes. The first the angle for horizontal spread, next is vertical spread and finally there's the ammo cost. this function does not check the remaining ammo count. MISC2 is one byte and one half nibble. its pellet count for the byte and the half nibble is the 'damage threshold' Damage threshold is only four options: 0 is the default 5-15, steps of 5 1 is lowest; 1-5, in steps of 1 2 is from 5-10, in steps of 1 and 3 is 10-15 in steps of 1 Obviously CustomBulletsBasic would be a slight pain to calculate the values needed. My implementation of how it converts those byte angles into something useful is also janky -CustomMelee same as normal melee. no ammocost option right now. its just a copy of A_Punch MISC2 is the range MISC1's first two bytes is the damage output. the 17th bit is if you want it to be affected by bezerker multipliers. The major bug is if you move and then shoot. your weapon may jitter. this can be seen with the revolver in the example wad. Spoiler Why not just use decorate or zscript? because i don't want to use it. I don't actually know if it would compile on other computers. i'm new to this, and i already wrote it. A more coherent explanation may be found in p_pspr.c not saying this is silver font. its probably a bit nutty prboom-plus-testing.7z 0 Share this post Link to post
hobomaster22 Posted February 1, 2022 I believe everything you want is here:https://github.com/kraflab/mbf21/blob/master/docs/spec.md Currently implemented in DSDA-Doom, GZDoom, and I believe Eternity as well. 0 Share this post Link to post
dregs Posted February 1, 2022 (edited) 28 minutes ago, hobomaster22 said: I believe everything you want is here:https://github.com/kraflab/mbf21/blob/master/docs/spec.md Currently implemented in DSDA-Doom, GZDoom, and I believe Eternity as well. the point of this is to add extra weapon functions to Dehacked. these have parameters like what was implemented for mobs never mind, wait. does prboom-plus have this? thats the major reason why i did this. 0 Share this post Link to post
Redneckerz Posted February 1, 2022 26 minutes ago, dregs said: the point of this is to add extra weapon functions to Dehacked. these have parameters like what was implemented for mobs never mind, wait. does prboom-plus have this? thats the major reason why i did this. PrBoom+ has stopped development. What we now have is PrBoom+UM and the successor DSDA-Doom. DSDA-Doom implements several new standards: DEHEXTRA MBF21 DSDHacked 0 Share this post Link to post
LuciferSam86 Posted February 1, 2022 (edited) If you want to check an example for weapons made with MBF21 standard, there is this excellent mod made by Xaser, but on GZDoom 4.7.1 doesn't work (MBF21 on latest stable GZDoom version (4.7.1 MBF21 support it's still in beta, I think for the next versions 4.8.x will be fixed) Edited February 1, 2022 by LuciferSam86 0 Share this post Link to post
MTrop Posted February 1, 2022 MBF21/DSDHacked is also supported by DECOHack (part of DoomTools). It requires some kind of DECORATE-ish know-how, but it compiles to DeHackEd. Disclosure: I wrote DECOHack. 2 Share this post Link to post
fabian Posted February 3, 2022 On 2/1/2022 at 4:40 PM, hobomaster22 said: I believe everything you want is here:https://github.com/kraflab/mbf21/blob/master/docs/spec.md Currently implemented in DSDA-Doom, GZDoom, and I believe Eternity as well. And Woof! 2 Share this post Link to post
fabian Posted February 3, 2022 (edited) On 2/1/2022 at 4:13 PM, dregs said: but not weapons because of how some ports render the weapon. Some ports treat the misc values as offsets. Because that's what Doom actually does: https://github.com/chocolate-doom/chocolate-doom/blob/41865b179684eaf812fc9682936d9b79320f5a1d/src/doom/p_pspr.c#L73 Edited February 4, 2022 by fabian 1 Share this post Link to post
bradharding Posted February 4, 2022 On 2/2/2022 at 2:40 AM, hobomaster22 said: I believe everything you want is here:https://github.com/kraflab/mbf21/blob/master/docs/spec.md Currently implemented in DSDA-Doom, GZDoom, and I believe Eternity as well. And Doom Retro! :D 3 Share this post Link to post