Skip to content

Commit

Permalink
Ac!d's Eriguns preliminary support
Browse files Browse the repository at this point in the history
Still need to make some icons.

Known Issues: Two weapons have modes that access a ZScript local variable, which as far as I know can't be reached by ACS, so these will be handled in a later update.
  • Loading branch information
FelesNoctis committed Sep 19, 2022
1 parent a1adb7f commit e9f9fb0
Show file tree
Hide file tree
Showing 7 changed files with 711 additions and 4 deletions.
Binary file modified ACS/HXAMODCM.o
Binary file not shown.
Binary file added ACS/HXMACID.o
Binary file not shown.
24 changes: 23 additions & 1 deletion ACSSourceCodes/HXAMODCM.acs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ str hxmod_none = "HXMOD_VANILLA";
str hxmod_resettoken = "HXMOD_IDontExist";
str hxmod_modfound = "HXMOD_MODFOUND";
str hxmod_64art = "HXMOD_Doom64Art";
str hxmod_acideriguns = "HXMOD_AcidEriguns";
str hxmod_bdlite = "HXMOD_BDLite";
str hxmod_beautifuldoom = "HXMOD_BeautifulDoom";
str hxmod_brutaldoom = "HXMOD_BrutalDoom";
Expand Down Expand Up @@ -41,15 +42,21 @@ str hxmod_weapononlyammo1 = "HXMOD_WeaponOnlyAmmo1";
str vanillaberserk = "PowerStrength";
str hxgen_berserk = "HX_BerserkPowerUpToken";
str hxgen_haste = "HX_HastePowerUpToken";
str hxgen_hastelong = "HX_HastePowerUpLongTimerToken";
str vanillainfrared = "PowerLightamp";
str hxgen_infrared = "HX_InfraredPowerUpToken";
str hxgen_infraredlong = "HX_InfraredPowerUpLongTimerToken";
str vanillainvisibility = "PowerInvisibility";
str hxgen_invisibility = "HX_InvisibilityPowerUpToken";
str hxgen_invisibilitylong = "HX_InvisibilityPowerUpLongTimerToken";
str vanillainvulnerability = "PowerInvulnerable";
str hxgen_invulnerability = "HX_InvulnerabilityPowerUpToken";
str hxgen_invulnerabilitylong = "HX_InvulnerabilityPowerUpLongTimerToken";
str hxgen_quaddamage = "HX_QuadDamagePowerUpToken";
str hxgen_quaddamagelong = "HX_QuadDamagePowerUpLongTimerToken";
str vanillaradsuit = "PowerIronfeet";
str hxgen_radsuit = "HX_RadSuitPowerUpToken";
str hxgen_radsuitlong = "HX_RadSuitPowerUpLongTimerToken";
/* str vanillabluecard = "BlueCard";
str hxgen_bluecard = "HX_BlueCardKeyToken";
str vanillablueskull = "BlueSkull";
Expand All @@ -63,6 +70,11 @@ str hxgen_yellowcard = "HX_YellowCardKeyToken";
str vanillayellowskull = "YellowSkull";
str hxgen_yellowskull = "HX_YellowSkullKeyToken"; */

// Ac!d's Eriguns
str acidclass = "EriPlayer";
str acidfist = "EriFist";
str acidpistol = "EriPistol";

// Beautiful Doom
str beautifulbloodcontrol = "BD_BloodyPrintControl";
str beautifuloverlaycontrol = "BD_OverlayControl";
Expand Down Expand Up @@ -179,8 +191,18 @@ script "HXS_ModCompatibilityStartup" enter
} */

// Mod Master Tokens
// Ac!d's Eriguns
if (CheckActorClass(0, acidclass)
&& CheckInventory(acidfist)
&& CheckInventory(acidpistol)
&& !CheckInventory(hxmod_acideriguns))
{
GiveInventory(hxmod_modfound, 1);
GiveInventory(hxmod_acideriguns, 1);
if (CheckInventory(hxmod_none)) { TakeInventory(hxmod_none, 1); }
}
// Beautiful Doom 7.1.6
if (CheckInventory(beautifulbloodcontrol)
else if (CheckInventory(beautifulbloodcontrol)
&& CheckInventory(beautifuloverlaycontrol)
&& CheckInventory(beautifulweaponcontrol)
&& !CheckInventory(hxmod_beautifuldoom))
Expand Down
93 changes: 93 additions & 0 deletions ACSSourceCodes/HXMACID.acs
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
#library "HXMACID"
#include "zcommon.acs"
#import "HXAMODCM.acs"
#import "HXACVAR.acs"

str eri_buddha = "PowerEriBuddha";
str hx_eri_buddha = "HX_Acid_BuddhaPowerUpToken";
str hx_eri_buddhalong = "HX_Acid_BuddhaPowerUpLongTimerToken";
str eri_haste = "EriPowerSpeed";
str eri_infrared = "PowerEriInfrared";
str eri_invisibility = "PowerEriBlurSphere";
str eri_invulnerability = "PowerEriInvulnerabilitySphere";
str eri_quaddamage = "PowerEriQuadDamage";
str eri_radsuit = "PowerEriRadSuit";
str hx_eri_pins = "HX_Acid_Eri_PINS";
str hx_eri_pinv = "HX_Acid_Eri_PINV";
str hx_eri_pstr = "HX_Acid_Eri_PSTR";

script "HXS_AcidEriguns35ticHandler" enter
{
// Wait 35 tics (1sec) before engaging, to make sure the token has been given
delay(35);

if (CheckInventory(hxmod_acideriguns)) {
while (true)
{
/* // Key Management Tokens
// Blue Keys
HXS_ItemSync(vanillabluecard, hxgen_bluecard);
HXS_ItemSync(vanillablueskull, hxgen_blueskull);
// Red Keys
HXS_ItemSync(vanillaredcard, hxgen_redcard);
HXS_ItemSync(vanillaredskull, hxgen_redskull);
// Yellow Keys
HXS_ItemSync(vanillayellowcard, hxgen_yellowcard);
HXS_ItemSync(vanillayellowskull, hxgen_yellowskull); */

// Powerup Management Tokens
// Berserk
HXS_ItemSync(vanillaberserk, hxgen_berserk);

// Timer
// Wait 35 tics (~1sec) before repeating, since we want this to be a clock
delay(35);
}
}
}

script "HXS_AcidEriguns7ticHandler" enter
{
// Wait 35 tics (1sec) before engaging, to make sure the token has been given
delay(35);

if (CheckInventory(hxmod_acideriguns)) {
while (true)
{
// Powerup Management Tokens
// Buddha
HXS_PowerupTimer(eri_buddha, hx_eri_buddha);
HXS_PowerupTimer(eri_buddha, hx_eri_buddhalong);
// Haste
HXS_PowerupTimer(eri_haste, hxgen_haste);
HXS_PowerupTimer(eri_haste, hxgen_hastelong);
// Infrared
HXS_PowerupTimer(eri_infrared, hxgen_infrared);
HXS_PowerupTimer(eri_infrared, hxgen_infraredlong);
// Invisibility
HXS_PowerupTimer(eri_invisibility, hxgen_invisibility);
HXS_PowerupTimer(eri_invisibility, hxgen_invisibilitylong);
// Invulnerability
HXS_PowerupTimer(eri_invulnerability, hxgen_invulnerability);
HXS_PowerupTimer(eri_invulnerability, hxgen_invulnerabilitylong);
// Quad Damage
HXS_PowerupTimer(eri_quaddamage, hxgen_quaddamage);
HXS_PowerupTimer(eri_quaddamage, hxgen_quaddamagelong);
// Radsuit
HXS_PowerupTimer(eri_radsuit, hxgen_radsuit);
HXS_PowerupTimer(eri_radsuit, hxgen_radsuitlong);

// Powerup Display Toggles
// Berserk & Quad Damage
HXF_CVARConvert_Generic("Eri_PSTR", hx_eri_pstr);
// Invisibility & Haste
HXF_CVARConvert_Generic("Eri_PINS", hx_eri_pins);
// Invulnerability & Buddha
HXF_CVARConvert_Generic("Eri_PINV", hx_eri_pinv);

// Timer
// Wait 7 tics (1/5sec) before repeating, since we want this to be reasonably responsive
delay(7);
}
}
}
13 changes: 13 additions & 0 deletions DECO/HXTOKENS.txt
Original file line number Diff line number Diff line change
Expand Up @@ -30,16 +30,29 @@ ACTOR HXMOD_WeaponDualWieldUniqueAmmo: Inventory { +INVENTORY.UNDROPPABLE Invent
ACTOR HXMOD_WeaponOnlyAmmo1: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 1 }
ACTOR HX_BerserkPowerUpToken: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 1 }
ACTOR HX_HastePowerUpToken: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 60 }
ACTOR HX_HastePowerUpLongTimerToken: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 999 }
ACTOR HX_InfraredPowerUpToken: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 120 }
ACTOR HX_InfraredPowerUpLongTimerToken: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 999 }
ACTOR HX_InvisibilityPowerUpToken: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 60 }
ACTOR HX_InvisibilityPowerUpLongTimerToken: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 999 }
ACTOR HX_InvulnerabilityPowerUpToken: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 30 }
ACTOR HX_InvulnerabilityPowerUpLongTimerToken: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 999 }
ACTOR HX_QuadDamagePowerUpToken: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 30 }
ACTOR HX_QuadDamagePowerUpLongTimerToken: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 999 }
ACTOR HX_RadSuitPowerUpToken: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 60 }
ACTOR HX_RadSuitPowerUpLongTimerToken: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 999 }
ACTOR HX_ShieldPowerUpToken: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 1 }
// Mod Master Token
ACTOR HXMOD_MODFOUND: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 1 }
// No Mods Detected/Vanilla
ACTOR HXMOD_VANILLA: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 1 }
// Ac!d's Eriguns
ACTOR HXMOD_AcidEriguns: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 1 }
ACTOR HX_Acid_BuddhaPowerUpToken: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 60 }
ACTOR HX_Acid_BuddhaPowerUpLongTimerToken: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 999 }
ACTOR HX_Acid_Eri_PINS: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 2 }
ACTOR HX_Acid_Eri_PINV: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 2 }
ACTOR HX_Acid_Eri_PSTR: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 2 }
// BDLite 1.2
ACTOR HXMOD_BDLite: Inventory { +INVENTORY.UNDROPPABLE Inventory.MaxAmount 1 }
// Beautiful Doom
Expand Down
1 change: 1 addition & 0 deletions LOADACS
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ HXAMODCM
HXACVAR
HXASTATS
HXMVAN
HXMACID
HXMBD
HXMBDPUN
HXMBDL
Expand Down
Loading

0 comments on commit e9f9fb0

Please sign in to comment.