mirror of
https://github.com/edgegamers/Jailbreak.git
synced 2025-12-06 04:42:57 -08:00
Fix S4S/M4M LR (Switch EventBulletImpact over to EventWeaponFire) (#373)
https://gitlab.edgegamers.io/source2/cs2/servers/jailbreak/-/issues/136
This commit is contained in:
@@ -34,7 +34,7 @@ public class BulletForBullet(BasePlugin plugin, IServiceProvider provider,
|
||||
=> magForMag ? LRType.MAG_FOR_MAG : LRType.SHOT_FOR_SHOT;
|
||||
|
||||
public override void Setup() {
|
||||
Plugin.RegisterEventHandler<EventBulletImpact>(OnPlayerShoot);
|
||||
Plugin.RegisterEventHandler<EventWeaponFire>(OnWeaponFire);
|
||||
|
||||
Prisoner.RemoveWeapons();
|
||||
Guard.RemoveWeapons();
|
||||
@@ -95,7 +95,7 @@ public class BulletForBullet(BasePlugin plugin, IServiceProvider provider,
|
||||
}, TimerFlags.STOP_ON_MAPCHANGE);
|
||||
}
|
||||
|
||||
private HookResult OnPlayerShoot(EventBulletImpact @event,
|
||||
private HookResult OnWeaponFire(EventWeaponFire @event,
|
||||
GameEventInfo info) {
|
||||
if (State != LRState.ACTIVE) return HookResult.Continue;
|
||||
|
||||
@@ -122,7 +122,7 @@ public class BulletForBullet(BasePlugin plugin, IServiceProvider provider,
|
||||
}
|
||||
|
||||
public override void OnEnd(LRResult result) {
|
||||
Plugin.DeregisterEventHandler<EventBulletImpact>(OnPlayerShoot);
|
||||
Plugin.DeregisterEventHandler<EventWeaponFire>(OnWeaponFire);
|
||||
State = LRState.COMPLETED;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user