Browse Source

♻️ Remove _misource access from SpawnLightning

pull/5054/head
Cesar Canassa 4 years ago committed by Anders Jenbo
parent
commit
831796fcd4
  1. 3
      Source/missiles.cpp

3
Source/missiles.cpp

@ -641,8 +641,7 @@ void SpawnLightning(Missile &missile, int dam)
if (!TileHasAny(pn, TileProperties::BlockMissile)) {
if (position != Point { missile.var1, missile.var2 } && InDungeonBounds(position)) {
missile_id type = MIS_LIGHTNING;
if (!missile.IsTrap() && missile._micaster == TARGET_PLAYERS
&& IsAnyOf(Monsters[missile._misource].type().type, MT_STORM, MT_RSTORM, MT_STORML, MT_MAEL)) {
if (IsAnyOf(missile.sourceMonster()->type().type, MT_STORM, MT_RSTORM, MT_STORML, MT_MAEL)) {
type = MIS_LIGHTNING2;
}
AddMissile(

Loading…
Cancel
Save