
Hobby page of Dr. Andrew White
Choose your first Destination:
| D&D Stuff |
Vanilla Angband Borg.
On this page, I share information about my borg. The borg is an automatic player for the game Angband. To learn more about Angband, check out the Official Angband Home Page. This borg runs on the most recent vanilla version (3.0.6), as well as DrAngband and Zangband 240. You can find executables for Windows here. If you need a DOS executable, email me and I'll send one to you. I work on it daily. So check this site often for the latest version
These files were last updated on 6 Septempber 2008. All files compressed in a .zip format.
Please make sure your borg.txt file is located in your \lib\user\ directory.
Vanilla Angband 309B:
Borg Source--You
will need the rest of the game source. Be sure to have the
ALLOW_BORG_GRAPHICS turned on in
config.h if you want to use graphics. This source code works
only
with Angband
3.0.9b. You need to make sure that the game source files included here
write over the original game source. There are several changes to the
game
source in order for the 309b borg to run.
309b Windows Executable --For 3.0.9b. Just the Windows EXE file with some required borg files.
309b Windows Borg ScreenSaver Executable-- The borg engine updated. You will need the rest of the supporting files. Read the Borgread.txt for installation
Vanilla Angband 306 and 305:DrAngband 299:
Drangband Borg.
You may want to visit the
Drangband
Homepage to learn more about it.
Zangband 240:
Zangband Borg Source. You
may want to visit the ZBorg
page
to learn more about it.
Information on this Borg and my To Do list
Parts of this code came from Adam Goodman. He did the work on *ID*, home optimization, borg_prep, speeding up a borg with telepathy, and basic borg defense routines. I expanded on each one, but he laid down the important skeleton. He also wrote the code for the Dynamic Calcs. Which allow external influences on the borg behavior. He deserves a huge thanks.
Be sure to modify your delay under the Options menu to watch the borg. If you have questions or want to know how certain bugs were squashed, just drop me and email at apwhite@itctel.com As I mentioned, improvements are made on a daily basis. Your comments are greatly appreciated. If there is a command or certain things you would recommend for the borg, just email a description to me.
This borg is customizable. Meaning you can select certain play options and have the borg play along those themes. To learn more, read the borg.txt file located in the file archives.
Click Here to see a massive list of what sets my borg apart from the others. It is truely impressive.
All bug reports are appreciated.
To Do List:
-The borg does not pickup Grond or the Massive Crown.
-Fix the bug with big screens. If the borg resumes a game
which had been
regular sized screen, but is now a large screen then the borg will
crash the
game. The borg will not crash if the screen is expaned in town. If the
game was
saved with a large screen, and the borg resumes a large screen game, it
will
not crash. So if you want to play the borg in a large screen, make the
change
in town or wizard light (or clairevoyance) the whole level before
activating
the borg.
Very bad things can happen if the borg is used in Big Screen
mode. It is
recommended that you not use Big Screen.
Statistics on Borg Deaths/Survivability
Tables of various borg deaths. Made from Excell using Pivot Tables. (special thx to Dan L.)
Send me your Winners, as well as your borg.dat if it has more than 100 deaths listed and I can add them to the database
Rephial from Andrew Sidwell. He has cool graphics on his page. Not at all like the rest of us.
The Official DrAngband Homepage. The variant of this wonderful game, with new dragon races and much, much more. Maintained by myself.
Amiga & Variants Page from Bablos. He has compiled many of the amiga versions and has links to just about every variant out there. There is also a link to borg statistics.
If your link is not here and you would like it to be, email me the address.
Daily
Record of Changes
Archive of old changes.
September 6, 2008, 1) The borg was unhooking when he was hit with an amnesia attack. I identified 4 possible causes due to item activation and corrected them. If another shows up sometime, let me know.
September 3, 2008, 1) A few out of bounds corrections which might have caused crashes if the monsters were very close to the edge of the map. 2) Big improvements to how a borg handles vaults. There is improved excavation of a vault, handling fear, and resting.
August 31, 2008, 1) Corrected a failed bounds check which could result in a crash if a monster is located very close to the edge of the map.
August 28, 2008, 1) The function borg_check_rest() which evaluated the safety of the borg's grid before he rested on it, needed a slight fix. 2) Fixed a potential crash related to monster creation. 3) The borg is misparsing the message line on some messages. It is difficult to catch him doing it. The borg would use Term_Locate() to identify the location of the cursor. In prior versions the game the cursor fell in the message line. Now it seems to be falling onto the borg following the message. The borg used the cursor location to parse the messages. He should be able to parse the messages more correctly now. The current fix might also help him parse long messages on a wider screen. The reason the borg freaked out on larger screens was due to problems in parsing the messages. In order to catch odd parse behavior, borg_verbose needs to be set as TRUE in your borg.txt file. 4) Certain useful spells (sleep, slow) would pass over a monster if it were already slow relative to it's base race speed. But monsters are allowed to have some variable speed, so some monsters would be passed over because their speed was 119 instead of 120. 5) It was possible for the borg to get stuck at 1 borg_no_rest point and then never rest to recoop mana.
August 26, 2008, 1) The damage from Chaos Strike was not being calculated correctly. I personally don't really like this spell much. It has a tendency to polymorph the monster. After the monster is polymorphed, he has his hitpoints reset. 2) Rework of the calcuations for Teleport Other. He was shooting it into walls and using it on some uniques when it was not really appropriate. He also needed to use T.O. if he was getting low on mana. 3) Backing up as a strategic retreat needs to have a better reward value. He was backing up from a danger of 458 to a grid of 450. Hardly seems worth the effort. Just stand and fight. 4) There was a rule conflict involving carrying !Life and returning to town to store them in the home. He ought to save those instead of carrying them around.
August 25, 2008, 1) The borg_desperate flag can be used to flee a level using down stairs now. Previously, he could only use to on up stairs. 2) Borgs would only consider using Teleport Away if there was signficant danger, like 70% of his hitpoints. That was reduced to 50%. We are seeing lots of borgs die from "out of the frying pan, into the fire." 3) Borg will use Banishment more liberally, especially when deep in the dungeon.
August 22, 2008, 1) The borg was incompletely calculating the danger of certain grids if a monster could move and use a ranged attack in the same round. This would be manifested as a borg retreating to a grid of danger 0, only to be chased by a faster monster who was able to threaten the borg's new grid following the monster's action 2) It was possible for the borg to purchase a replacement torch for his lantern if the lantern ran out of fuel. 3) Corrected a really old gobal variable code issue related to borg_full_damage. It is now properly a parameter to borg_danger(). 4) Low level mages will attempt to conserve mana in town by not casting MM on certain town monsters (the ones which do not have an attack or no reward.) Hopefully he will save his mana for the SER, MLM, and BSV. 5) Borgs will try not flow through monsters to a destination. This will help him avoid bouncing on grids near never_move monsters.
August 21, 2008, Implemented changes recommended on the Forum. 1) Genociding Nasties will begin earlier (depth 25 instead of depth 50). Loosened the restrictions slightly. 2) Added new borg command 'C' which will log the current Nasty Count. Nasties are monsters that the borg would rather not fight. He genocides them if they get too numerous on a level. By default, the nasties are monsters with the following tokens: ZAVULWD. The borg keeps count of these monsters and when they reach a certain number on the depth, he will use Genocide to thin them out. Counts are 20, 20, and 10 for the others. I dont think the count is configured in Borg.txt but it could easily be made to do so. By default, at the beginning of every level, he automatically assumes there are 25 hounds, and will Genocide Z as soon as he can. As mentioned above, he did not do this until depth 50 but will now start earlier. The borg has been genociding hounds at the beginning of each level for years (he began doing it November 2002). 3) Borgs suffereing from Confusion were allowed to strategically retreat under certain conditions. This will be disallowed since a confused borg can not actually walk to his destination. 4) there was a problem with the borgs learning spells in their last spellbook. Not sure how that crept in, but not having access to Keleks is a big deal.
August 20, 2008, 1) Improvements to light handles. The borg incorrectly thought that Lanterns of Brightness caused him to glow (being a permanent light source) 2) For years, the borg has been able navigate the dungeon if he runs out of light. He has been able to cast Call Light if he found himself on a glowing grid, which would help him illuminate the halls, every few steps, as he moved through them. Of course, he could not cast the Call Light spell unless he were on a glowing grid. I just added a feature which will allow him to use his remaining few turns of light to Call Light so he had a glowing grid to start on. The major drag with this Light-as-you-go technique is that it uses a lot of food due to all the resting to regain mana. So he will only do it if he has food to spare. Running out of light is still a very dangerous position for the borg. He might survive the ascent while dark, but its really risky.
August 19, 2008, 1) The borg will be a bit more flexible in following out-of-sight monsters which are moving and will try to avoid creating a new monster index for the same monster. 2) Borg will attempt to rest on a single grid to avoid the situation wherein the borg is two grids away from a monster and when the borg moves 1 grid to close the distance, the monster gets a free hit on the borg. This is a bit tricky to do correctly; several things are involved including the borg-monster speed differential.
August 18, 2008, 1) Repairs to the borg targetting PASS_WALL monsters who sit in a wall. 2) The spell Detect Invis is no longer a timed event. The borg needed to be told so. Was this game change listed in any change log? This type of spell change is important for the borg and I am surprised I didn't catch it in a log. 3) Improvements to how the borg uses wands: he will be more careful about wasting charges and hold onto certain wands (MM, Stinking Cloud). 4) Low level borgs tend to waste a lot of ?WoR while on depth 1 avoiding Scaryguys. The borg will be allowed to use the borg_desperate functions to find stairs.
August 11, 2008, 1) The distribution files did not seem to work on computers that did not have M$ Visual Studio 2008 installed. There is a well known issue with VS2008, producing executable files requiring a special non-default dll to be installed on the target machine. I have modified the solution to link directly to the needed parts of the dll. 2) Borg will cast the Detection type spells a bit less frequently. This will help the low level guys save some mana and keep him from the rest-regain mana-cast spell-rest again-loop. 3) borg wills reset their flow and movement goals after strategically backing away from a monster. This will force him to reevaluate the danger and value of the grids. 4) The borg will be less likely to rest to mana recoop right after casting certain prepatory/defence spells.
August 8, 2008, 1) The problem with the borg not buying torches to refuel his Torch is Brightness is solved.
August
7, 2008, 1) Some changes to the game code when upgrading from
A to B modified the store purchasing keys. These
changes are
now addressed in this borg. So that basically means that this
release will not work on 309a due to the shopping changes. If
you
really want to, you can get this source code to work by editing borg1.c
at line 454. It is commented for you. If you
attempt to use
any prior borg on 309b, there will be some serious problems with
purchasing wares from the store and shops. 2) The borg is
having
some goofy issues relating to buying torches and running out of light.
This is a new weirdness. I have only seen him do it
with
Torches of Brightness. I strongly suspect he is not buying
normal
torches to refuel the Brightness torch due to a problem with him
thinking the new torch will replace the Brightness one, giving him less
power. I will track it down and fix it in the next days.
August 6, 2008, 1) Updated a potential crash related to the borg being very near the edge of the dungeon border and having a large light radius. 2) Corrected how the borg was calculating light radius from artifacts. This did cause bad behavior related to using Light Beam to illuminate hallways for locating unseen monsters. 3) Improved how the borg will illuminate hallways looking for unseen monsters. Unseen monsters are those who hide in the dark and use ranged attacks. The borg is aware of these attacks and attempts to light up the hallways to reveal the monster in order to ID it and calculate an attack strategy.
August 5, 2008, Updated the webpage. Updated the Zborg. It had been about 4 years since I looked at that code. I got it up and running under VS2008. Fixed a crash error.
March 1, 2008, 1) The borg could miscalculate the benefit of using Teleport Other if he were fighting only a single guy.
February 27, 2008, 1) Updated the 309 borg. If the option to remember torch-lit grids was on, then the borg believed that those grids were glowing grids and would get stuck if he ran out of torch/lantern light. This lead to a few starvation deaths. It's now corrected, that option can be set either way.
February 20, 2008, Major fixes today. 1) When the borg was respawning (rerolling a character after one dies) the startup equipment included torches with 0 turns. Prior to 309, the Pval of the torch determined the turns of light remaining. In 309, it is the Timeout. This is now corrected. 2) Significantly improved how the borg calculates damage to and fear of compromised (sleeping, confused, slow) monsters. This will allow him to use the wands of slow/sleep, etc. Previously, he would very rarely use those things eventhough he knew how. 3) Removed some old 3.0.5 references to clean the code. 4) Improved how the borg will use the defence and perma maneuvers for Bless. This made a huge improvement for his mana in the very early game. 5) Improved how very low level borgs will explore the dungeon and stay close to the stairs. Previously, he would return to town after a short exploration of the dungeon (usually just one hallway). The problem is the town is a very dangerous place with no exp reward for that risk exposure. He will now return to town less frequently and explore the dungeon a little more efficiently while still staying close to the stairs. Staying next to the stairs is a good idea so he can make a prompt escape from Grip/Fang/Jackals, etc. Basically he will explore more than just one hall. 6) The borg will now clear his flow codes when a monster changes his sleep state. This will allow him to abort his flee attempts and attack a monster which has just been put to sleep.
February 19th, 2008, 1) Because the General Store no longer buys torches or cloaks, the borg is filling his inventory with them. The torches are useful, but the way he was sorting them, he prefered higher pvalue torches (3000 turns) over used ones (~500 turns) and would refuel his torch with the higher pval ones. I corrected how he sorts for them and will now prefere the shorter stacks over higher pval. This will keep him from filling up his inventory with a bunch of used torches. 2) I will sell cloaks to the Black Market for the same reason as above. 3) added a borg_verbose flag to borg.txt which will cut back on how many reports are sent to the log. (Cuts back on all the parsing messages making the log much easier for noobs to read.)
February 17th, 2008, 1) Slight tweak on strategic Backing Up, which will allow the borg to step back into a hall or other safe place to avoid being surrounded and such. The restrictions were loosened so the borg will be more likely to do this.
February 16th 2008, 1) Bless is more likely to be cast for low level guys. 2) If fleeing the level from a scaryguy and a monster is adjacent, he will attempt to attack that guy. He keeps dying to bats and really easy guys. 3) Some improvements to the critical Phase Door attempts. Borgs with several ?PD would rather fight in a suicide fight rather than even attempt the phase.
February 9th, 2008, 1) Slight correction to how the borg store the array of runes of protection. 2) the borg will no longer cast Rune of Protection (Glyph) in anti-summon corridors. He was using too much mana doing this. 3) Another slight fix to the 309 borg.
December 14, 2007, 1) Had to repair the 309 borg. It is still not perfect but it does run. There was an issue with Torches of Brightness and the borg thinking that he was glowing.
October 26, 2007 1) I have been working daily on the 3.0.9 version borg. There have been quite a few issues to address. The borg is running and is mostly stable. I find little bugs every few days. Today, I found that the message for failed glyph creation changed. So I had to make that correction. Little things like that pop up. It is stable enough to send out for beta work. I find some unhooks after shopping. You can find a copy of the borg source code and the necessary game code changes here. I am pretty sure I included all the game files that were altered. If the borg won't compile, drop me a line so I can fix that zip file. 2) I added some better handling for *Heal* and Life potions. He will be more careful about storing potions in the home rather than carrying them around and running the risk of getting them shattered by cold attacks. 3) Correction to how the borg deals with a glyph creation in an anti-summoning corridor. 4) Some work on getting the borg to run under a big screen (wider than 80 columns).
Sept 28, 2007, 1) Corrected a bug which could cause the game to crash while fighting Morgoth. 2) The mage spell of Rift needed to be defined as a beam, had been a bolt. 3) Shooting into grids that contained the borg_invis feature need some corrections for pass_wall ghosts. 4) Placing a possible wall under a pass_wall ghost if the borg shoots and misses a pain response. 5) Leave_level() has some changes to make him want to stay on level 100 longer. 6) Minor repair to how the borg will rest if he is in a sea of runes waiting for Morgoth. 7) The borg's self-defined money scumming limit is now 85k. I have a machine with him scumming to get $334,000. He has been there for 2 weeks already. 8) Rewrite to the banish nasties defence routine in borg6.c. This routine will count the number of certain monsters and bast Banishment on them if they get too numerous on a level. I modified it to make it much easier to expand the list and modify its usage. 9) Mass Banishment scrolls are collected and stored in the home better. 10) Interestingly, the borg was doing some interesting behavior. He would stay on depth 99, collecting *Heal* potions, as expected, and storing some in his home. As soon as his *Heal* potion goal is met (adding the personal supply and home supply), he would dive to 100. The problem is, he would dive right then, instead of returning to his home and gathering up all his stored items. He will now return home first, to gather his gear before driving. There were a few changes to the borg.txt, so its a good idea to replace yours (or set the Dynamic Calcs off).
Sept 21, 2007, 1) There had been a very elusive bug were the borg at depth 99 would literally get naked in the dungeon, taking off all his stuff and throwing it on the ground. He would usually pick it back up again, but not always. He would sometimes trade out his nice gear (like Ringil) for an {excellent} weapon. I have seen the borg after this event but never caught him in the act. I received a savefile with this behavior in full swing. With the help of the savefile, I think I was able to identify and correct the error.
Sept 20, 2007, 1) Repaired a potential bug in how the borg tracks the glyphs. It was causing crashes in some battles with Morgoth. 2) Major improvement in anti equipment loops. There had been a persistant 3-way armor bug with Belegonnon, Thalkettoth, and Isildur. I now have the borg tracking the artifacts he wears and will forbid him from rewearing an artifact which had recently been removed. This will not effect the swapping of armor or weapons from the Swap routine which is designed to help him wear a backup item. You will still see him swap a tiny bit with respect to the Best Combo routine.
Sept 19, 2007, 1) Repaired a swapping loop at the house. This one involved swapping staves. He still loops a little but not nearly as much. I fear this change may adversely impact his food purchase ability. Keep an eye out for an increase in starvations. This repair will significantly improve his turn count. He would previously flee town in a swap loop. That flee would take him to depth 1 for a while then return to town and swap again. This will help reduce the time on depth 1. 2) Made a major bug fix on the money scumming for the botg. He kept buying stuff instead of saving all his money for the scum item. This should help reduce the number of rounds he spends scumming.
April 9, 2007, 1) Borg will no longer attempt those emergency teleport spells if clevel >10. 2) Borg will have an extra check on using the EZ_Heal potions. 3) There is still one more 3-way armor swap that needs to be fixed. I have a save file demonstrating the bug. I will work on it over the next week. 4) A few winners were submitted.
April 8, 2007, 1) More improvements to the borg resting to recover his mana points. 2) Another repair to equipment swaps. The most likely 3-way armor swaps include Rohirrim. 3) Improvement to the use of Sanctuary spell. 4) Improvement to use of missile/ball attacks to Pass Wall monsters while they are in a wall (Dreads, etc) 5) Offset attacks that only do 1 damage are less likely. 6) Some monsters have immunities which, in the game, reduce the damage by 90%. The borg would previously make this exact calculation which often permitted the borg to use an expensive spell and only do 10% damage. The damage is now reduced to zero which should save him some mana. This was often seen as the borg using offset attacks (usually poison ball) on a never_move monster. While the borg rested to regain his mana, the monster would typically heal up. If any of this behavior is seen following this update, send me the savefile while the borg is doing it.
Feb 23, 2007. 1) Borg will be slightly more likely to
rest to
recover his HP/SP. 2) Borg will reset his recall depth a
little
more often especially if he is slightly out of depth (maximal
depth is about 5 deeper than what he is prepared to
handle). 3)
Borg will be slightly more likely to quaff his !Speed if fighting
certain annoying uniques (Wormtongue, Orc Uniques, Bullroarer)
Feb 11, 2007, 1) Repaired some of the Staff Buy-Sell loops. These were introduced when staves stacked. 2) Money Scumming seemed to double up some times. Meaning, after he scummed for the 20k to get the stat potion, he would purchase the potion then continue to scum another 20k. This is now repaired.
October 7, 2006, 1) Borg was having problems counting charges in his staff stacks.
July 15, 2006, 1) Sometimes the borg would cast Create Door in town which could leave him trapped in the ring of doors and he did not understand how to open them. That is now repaired.
July 11, 2006, 1) Found and corrected one source of shop-loops. If the borg was in rough shape upon returning from the dungeon, he might decide to buy something and sell something in the same turn.
July 8, 2006, 1) Some fine tuning to the sea of runes technique. 2) Do not use Teleport Level Defence maneuver if Morgoth is on the level. 3) Log the reason why the borg is looking for up-stairs. 4) I used a savefile of a mage at depth 100 to kill Morgoth about 10 times. There were only a few instances were he was getting whipped. I will try to resolve those this month.
July 6, 2006, 1) Some borgs (Paladins and Priests with < 650 HP
and valid Heal spells) were trying to Questor Combat Heal while in
town. 2) Borg Perma skills need not be cast in shallow depths, nor
should the high level borgs need to Lunal (stair) scum while shallow.
3) Borg.txt is updated to set the borg_self_lunal = FALSE. Self_lunal
mode was actually taking more turns to dive than looking for the stairs.
June 28, 2006, 1) I think I fixed that crash issue with low level borgs in the dungeon.
April 24, 2006, 1) It was possible for the borg to unhook on level 100 if he ran out of mana while making a sea of runes. 2) The borg needed to not do his Restock() checks while in town.
February 17, 2006, 1) Seasoned borgs (clevel 10) were dying on level 1 while trying to escape a 'scary guy level.' They would choose to not fight on the race to the stairs, and take hits from faster monsters. So now, if the borg is clevel >= depth*4, he will stand and fight. 2) Borg needed to be more open to the idea of using the using the Destruction staves.
February 12, 2006, 1) Borg needed a backup method to see if he was standing on stairs, so that he could use them to escape better. There were some cases of 'flowing to stairs 0' which means stair was under him, but he was not able to use. 2) 'Desperate for Stairs 3' allowed a low level borg in danger to continue moving to stairs instead of turning to fight. The borg was being too risky and dying. 3) Slight tweak on danger-escape thresholds to make the borg a bit more timid.