|
| 1 | +// Visual Pinball Engine |
| 2 | +// Copyright (C) 2021 freezy and VPE Team |
| 3 | +// |
| 4 | +// This program is free software: you can redistribute it and/or modify |
| 5 | +// it under the terms of the GNU General Public License as published by |
| 6 | +// the Free Software Foundation, either version 3 of the License, or |
| 7 | +// (at your option) any later version. |
| 8 | +// |
| 9 | +// This program is distributed in the hope that it will be useful, |
| 10 | +// but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 11 | +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 12 | +// GNU General Public License for more details. |
| 13 | +// |
| 14 | +// You should have received a copy of the GNU General Public License |
| 15 | +// along with this program. If not, see <https://www.gnu.org/licenses/>. |
| 16 | + |
| 17 | +using System; |
| 18 | +using VisualPinball.Engine.Common; |
| 19 | +using VisualPinball.Engine.Game.Engines; |
| 20 | +using VisualPinball.Engine.PinMAME.MPUs; |
| 21 | +using VisualPinball.Engine.VPT.Plunger; |
| 22 | +using VisualPinball.Engine.VPT.Trough; |
| 23 | + |
| 24 | +namespace VisualPinball.Engine.PinMAME.Games |
| 25 | +{ |
| 26 | + [Serializable] |
| 27 | + public class AttackFromMars : Wpc |
| 28 | + { |
| 29 | + public override string Name { get; } = "Attack From Mars"; |
| 30 | + public override string Id { get; } = "afm"; |
| 31 | + public override int Year { get; } = 1995; |
| 32 | + public override string Manufacturer { get; } = "Bally"; |
| 33 | + public override int IpdbId { get; } = 3781; |
| 34 | + public override PinMameRom[] Roms { get; } = { |
| 35 | + new PinMameRom("afm_113", "1.13"), |
| 36 | + new PinMameRom("afm_10", "1.0"), |
| 37 | + new PinMameRom("afm_11", "1.1"), |
| 38 | + new PinMameRom("afm_11u", "1.1", "Ultrapin"), |
| 39 | + new PinMameRom("afm_11pfx", "1.1", "Pinball FX"), |
| 40 | + new PinMameRom("afm_113b", "1.13b"), |
| 41 | + new PinMameRom("afm_f10", "0.10", "FreeWPC"), |
| 42 | + new PinMameRom("afm_f20", "0.20", "FreeWPC"), |
| 43 | + new PinMameRom("afm_f32", "0.32", "FreeWPC"), |
| 44 | + }; |
| 45 | + |
| 46 | + protected override GamelogicEngineSwitch[] Switches { get; } = { |
| 47 | + new GamelogicEngineSwitch("11") { Description = "Launch Ball", InputActionHint = InputConstants.ActionPlunger }, |
| 48 | + |
| 49 | + new GamelogicEngineSwitch("13") { Description = "Start Button", InputActionHint = InputConstants.ActionStartGame }, |
| 50 | + new GamelogicEngineSwitch("14") { Description = "Plumb Bolt Tilt" }, |
| 51 | + |
| 52 | + new GamelogicEngineSwitch("16") { Description = "Left Outline" }, |
| 53 | + new GamelogicEngineSwitch("17") { Description = "Right Return Lane" }, |
| 54 | + new GamelogicEngineSwitch("18") { Description = "Shooter Lane" }, |
| 55 | + |
| 56 | + new GamelogicEngineSwitch("21") { Description = "Slam Tilt", InputActionHint = InputConstants.ActionSlamTilt }, |
| 57 | + new GamelogicEngineSwitch("22") { Description = "Coin Door Closed", NormallyClosed = true, InputActionHint = InputConstants.ActionCoinDoorOpenClose }, |
| 58 | + |
| 59 | + new GamelogicEngineSwitch("24") { Description = "Always Closed", ConstantHint = SwitchConstantHint.AlwaysClosed}, |
| 60 | + |
| 61 | + new GamelogicEngineSwitch("26") { Description = "Left Return Lane" }, |
| 62 | + new GamelogicEngineSwitch("27") { Description = "Right Outlane" }, |
| 63 | + |
| 64 | + new GamelogicEngineSwitch("31") { Description = "Trough Eject (jam)", DeviceHint = "^Trough\\s*\\d?", DeviceItemHint = "jam"}, |
| 65 | + new GamelogicEngineSwitch("32") { Description = "Trough Ball 1", DeviceHint = "^Trough\\s*\\d?", DeviceItemHint = "1" }, |
| 66 | + new GamelogicEngineSwitch("33") { Description = "Trough Ball 2", DeviceHint = "^Trough\\s*\\d?", DeviceItemHint = "2" }, |
| 67 | + new GamelogicEngineSwitch("34") { Description = "Trough Ball 3", DeviceHint = "^Trough\\s*\\d?", DeviceItemHint = "3" }, |
| 68 | + new GamelogicEngineSwitch("35") { Description = "Trough Ball 4", DeviceHint = "^Trough\\s*\\d?", DeviceItemHint = "4" }, |
| 69 | + new GamelogicEngineSwitch("36") { Description = "Left Popper", ConstantHint = SwitchConstantHint.AlwaysOpen }, |
| 70 | + new GamelogicEngineSwitch("37") { Description = "Right Popper", ConstantHint = SwitchConstantHint.AlwaysOpen }, |
| 71 | + new GamelogicEngineSwitch("38") { Description = "Left Top Lane" }, |
| 72 | + |
| 73 | + new GamelogicEngineSwitch("41") { Description = "MARTI\"A\"N Target" }, |
| 74 | + new GamelogicEngineSwitch("42") { Description = "MARTIA\"N\" Target" }, |
| 75 | + new GamelogicEngineSwitch("43") { Description = "MAR\"T\"IAN Target" }, |
| 76 | + new GamelogicEngineSwitch("44") { Description = "MART\"I\"AN Target" }, |
| 77 | + new GamelogicEngineSwitch("45") { Description = "Left Motor Bank" }, |
| 78 | + new GamelogicEngineSwitch("46") { Description = "Center Motor Bank" }, |
| 79 | + new GamelogicEngineSwitch("47") { Description = "Right Motor Bank" }, |
| 80 | + new GamelogicEngineSwitch("48") { Description = "Right Top Lane" }, |
| 81 | + |
| 82 | + new GamelogicEngineSwitch("51") { Description = "Left Slingshot (Kicker)" }, |
| 83 | + new GamelogicEngineSwitch("52") { Description = "Right Slingshot (Kicker)" }, |
| 84 | + new GamelogicEngineSwitch("53") { Description = "Left Jet Bumper" }, |
| 85 | + new GamelogicEngineSwitch("54") { Description = "Bottom Jet Bumper" }, |
| 86 | + new GamelogicEngineSwitch("55") { Description = "Right Jet Bumper" }, |
| 87 | + new GamelogicEngineSwitch("56") { Description = "\"M\"ARTIAN Target" }, |
| 88 | + new GamelogicEngineSwitch("57") { Description = "M\"A\"RTIAN Target" }, |
| 89 | + new GamelogicEngineSwitch("58") { Description = "MA\"R\"TIAN Target" }, |
| 90 | + |
| 91 | + new GamelogicEngineSwitch("61") { Description = "Left Ramp Enter" }, |
| 92 | + new GamelogicEngineSwitch("62") { Description = "Center Ramp Enter" }, |
| 93 | + new GamelogicEngineSwitch("63") { Description = "Right Ramp Enter" }, |
| 94 | + new GamelogicEngineSwitch("64") { Description = "Left Ramp Exit" }, |
| 95 | + new GamelogicEngineSwitch("65") { Description = "Right Ramp Exit" }, |
| 96 | + new GamelogicEngineSwitch("66") { Description = "Motor Bank Down" }, |
| 97 | + new GamelogicEngineSwitch("67") { Description = "Motor Bank Up" }, |
| 98 | + |
| 99 | + new GamelogicEngineSwitch("71") { Description = "Right Bank High" }, |
| 100 | + new GamelogicEngineSwitch("72") { Description = "Right Bank Low" }, |
| 101 | + new GamelogicEngineSwitch("73") { Description = "Left Loop High" }, |
| 102 | + new GamelogicEngineSwitch("74") { Description = "Left Loop Low" }, |
| 103 | + new GamelogicEngineSwitch("75") { Description = "Left Saucer Target" }, |
| 104 | + new GamelogicEngineSwitch("76") { Description = "Right Saucer Target" }, |
| 105 | + new GamelogicEngineSwitch("77") { Description = "Drop Targets" }, |
| 106 | + new GamelogicEngineSwitch("78") { Description = "Center Trough" }, |
| 107 | + }; |
| 108 | + |
| 109 | + public override GamelogicEngineLamp[] AvailableLamps { get; } = { |
| 110 | + new GamelogicEngineLamp("11") { Description = "Super Jets" }, |
| 111 | + new GamelogicEngineLamp("12") { Description = "Super Jackpot" }, |
| 112 | + new GamelogicEngineLamp("13") { Description = "Martian Attack Multi-ball" }, |
| 113 | + new GamelogicEngineLamp("14") { Description = "Annihilation" }, |
| 114 | + new GamelogicEngineLamp("15") { Description = "Return To Battle (2)" }, |
| 115 | + new GamelogicEngineLamp("16") { Description = "Conquer Mars" }, |
| 116 | + new GamelogicEngineLamp("17") { Description = "5-Way Combo" }, |
| 117 | + new GamelogicEngineLamp("18") { Description = "Drop Target" }, |
| 118 | + |
| 119 | + new GamelogicEngineLamp("21") { Description = "Big-O-Beam 1" }, |
| 120 | + new GamelogicEngineLamp("22") { Description = "Big-O-Beam 2" }, |
| 121 | + new GamelogicEngineLamp("23") { Description = "Big-O-Beam 3" }, |
| 122 | + new GamelogicEngineLamp("24") { Description = "Left Ramp Jackpot" }, |
| 123 | + new GamelogicEngineLamp("25") { Description = "Left Ramp Arrow" }, |
| 124 | + new GamelogicEngineLamp("26") { Description = "Lock 2" }, |
| 125 | + new GamelogicEngineLamp("27") { Description = "Lock 3" }, |
| 126 | + new GamelogicEngineLamp("28") { Description = "Center Ramp Jackpot" }, |
| 127 | + |
| 128 | + new GamelogicEngineLamp("31") { Description = "Tractor Beam 1" }, |
| 129 | + new GamelogicEngineLamp("32") { Description = "Tractor Beam 2" }, |
| 130 | + new GamelogicEngineLamp("33") { Description = "Tractor Beam 3" }, |
| 131 | + new GamelogicEngineLamp("34") { Description = "Right Ramp Jackpot" }, |
| 132 | + new GamelogicEngineLamp("35") { Description = "Right Ramp Arrow" }, |
| 133 | + new GamelogicEngineLamp("36") { Description = "Martian Attack" }, |
| 134 | + new GamelogicEngineLamp("37") { Description = "Rule Universe" }, |
| 135 | + new GamelogicEngineLamp("38") { Description = "Stroke Of Luck" }, |
| 136 | + |
| 137 | + new GamelogicEngineLamp("41") { Description = "Right Loop Arrow" }, |
| 138 | + new GamelogicEngineLamp("42") { Description = "Center Ramp Arrow" }, |
| 139 | + new GamelogicEngineLamp("43") { Description = "Left Top Lane" }, |
| 140 | + new GamelogicEngineLamp("44") { Description = "Right Top Lane" }, |
| 141 | + new GamelogicEngineLamp("45") { Description = "Left Motor Bank" }, |
| 142 | + new GamelogicEngineLamp("46") { Description = "Center Motor Bank" }, |
| 143 | + new GamelogicEngineLamp("47") { Description = "Right Motor Bank" }, |
| 144 | + new GamelogicEngineLamp("48") { Description = "MARTIAN Target" }, |
| 145 | + |
| 146 | + new GamelogicEngineLamp("51") { Description = "Attack Mars" }, |
| 147 | + new GamelogicEngineLamp("52") { Description = "D.C., U.S.A." }, |
| 148 | + new GamelogicEngineLamp("53") { Description = "London, England" }, |
| 149 | + new GamelogicEngineLamp("54") { Description = "Light Lock" }, |
| 150 | + new GamelogicEngineLamp("55") { Description = "Lock 1" }, |
| 151 | + new GamelogicEngineLamp("56") { Description = "Pisa, Italy" }, |
| 152 | + new GamelogicEngineLamp("57") { Description = "Berlin, Germany" }, |
| 153 | + new GamelogicEngineLamp("58") { Description = "Paris, France" }, |
| 154 | + |
| 155 | + new GamelogicEngineLamp("61") { Description = "Francois d'Grimm" }, |
| 156 | + new GamelogicEngineLamp("62") { Description = "King of Payne" }, |
| 157 | + new GamelogicEngineLamp("63") { Description = "Earl of Ego" }, |
| 158 | + new GamelogicEngineLamp("64") { Description = "Left Ramp Jackpot" }, |
| 159 | + new GamelogicEngineLamp("65") { Description = "Revolting Peasants!" }, |
| 160 | + new GamelogicEngineLamp("66") { Description = "Ugly Riot!" }, |
| 161 | + new GamelogicEngineLamp("67") { Description = "Angry Mob!" }, |
| 162 | + new GamelogicEngineLamp("68") { Description = "Rabble Rouser" }, |
| 163 | + |
| 164 | + new GamelogicEngineLamp("71") { Description = "Howard Hurtz" }, |
| 165 | + new GamelogicEngineLamp("72") { Description = "Magic Shield" }, |
| 166 | + new GamelogicEngineLamp("73") { Description = "Sir Psycho" }, |
| 167 | + new GamelogicEngineLamp("74") { Description = "Duke of Bourbon" }, |
| 168 | + new GamelogicEngineLamp("75") { Description = "Castle Lock 2" }, |
| 169 | + new GamelogicEngineLamp("76") { Description = "Castle Lock 1" }, |
| 170 | + new GamelogicEngineLamp("77") { Description = "Super Jackpot" }, |
| 171 | + new GamelogicEngineLamp("78") { Description = "Super Jets (2)" }, |
| 172 | + |
| 173 | + new GamelogicEngineLamp("81") { Description = "Right Outlane" }, |
| 174 | + new GamelogicEngineLamp("82") { Description = "Right Return" }, |
| 175 | + new GamelogicEngineLamp("83") { Description = "Left Return" }, |
| 176 | + new GamelogicEngineLamp("84") { Description = "Left Outlane" }, |
| 177 | + new GamelogicEngineLamp("85") { Description = "Castle Lock 3" }, |
| 178 | + new GamelogicEngineLamp("86") { Description = "Shoot Again" }, |
| 179 | + new GamelogicEngineLamp("87") { Description = "Launch Button" }, |
| 180 | + new GamelogicEngineLamp("88") { Description = "Start Button" } |
| 181 | + }; |
| 182 | + |
| 183 | + protected override GamelogicEngineCoil[] GameCoils { get; } = { |
| 184 | + new GamelogicEngineCoil("01", 1) { Description = "Auto Plunger", DeviceHint = "Plunger", DeviceItemHint = Plunger.FireCoilId }, |
| 185 | + new GamelogicEngineCoil("02", 2) { Description = "Trough Eject", DeviceHint = "^Trough\\s*\\d?", DeviceItemHint = Trough.EjectCoilId }, |
| 186 | + new GamelogicEngineCoil("03", 3) { Description = "Left Popper" }, |
| 187 | + new GamelogicEngineCoil("04", 4) { Description = "Right Popper" }, |
| 188 | + new GamelogicEngineCoil("05", 5) { Description = "Left Alien Low" }, |
| 189 | + new GamelogicEngineCoil("06", 6) { Description = "Left Alien High" }, |
| 190 | + new GamelogicEngineCoil("07", 7) { Description = "Knocker" }, |
| 191 | + new GamelogicEngineCoil("08", 8) { Description = "Right Alien High" }, |
| 192 | + new GamelogicEngineCoil("09", 9) { Description = "Left Slingshot" }, |
| 193 | + new GamelogicEngineCoil("10") { Description = "Right Slingshot" }, |
| 194 | + new GamelogicEngineCoil("11") { Description = "Right Slingshot" }, |
| 195 | + new GamelogicEngineCoil("12") { Description = "Left Jet Bumper" }, |
| 196 | + new GamelogicEngineCoil("13") { Description = "Bottom Jet Bumper" }, |
| 197 | + new GamelogicEngineCoil("14") { Description = "Right Alien Low" }, |
| 198 | + new GamelogicEngineCoil("15") { Description = "Saucer Shake" }, |
| 199 | + new GamelogicEngineCoil("16") { Description = "Drop Target" }, |
| 200 | + new GamelogicEngineCoil("17") { Description = "Right Ramp High Flashers", IsLamp = true }, |
| 201 | + new GamelogicEngineCoil("18") { Description = "Right Ramp Low Flasher", IsLamp = true }, |
| 202 | + new GamelogicEngineCoil("19") { Description = "Right Side High Flashers", IsLamp = true }, |
| 203 | + new GamelogicEngineCoil("20") { Description = "Right Side Low Flasher", IsLamp = true }, |
| 204 | + new GamelogicEngineCoil("21") { Description = "Center Arrow Flasher", IsLamp = true }, |
| 205 | + new GamelogicEngineCoil("22") { Description = "Jets", IsLamp = true }, |
| 206 | + new GamelogicEngineCoil("23") { Description = "Saucer Dome", IsLamp = true }, |
| 207 | + new GamelogicEngineCoil("24") { Description = "Motor Bank", IsLamp = true }, |
| 208 | + new GamelogicEngineCoil("25") { Description = "Left Ramp Left" }, |
| 209 | + new GamelogicEngineCoil("26") { Description = "Left Ramp Right" }, |
| 210 | + new GamelogicEngineCoil("27") { Description = "Left Side High" }, |
| 211 | + new GamelogicEngineCoil("28") { Description = "Left Side Low" }, |
| 212 | + new GamelogicEngineCoil("33") { Description = "Right Gate" }, |
| 213 | + new GamelogicEngineCoil("34") { Description = "Left Gate" }, |
| 214 | + new GamelogicEngineCoil("35") { Description = "Diverter Power" }, |
| 215 | + new GamelogicEngineCoil("36") { Description = "Diverter Hold", MainCoilIdOfHoldCoil = "35" }, |
| 216 | + new GamelogicEngineCoil("37") { Description = "L.E.D. Clock", IsLamp = true }, |
| 217 | + new GamelogicEngineCoil("38") { Description = "L.E.D. Data", IsLamp = true }, |
| 218 | + new GamelogicEngineCoil("39") { Description = "Strobe Light", IsLamp = true }, |
| 219 | + }; |
| 220 | + } |
| 221 | +} |
0 commit comments