Major Sea of Runes work

I have been running a Sorcery/Nature guy.  I have made some improvement to the spell use for those realms.  I also made a serious overhaul to the Sea of Runes routines.

  • Added a cost to the racial attacks and the cost is greater if he’s lower on mana or HP.
  • Reordered and reworked the defence routine of summoning helpers.  Its now more depth dependant.  It was futile to summon a red centipede on dungeon depth 45.
  •  Added a cost to the mutation and racial attacks.  This cost will reduce the reward for using the effect.
  •  Added a check in borg_launch_damage_one() which will eliminate using extremely low damage attacks against a powerful enemy.  Ie, no long will the borg use a damage 5 offset-ball attack against a creature with 2800 HP.
  •  Added the other sorcery source of ESP to the borg_perma maneuvers as well as granting the BI_SESP (source of ESP] flag to spells so the borg could dive deeper.  This source is checked in the borg_prep code.  Also added a BI_SSINV as a source from spells.
  •  Allowed the tracking of unique monsters over a greater distance so as to avoid creating multiple instances of them.
  •  Removed the code that deleted a monster if it didn’t move during its turn (borg_follow_kill())
  •  Borg_escape() will try to forbid teleporting if the borg is in an as_corridor and fighting a unique.
  •  Rework on borg_follow_kill() which attempts to guess the current grid of a monster that is now not visable.
  •  No need to flow to a recover grid if sitting in an as_corridor.  Its as safe as anything else.
  •  Attempt to use borg_recover() if sitting in a as_corridor, prior to leaving it.  There is a reason why we were there.  Lets heal up before venturing out.
  •  Borg_attack_aux_rest() needed a time check to make sure the borg didn’t wait ad nauseam.
  •  Better DimDoor support added to certain flow routines and made the borg_dim_door_to() more useful to other routines who borrow it.
  •  Borg_kills_summoner will be linked to the flow distance for a summoner instead of normal distance().  Change made in borg_near_monster_type()
  •  Rework the monster flow depth to be based on the compilier flag of MONSTER_FLOW and the tuned for individual races (r_ptr->aaf).  Also added some support into borg_near_monster_type() for the flag borg_kills_summoner.  I also reworked the flow_spread_m() to more closely match the game’s internal calculation.  The result is really nice.
  •  Extensive rework the BORG_VIEW array in order to reduce the number of calls to borg_los().
  •  Added support for magical figurines being thown as weapons and kept in the inventory.
  •  Fixed a crash in borg_think_home_sell_aux().
  •  Backing up (from borg_caution()) will grant a more favorable result to a grid which is occupied by a pet.  The will swap places with the pet and throw it under bus.  He already knew how to use the mutation of swap position but not a manual displacement.
  •  Borg will not purchase (grab for home) mundane equipment. If can find those in the dungeon.
  •  The ‘bored’ flag in borg_leave_level is made false if the borg is fighting a questor monster.
  •  Added the Nature spell of Explosive Rune to the functions calling runes.
  •  Tweaked with the defense maneuver for speed to encourage the borg to cast it if questor or uniques were on the level.
  •  bool DEPTH_QUEST_level was always set to false, but I added support to keep it accurate.
  •  Resequenced the teleport other sources to as to conserve mana and use up charges first.
  •  Slight bug fix on calculating targets of Teleport Other.
  •  borg_fear_region[y][x] will reduce more quickly.
  •  Added a flag called BI_NSRANGED, which is a ‘Non-Spell Ranged Attack.’  It is used in teleporting away monsters while in a sea of runes.
  •  Water and Lava will no longer be considered vison blocking layers like doors and walls.
  •  The Nature Realm spell of Whirlwind attack needed to check if an adjacent monster was a pet or friendly.
  •  Borg_check_rest() would look for pets/friendlies when considering the rest.  But he was doing so after a check for breeders.  The ally check was moved higher so that the borg would be allowed to rest near a friendly/ally breeder.
  • The borg tracks when breeders are killed.  He does this so he does not rest next to an unexplored area full of unknown breeders.  But I added a check to avoid this check if the breeder was a pet.  This way, he can rest if a breeder was recently killed.
  •  Borg will not recall back to town to fix his XP if the dlevel has (morgoth | quest)
  •  Some interesting improvements to the Sea of Runes behavior:
    •  Borg will use it when he encounters questors who can bore through walls.
    •  Once the sea is fully set up, he will continue excavate the regional dungeon using S2M in order to increase the number of shots on the tunneling monster.
    •  Will use Light Beam to illuminate the recently excavated grid so he no longer assumes that it is a wall grid (which would have limited his LOS() and shots).
    •  Will rest there as a defence maneuver and as an attack maneuver in order to correctly make normal attacks and wait for monsters to approach.
    •  Will wait about 500 rounds for tunneling to approach.  If not seen then he goes on the hunt and behaves normally.
    •  Will use Teleport Other to get others away from the area he is trying to use for a Sea of Runes.
    •  Can excavate an area and build the see instead of having to find a room with the right dimensions.
    •  Can wait for a bit, then leave the sea to go hunt around.
    •  Can return to the existing sea or build a new one following the hunt.
    •  Will create a 5×5 or 3×3 grid based on how affordable the glyph spell is.
    •  The borg will consider the terrain when using Teleport Other spell.  Since some monsters are not able to cross certain terrains, they are less of a threat.
  •  I added several bitwise flags to the borg code to manage his special position behavior and special questor/unique monster appearances.
  •  Improved the use of the perma-spell of resistance.  He was still casting it, even though he had 3 immunities.

 

This entry was posted in Zangband 240 and tagged , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *