Skip to content

Commit

Permalink
Merge pull request #23 from Eroc/main
Browse files Browse the repository at this point in the history
Remove vertical clamps on front post bobbing
  • Loading branch information
UndeadZeratul authored Dec 18, 2023
2 parents 066b34d + a09ff80 commit 951216d
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions zscript/accensus/weapons/Blackjack/blackjack.zs
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ class HDBlackjack : HDWeapon
[cx, cy, cw, ch] = Screen.GetClipRect();
sb.SetClipRect(-16 + bob.x, -4 + bob.y, 32, 12, sb.DI_SCREEN_CENTER);
vector2 bob2 = bob * 1.14;
bob2.y = clamp(bob2.y, -8, 8);
//bob2.y = clamp(bob2.y, -8, 8);
sb.DrawImage("BJCKFRNT", bob2, sb.DI_SCREEN_CENTER | sb.DI_ITEM_TOP, alpha: 0.9, scale: (0.8, 0.6));
sb.SetClipRect(cx, cy, cw, ch);
sb.DrawImage("BJCKBACK", bob, sb.DI_SCREEN_CENTER | sb.DI_ITEM_TOP, scale: (1.0, 0.8));
Expand Down Expand Up @@ -568,7 +568,7 @@ class HDBlackjack : HDWeapon

if (invoker.WeaponStatus[chamberIndex] == 1)
{
A_EjectCasing(casingCls,frandom(-1,2),(6,-frandom(79, 81),frandom(6.0, 6.5)),(0,0,-2));
A_EjectCasing(casingCls,frandom(-1,2),(frandom(0.2,0.3),-frandom(7,7.5),frandom(0,0.2)),(0,0,-2));
//A_EjectCasing(casingCls, 6, -random(79, 81), frandom(6.0, 6.5));
}

Expand Down
2 changes: 1 addition & 1 deletion zscript/accensus/weapons/Gungnir/gungnir.zs
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@ class HDGungnir : HDCellWeapon
[cx, cy, cw, ch] = Screen.GetClipRect();
sb.SetClipRect(-16 + bob.x, -4 + bob.y, 32, 16, sb.DI_SCREEN_CENTER);
vector2 bobb = bob * 1.14;
bobb.y = clamp(bobb.y, -8, 8);
//bobb.y = clamp(bobb.y, -8, 8);
sb.DrawImage("GNGRFRNT", bobb, sb.DI_SCREEN_CENTER | sb.DI_ITEM_TOP, alpha: 0.9);
sb.SetClipRect(cx, cy, cw, ch);
sb.DrawImage("GNGRBACK", (0, 3) + bob, sb.DI_SCREEN_CENTER | sb.DI_ITEM_CENTER);
Expand Down
2 changes: 1 addition & 1 deletion zscript/accensus/weapons/Jackdaw/jackdaw.zs
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ class HDJackdaw : HDWeapon
[cx, cy, cw, ch] = Screen.GetClipRect();
sb.SetClipRect(-16 + bob.x, -4 + bob.y, 32, 16, sb.DI_SCREEN_CENTER);
vector2 bob2 = bob * 1.14;
bob2.y = clamp(bob2.y, -8, 8);
//bob2.y = clamp(bob2.y, -8, 8);
sb.DrawImage("JDWFRONT", bob2, sb.DI_SCREEN_CENTER | sb.DI_ITEM_TOP, alpha: 0.9);
sb.SetClipRect(cx, cy, cw, ch);
sb.DrawImage("JDWBACK", (0, -7) + bob, sb.DI_SCREEN_CENTER | sb.DI_ITEM_TOP);
Expand Down
2 changes: 1 addition & 1 deletion zscript/accensus/weapons/Majestic/majestic.zs
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ class HDMajestic : HDHandgun
[cx, cy, cw, ch] = Screen.GetClipRect();
sb.SetClipRect(-16 + bob.x, -4 + bob.y, 32, 13, sb.DI_SCREEN_CENTER);
vector2 bob2 = bob * 1.14;
bob2.y = clamp(bob2.y, -8, 8);
//bob2.y = clamp(bob2.y, -8, 8);
sb.DrawImage("MJTCFRNT", bob2, sb.DI_SCREEN_CENTER | sb.DI_ITEM_TOP, alpha: 0.9, scale: (0.8, 0.6));
sb.SetClipRect(cx, cy, cw, ch);
sb.DrawImage("MJTCBACK", bob, sb.DI_SCREEN_CENTER | sb.DI_ITEM_TOP, scale: (0.6, 0.7));
Expand Down
2 changes: 1 addition & 1 deletion zscript/accensus/weapons/Redline/redline.zs
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ class HDRedline : HDCellWeapon
{
sb.SetClipRect(-16 + bob.x, -4 + bob.y, 32, 16, sb.DI_SCREEN_CENTER);
vector2 bob2 = bob * 1.14;
bob2.y = clamp(bob2.y, -8, 8);
//bob2.y = clamp(bob2.y, -8, 8);
sb.DrawImage("REDFRONT", bob2, sb.DI_SCREEN_CENTER | sb.DI_ITEM_TOP, alpha: 0.9);
sb.ClearClipRect();
sb.DrawImage("REDBACK", bob, sb.DI_SCREEN_CENTER | sb.DI_ITEM_TOP);
Expand Down
2 changes: 1 addition & 1 deletion zscript/accensus/weapons/Viper/viper.zs
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ class HDViper : HDHandgun
[cx, cy, cw, ch] = Screen.GetClipRect();
sb.SetClipRect(-16 + bob.x, -4 + bob.y, 32, 13, sb.DI_SCREEN_CENTER);
vector2 bob2 = bob * 1.3;
bob2.y = clamp(bob2.y, -8, 8);
//bob2.y = clamp(bob2.y, -8, 8);
sb.DrawImage("VIPRFRNT", bob2, sb.DI_SCREEN_CENTER | sb.DI_ITEM_TOP, alpha: 0.9, scale: (0.8, 0.6));
sb.SetClipRect(cx, cy, cw, ch);
sb.DrawImage("VIPRBACK", bob, sb.DI_SCREEN_CENTER | sb.DI_ITEM_TOP, scale: (0.9, 0.7));
Expand Down

0 comments on commit 951216d

Please sign in to comment.