Skip to content

Commit

Permalink
Mirrored Hong Kong Helibase buttons are oriented correctly (#769)
Browse files Browse the repository at this point in the history
* rotate 06_HONGKONG_HELIBASE buttons so that they're correct on mirrored maps

* check for button event in DXRFixupM06

* remove #var(prefix) since HX doesn't replace ProjectileGenerator

---------

Co-authored-by: Die4Ever <die4ever2005@gmail.com>
  • Loading branch information
MQDuck and Die4Ever authored May 19, 2024
1 parent edb7212 commit 8c3544e
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 4 deletions.
2 changes: 2 additions & 0 deletions DXRCore/DeusEx/Classes/DXRActorsBase.uc
Original file line number Diff line number Diff line change
Expand Up @@ -892,6 +892,8 @@ static function int GetRotationOffset(class<Actor> c)
return 16384;
if(ClassIsChildOf(c, class'#var(prefix)ComputerPublic'))
return 16384;
if(ClassIsChildOf(c, class'ProjectileGenerator'))
return 16384;
//ComputerPersonal is fine without this, so just leave it commented out
//if(ClassIsChildOf(c, class'#var(prefix)ComputerPersonal'))
// return 32768;
Expand Down
15 changes: 11 additions & 4 deletions DXRMapFixups/DeusEx/Classes/DXRFixupM06.uc
Original file line number Diff line number Diff line change
Expand Up @@ -78,16 +78,16 @@ function PreFirstEntryMapFixes()
pg.ProjectileClass = class'PurgeGas';
switch(pg.Name) {
case 'ProjectileGenerator5':// left side
pg.SetRotation(rotm(-7000, 80000, 0, 16384));
pg.SetRotation(rotm(-7000, 80000, 0, GetRotationOffset(pg.class)));
break;
case 'ProjectileGenerator2':// middle left
pg.SetRotation(rotm(-6024, 70000, 0, 16384));
pg.SetRotation(rotm(-6024, 70000, 0, GetRotationOffset(pg.class)));
break;
case 'ProjectileGenerator3':// middle right
pg.SetRotation(rotm(-8056, 64000, 0, 16384));
pg.SetRotation(rotm(-8056, 64000, 0, GetRotationOffset(pg.class)));
break;
case 'ProjectileGenerator7':// right side
pg.SetRotation(rotm(-8056, 60000, 0, 16384));
pg.SetRotation(rotm(-8056, 60000, 0, GetRotationOffset(pg.class)));
break;
}
}
Expand All @@ -104,6 +104,13 @@ function PreFirstEntryMapFixes()
break;
}
}

foreach AllActors(class'Button1', b) {
if (b.tag == 'Weapons_Lock_broken' || b.tag == 'Weapons_lock' || b.event == 'missile_door') {
b.SetRotation(rot(14312, 18536, 51312)); // my guess is that the vanilla rotations were each done by eye
}
}

buttonHint = DXRButtonHoverHint(class'DXRButtonHoverHint'.static.Create(self, "", button.Location, button.CollisionRadius+5, button.CollisionHeight+5, exit));
buttonHint.SetBaseActor(button);

Expand Down

0 comments on commit 8c3544e

Please sign in to comment.