Skip to content

Commit

Permalink
Merge pull request #21 from UndeadZeratul/main
Browse files Browse the repository at this point in the history
Update Muzzle Flashes to properly use Overlay Sprites
  • Loading branch information
UndeadZeratul authored Dec 14, 2023
2 parents 0c9d939 + 194001c commit 066b34d
Show file tree
Hide file tree
Showing 28 changed files with 285 additions and 152 deletions.
35 changes: 12 additions & 23 deletions TEXTURES.majestic
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// Texture definitions generated by SLADE3
// on Tue Jul 18 07:52:17 2023
// on Sat Nov 11 08:27:47 2023

Sprite "MJMGA0", 15, 10
{
Expand Down Expand Up @@ -105,23 +105,15 @@ Sprite "MJCGD0", 89, 119
Patch "MJCGD0", 0, 0
}

Sprite "MJCGE0", 110, 156
{
XScale 1.200
YScale 1.400
Offset -144, -91
Patch "MJCFA0", 0, 0
}

Sprite "MJCGF0", 89, 119
Sprite "MJCGE0", 89, 119
{
XScale 1.100
YScale 1.400
Offset -149, -131
Patch "MJCGA0", 0, 0
}

Sprite "MJCGG0", 89, 119
Sprite "MJCGF0", 89, 119
{
XScale 1.200
YScale 1.400
Expand Down Expand Up @@ -173,37 +165,34 @@ Sprite "MJ2GD0", 89, 119
}
}

Sprite "MJ2GE0", 110, 156
Sprite "MJ2GE0", 89, 119
{
XScale 1.200
XScale 1.100
YScale 1.400
Offset -130, -91
Patch "MJCFA0", 0, 0
Offset -114, -131
Patch "MJCGA0", 0, 0
{
FlipX
}
}

Sprite "MJ2GF0", 89, 119
{
XScale 1.100
XScale 1.200
YScale 1.400
Offset -114, -131
Offset -130, -128
Patch "MJCGA0", 0, 0
{
FlipX
}
}

Sprite "MJ2GG0", 89, 119
Sprite "MJCFA0", 110, 156
{
XScale 1.200
YScale 1.400
Offset -130, -128
Patch "MJCGA0", 0, 0
{
FlipX
}
Offset -144, -91
Patch "MJCFA0", 0, 0
}

// End of texture definitions
27 changes: 8 additions & 19 deletions TEXTURES.viper
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// Texture definitions generated by SLADE3
// on Sun Dec 13 22:26:10 2020
// on Fri Nov 10 18:34:03 2023

Graphic "VPMGNORM", 15, 23
{
Expand Down Expand Up @@ -82,15 +82,7 @@ Sprite "VPRGB0", 71, 97
Patch "VIPRGB0", 0, 0
}

Sprite "VPRGC0", 83, 106
{
XScale 1.100
YScale 1.300
Offset -140, -116
Patch "VIPRGC0", 0, 0
}

Sprite "VPRGD0", 71, 97
Sprite "VPRGC0", 71, 97
{
XScale 1.100
YScale 1.300
Expand Down Expand Up @@ -120,26 +112,23 @@ Sprite "VP2GB0", 71, 97
}
}

Sprite "VP2GC0", 83, 106
Sprite "VP2GC0", 71, 97
{
XScale 1.100
YScale 1.300
Offset -129, -116
Patch "VIPRGC0", 0, 0
Offset -129, -125
Patch "VIPRGD0", 0, 0
{
FlipX
}
}

Sprite "VP2GD0", 71, 97
Sprite "VPRFA0", 83, 106
{
XScale 1.100
YScale 1.300
Offset -129, -125
Patch "VIPRGD0", 0, 0
{
FlipX
}
Offset -140, -116
Patch "VIPRGC0", 0, 0
}

// End of texture definitions
Binary file modified patches/Blackjack/BLJCKGB0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified patches/Blackjack/BLJCKGC0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified patches/Gungnir/GUNGRF0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified patches/Hammerhead/BLNFA0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified patches/Hammerhead/BLNFB0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified patches/Hammerhead/BLNFC0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified patches/Hammerhead/BLNFD0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified patches/Jackdaw/JACKDWB0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified patches/Majestic/MJCFA0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified patches/Redline/RDLGF0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified patches/Scorpion/SCORPB0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified patches/Viper/VIPRGC0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified patches/Wyvern/WYVRFA0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified patches/Wyvern/WYVRFB0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified patches/Wyvern/WYVRFC0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified patches/Wyvern/WYVRFD0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified patches/Wyvern/WYVRFE0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
123 changes: 66 additions & 57 deletions zscript/accensus/weapons/Blackjack/blackjack.zs
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ class HDBlackjack : HDWeapon
Goto Ready;

Fire:
BJKG A 1
#### A 1
{
if (invoker.InvertFire.GetBool())
{
Expand All @@ -285,17 +285,17 @@ class HDBlackjack : HDWeapon
}
Goto Nope;
RealFire:
BJKF A 1 Bright
#### A 1
{
HDBulletActor.FireBullet(self, 'HDB_355', spread: 1.25, speedfactor: 1.15);
A_AlertMonsters();
invoker.WeaponStatus[BJProp_ChamberPrimary] = 1;
A_StartSound("Blackjack/Fire", CHAN_WEAPON);
A_ZoomRecoil(0.995);
A_MuzzleClimb(-frandom(0.3, 0.35), -frandom(0.40, 0.5), -frandom(0.3, 0.35), -frandom(0.40, 0.5));
A_GunFlash("Flash");
A_Overlay(PSP_FLASH, 'Flash');
}
BJKG A 2 Offset(0, 36)
#### A 2 Offset(0, 36)
{
if (invoker.WeaponStatus[BJProp_ChamberPrimary] == 1)
{
Expand All @@ -318,7 +318,7 @@ class HDBlackjack : HDWeapon
Goto Ready;

AltFire:
BJKG A 1
#### A 1
{
if (invoker.InvertFire.GetBool())
{
Expand All @@ -331,17 +331,17 @@ class HDBlackjack : HDWeapon
}
Goto Nope;
RealAltFire:
BJKF B 1 Bright
#### A 1
{
Hunter.Fire(self, 3);
A_AlertMonsters();
invoker.WeaponStatus[BJProp_ChamberSecondary] = 1;
A_StartSound("Blackjack/AltFire", CHAN_WEAPON);
A_ZoomRecoil(0.995);
A_MuzzleClimb(-frandom(1, 1.2), -frandom(1.5, 2.0), -frandom(1, 1.2), -frandom(1.5, 2.0));
A_GunFlash("Flash");
A_Overlay(PSP_FLASH, 'AltFlash');
}
BJKG A 1 Offset(0, 39)
#### A 1 Offset(0, 39)
{
if (invoker.WeaponStatus[BJProp_ChamberSecondary] == 1)
{
Expand All @@ -362,15 +362,24 @@ class HDBlackjack : HDWeapon
}
}
AltHold:
BJKG A 1;
BJKG A 0 A_Refire();
#### A 1;
#### A 0 A_Refire();
Goto Ready;
Flash:
TNT1 A 1 A_Light1();
BJKF A 1 Bright
{
HDFlashAlpha(64);
}
goto lightdone;
AltFlash:
BJKF B 1 Bright
{
HDFlashAlpha(-32);
}
goto lightdone;

Unload:
BJKG A 0
#### A 0
{
bool invert = invoker.InvertFire.GetBool();
bool sec = PressingUse() && !invert || !PressingUse() && invert;
Expand All @@ -388,12 +397,12 @@ class HDBlackjack : HDWeapon
}
Goto Nope;
UnloadChamber:
BJKG A 1 A_JumpIf(invoker.WeaponStatus[BJProp_LoadType] == 1 && invoker.WeaponStatus[BJProp_ChamberPrimary] == 0 || invoker.WeaponStatus[BJProp_LoadType] == 2 && invoker.WeaponStatus[BJProp_ChamberSecondary] == 0, 'Nope');
BJKG A 4 Offset(2, 34)
#### A 1 A_JumpIf(invoker.WeaponStatus[BJProp_LoadType] == 1 && invoker.WeaponStatus[BJProp_ChamberPrimary] == 0 || invoker.WeaponStatus[BJProp_LoadType] == 2 && invoker.WeaponStatus[BJProp_ChamberSecondary] == 0, 'Nope');
#### A 4 Offset(2, 34)
{
A_StartSound("Blackjack/BoltPull", 8);
}
BJKG A 6 Offset(1, 36)
#### A 6 Offset(1, 36)
{
if (invoker.WeaponStatus[BJProp_LoadType] == 1)
{
Expand All @@ -408,12 +417,12 @@ class HDBlackjack : HDWeapon
invoker.WeaponStatus[BJProp_ChamberSecondary] = 0;
}
}
BJKG A 2 Offset(0, 34);
#### A 2 Offset(0, 34);
Goto ReadyEnd;

Reload:
AltReload:
BJKG A 0
#### A 0
{
bool invert = invoker.InvertFire.GetBool();

Expand Down Expand Up @@ -444,13 +453,13 @@ class HDBlackjack : HDWeapon
}
Goto UnMag;
LoadChamber:
BJKG A 1 Offset(0, 34) A_StartSound("weapons/pocket", 9);
BJKG A 1 Offset(2, 36);
BJKG A 1 Offset(2, 44);
BJKG A 1 Offset(5, 54);
BJKG A 2 Offset(7, 60);
BJKG A 6 Offset(8, 70);
BJKG A 5 Offset(8, 77)
#### A 1 Offset(0, 34) A_StartSound("weapons/pocket", 9);
#### A 1 Offset(2, 36);
#### A 1 Offset(2, 44);
#### A 1 Offset(5, 54);
#### A 2 Offset(7, 60);
#### A 6 Offset(8, 70);
#### A 5 Offset(8, 77)
{
if (invoker.WeaponStatus[BJProp_LoadType] == 1 && CheckInventory("HDRevolverAmmo", 1))
{
Expand All @@ -465,27 +474,27 @@ class HDBlackjack : HDWeapon
A_StartSound("Blackjack/ChamberQuick", 8);
}
}
BJKG A 3 Offset(9, 74);
BJKG A 2 Offset(5, 70);
BJKG A 1 Offset(5, 64);
BJKG A 1 Offset(5, 52);
BJKG A 1 Offset(5, 42);
BJKG A 1 Offset(2, 36);
BJKG A 2 Offset(0, 34);
#### A 3 Offset(9, 74);
#### A 2 Offset(5, 70);
#### A 1 Offset(5, 64);
#### A 1 Offset(5, 52);
#### A 1 Offset(5, 42);
#### A 1 Offset(2, 36);
#### A 2 Offset(0, 34);
Goto Nope;

UnMag:
BJKG A 1 Offset(0, 34);
BJKG A 1 Offset(5, 38);
BJKG A 1 Offset(10, 42);
BJKG A 3 Offset(20, 46) A_MuzzleClimb(0.3, 0.4);
BJKG A 2 Offset(26, 52) A_MuzzleClimb(0.3, 0.4);
BJKG A 2 Offset(26, 54)
#### A 1 Offset(0, 34);
#### A 1 Offset(5, 38);
#### A 1 Offset(10, 42);
#### A 3 Offset(20, 46) A_MuzzleClimb(0.3, 0.4);
#### A 2 Offset(26, 52) A_MuzzleClimb(0.3, 0.4);
#### A 2 Offset(26, 54)
{
A_StartSound("Blackjack/MagOut", 8);
A_MuzzleClimb(0.3, 0.4);
}
BJKG A 0
#### A 0
{
int type = invoker.WeaponStatus[BJProp_LoadType];
int magAmt = invoker.WeaponStatus[type == 1 ? BJProp_MagPrimary : BJProp_MagSecondary];
Expand All @@ -510,21 +519,21 @@ class HDBlackjack : HDWeapon
}
}
PocketMag:
BJKG AAAAAA 5 Offset(26, 54) A_MuzzleClimb(frandom(0.2, -0.8),frandom(-0.2, 0.4));
#### AAAAA 5 Offset(26, 54) A_MuzzleClimb(frandom(0.2, -0.8),frandom(-0.2, 0.4));
MagOut:
BJKG A 0
#### A 0
{
if (invoker.WeaponStatus[BJProp_Flags] & BJF_JustUnload)
{
SetWeaponState('ReloadEnd');
}
}
LoadMag:
BJKG A 0 A_StartSound("weapons/pocket", 9);
BJKG A 6 offset(34, 54) A_MuzzleClimb(frandom(0.2, -0.8), frandom(-0.2, 0.4));
BJKG A 7 offset(34, 52) A_MuzzleClimb(frandom(0.2, -0.8), frandom(-0.2, 0.4));
BJKG A 10 offset(32, 50);
BJKG A 3 offset(32, 49)
#### A 0 A_StartSound("weapons/pocket", 9);
#### A 6 offset(34, 54) A_MuzzleClimb(frandom(0.2, -0.8), frandom(-0.2, 0.4));
#### A 7 offset(34, 52) A_MuzzleClimb(frandom(0.2, -0.8), frandom(-0.2, 0.4));
#### A 10 offset(32, 50);
#### A 3 offset(32, 49)
{
class<Inventory> whichCls = invoker.WeaponStatus[BJProp_LoadType] == 1 ? 'HDBlackjackMag355' : 'HDBlackjackMagShells';
int whichIndex = invoker.WeaponStatus[BJProp_LoadType] == 1 ? BJProp_MagPrimary : BJProp_MagSecondary;
Expand All @@ -538,18 +547,18 @@ class HDBlackjack : HDWeapon
Goto ReloadEnd;

ReloadEnd:
BJKG A 2 Offset(30, 52);
BJKG A 2 Offset(20, 46);
BJKG A 2 Offset(10, 42);
BJKG A 2 Offset(5, 38);
BJKG A 1 Offset(0, 34);
#### A 2 Offset(30, 52);
#### A 2 Offset(20, 46);
#### A 2 Offset(10, 42);
#### A 2 Offset(5, 38);
#### A 1 Offset(0, 34);
Goto ChamberManual;

ChamberManual:
BJKG A 0 A_JumpIf(invoker.WeaponStatus[BJProp_LoadType] == 1 && (invoker.WeaponStatus[BJProp_MagPrimary] <= 0 || invoker.WeaponStatus[BJProp_ChamberPrimary] == 2) || invoker.WeaponStatus[BJProp_LoadType] == 2 && (invoker.WeaponStatus[BJProp_MagSecondary] <= 0 || invoker.WeaponStatus[BJProp_ChamberSecondary] == 2), "Nope");
BJKG A 2 Offset(2, 34);
BJKG A 4 Offset(3, 38);
BJKG A 5 Offset(4, 44)
#### A 0 A_JumpIf(invoker.WeaponStatus[BJProp_LoadType] == 1 && (invoker.WeaponStatus[BJProp_MagPrimary] <= 0 || invoker.WeaponStatus[BJProp_ChamberPrimary] == 2) || invoker.WeaponStatus[BJProp_LoadType] == 2 && (invoker.WeaponStatus[BJProp_MagSecondary] <= 0 || invoker.WeaponStatus[BJProp_ChamberSecondary] == 2), "Nope");
#### A 2 Offset(2, 34);
#### A 4 Offset(3, 38);
#### A 5 Offset(4, 44)
{
A_StartSound("Blackjack/BoltPull", 8, CHANF_OVERLAP);
int type = invoker.WeaponStatus[BJProp_LoadType];
Expand All @@ -567,9 +576,9 @@ class HDBlackjack : HDWeapon
invoker.WeaponStatus[chamberIndex] = 2;
A_WeaponBusy();
}
BJKG A 2 Offset(3, 38);
BJKG A 2 Offset(2, 34);
BJKG A 2 Offset(0, 32);
#### A 2 Offset(3, 38);
#### A 2 Offset(2, 34);
#### A 2 Offset(0, 32);
Goto Nope;
}
}
Expand Down
Loading

0 comments on commit 066b34d

Please sign in to comment.