Advanced Search

Author Topic: CoreAltfire/FuncFire recode  (Read 2326 times)

0 Members and 1 Guest are viewing this topic.

October 29, 2018, 08:28:26 PM
Read 2326 times

Offline JaxOf7

  • MM8BDM Extender

  • ****
  • Date Registered: March 23, 2011, 03:56:13 AM

    • View Profile
CoreAltfire/FuncFire recode
« on: October 29, 2018, 08:28:26 PM »
Let us refer to Core Altfires as "FunctionFire"s or "FuncFire."

Let's say you want to make a mod that grants different functionality to Altfire and rebind FuncFire to a different key.
(With Megaman11 a thing, a mod that implements the gears comes to mind...)

It's a pain.
But it doesn't have to be.

That is the primary goal of this, but I've also
*Added functionality to disable weapon firing. Would make for an interesting status condition, but also helpful for bots and charge weapons.
*Eliminated the need for a seperate Altfire state for charge weapons.
*Hopefully reduced the overall amount of repasted code.
*Integrated support for "deselect fire" (like how CBM slide makes you throw in super arm if you are holding).

This first file is the suggestion itself. The recode in some example weapons which actually should exhibit no differences.

https://allfearthesentinel.net/zandronum/download.php?file=corealtfirerecode4h.pk3

Now for the interesting modding.

Add one of these after the recode. They're each pretty small.

https://allfearthesentinel.net/zandronum/download.php?file=altfireisspeedgear4h.pk3
Rebinds FuncFire to zoom, altfire to speed gear.

https://allfearthesentinel.net/zandronum/download.php?file=altfireisbuster4h.pk3
Rebinds FuncFire to zoom, altfire to buster on any weapon.

https://allfearthesentinel.net/zandronum/download.php?file=altfireclasses4h.pk3
Classes consisting of standard megaman and a class of each previous file.
Standard Megaman also has zoom for FuncFire.
Incredibly, these can all coexist.

I may or may not complete the recode for all the v5d weapons. But I don't think you're gonna see much more than what I've done.

October 30, 2018, 04:58:09 PM
Reply #1

Offline JaxOf7

  • MM8BDM Extender

  • ****
  • Date Registered: March 23, 2011, 03:56:13 AM

    • View Profile
Re: CoreAltfire/FuncFire recode
« Reply #1 on: October 30, 2018, 04:58:09 PM »
Well this is embarrassing.

So there was a desync issue with this (which I've reported here: https://zandronum.com/tracker/view.php?id=3563)
I've fixed it, but it's unsatisfactory.

While I will be using this code for my modding ventures, the aforementioned issue might make this more trouble than it's worth for core.

I don't know, maybe you do think it is still core-worthy.

Do whatever.

February 19, 2019, 12:47:45 PM
Reply #2

Offline JaxOf7

  • MM8BDM Extender

  • ****
  • Date Registered: March 23, 2011, 03:56:13 AM

    • View Profile
Re: CoreAltfire/FuncFire recode
« Reply #2 on: February 19, 2019, 12:47:45 PM »
Redone.
Beat works with v5d.
No more desync issue.
New stuff, change in suggestion scope.

Old version of first post
Spoiler for Hiden:
Let us refer to Core Altfires as "FunctionFire"s or "FuncFire."

Let's say you want to make a mod that grants different functionality to Altfire and rebind FuncFire to a different key.
(With Megaman11 a thing, a mod that implements the gears comes to mind...)

It's a pain.
But it doesn't have to be.

This first file is the suggestion itself. The recode in some example weapons which actually should exhibit no differences.

https://allfearthesentinel.net/zandronum/download.php?file=corealtfirerecode3h.pk3

But with this recode in place, we can do some interesting modding.

This example file (add after recode) rebinds FuncFire to User1 and turns altfire into speed gear.

https://allfearthesentinel.net/zandronum/download.php?file=altfireisspeedgear3.pk3

Pretty small file, huh?

This example file is bigger.
It has classes.
Standard Megaman lets you do FuncFire with Altfire or User1.
MegamanBuster lets you do MegaBuster with AltFire and FuncFire with User1. Unfortunately, getting weapons to do this right is still kind of a pain. Hopefully less of a pain.
MegamanSpeed is just the Mega from the speed gear example file.
Incredibly, these all can coexist just fine thanks to the recode.

https://allfearthesentinel.net/zandronum/download.php?file=altfireclasses3h.pk3

Minor highlight: recode eliminates the need for Altfire states on Charge Weapons. FuncFire check is just seperate from A_Refire. (Though as MetalBlade shows, it can still compliment it)

I may or may not complete the recode for all the v5c weapons. But I don't think you're gonna see much more than what I've done.

Edit:
Hold on, desync issue.
Edit2:
Fixed...

March 20, 2019, 08:09:06 AM
Reply #3

Offline JaxOf7

  • MM8BDM Extender

  • ****
  • Date Registered: March 23, 2011, 03:56:13 AM

    • View Profile
Re: CoreAltfire/FuncFire recode
« Reply #3 on: March 20, 2019, 08:09:06 AM »
Working on a mass recode for all the weps
wanted to put in basic bot support, but that sadly requires updating all these files.
So here's those, also some minor updates in general, like better metalblade.


Old files