home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!zephyr.ens.tek.com!master!saab!billr
- From: billr@saab.CNA.TEK.COM (Bill Randle)
- Newsgroups: comp.sources.games
- Subject: v14i035: umoria4 - single player dungeon simulation (ver. 5.5), Part03/39
- Message-ID: <3393@master.CNA.TEK.COM>
- Date: 20 Aug 92 18:02:22 GMT
- Sender: news@master.CNA.TEK.COM
- Lines: 1108
- Approved: billr@saab.CNA.TEK.COM
-
- Submitted-by: grabiner@math.harvard.edu (David Grabiner)
- Posting-number: Volume 14, Issue 35
- Archive-name: umoria4/Part03
- Supersedes: umoria3: Volume 9, Issue 55-97; Volume 10, Issue 15-17
- Environment: Curses, Unix, Mac, MS-DOS, Atari-ST, Amiga, VMS
-
-
-
- #! /bin/sh
- # This is a shell archive. Remove anything before this line, then unpack
- # it by saving it into a file and typing "sh file". To overwrite existing
- # files, type "sh file -c". You can also feed this as standard input via
- # unshar, or by typing "sh <file", e.g.. If this archive is complete, you
- # will see the following message at the end:
- # "End of archive 3 (of 39)."
- # Contents: OChanges source/misc4.c
- # Wrapped by billr@saab on Thu Aug 20 09:11:26 1992
- PATH=/bin:/usr/bin:/usr/ucb ; export PATH
- if test -f 'OChanges' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'OChanges'\"
- else
- echo shar: Extracting \"'OChanges'\" \(51602 characters\)
- sed "s/^X//" >'OChanges' <<'END_OF_FILE'
- X::::::: 1990 ::::::::
- X------------ 1/1
- Xcreatures.c: in mon_cast_spell(), must update_mon() to light monsters before
- X they cast a spell
- X------------- 1/2
- Xmoria1.c: inven_command(), could not wear item which replaced equip item if
- X inven full, only fail if inven_check_num fails for torches
- Xmisc2.c: change spacing for stats on change_character page, was printing in
- X last column for max stat
- Xmoria2.c: tunnel(), if no shovel/pick, divide total tabil chance by two
- Xmonsters.c: change eye-sight and sleep values for consistency, as noted by
- X djgrabin
- Xhelp.c: change the monster recall so that it lists high level monsters first
- Xcreature.c: when monster bashes down a door, call disturb() to halt resting
- Xio.c: fix msg_print() so that -more- is always printed on screen, fix
- X put_buffer() so that does not fail if col argument greater than 79/80
- Xmisc1.c: change chance for ego weapons/missiles to 3*special/2 instead of
- X just special, needed because treasure distribution change has made
- X ego weapons not as common as before
- X--------- 1/11
- Xmonsters.c: let nether wraith phase, set Black/Red/Multi ancient dragons
- X to a sleep value of 700
- Xcreature.c: increase r_attacks if either notice true or r_attacks is
- X nonzero (i.e. it has been noticed before)
- Xmoria2.c: move_char(), when step back after setting off a falling rock trap,
- X check to see if have stepped back onto another trap
- Xmoria1.c: inven_command(), when restart it after taking off an item, don't
- X print the 'have to drop something' message because that is confusing
- Xmisc2.c: modify_stat(), could overflow 118 when increasing stats, add extra
- X case to enforce max of 118
- X--------- 1/12
- Xall: apply william setzer's objdes() diffs, 500K patch file, change version
- X number to 5.0.10 and distribute
- Xdesc.c, misc2.c, store1.c: remove several obsolete uses of index(),
- X insert_num() no longer used anywhere
- Xconstant.h, desc.c: change ID_TRIED,ID_KNOWN1 to OD_TRIED,OD_KNOWN1
- Xdesc.c: eliminate titles[], rename title_space[] to titles[]
- Xall: fixed lint errors
- Xall: make sure that all objdes() strings are bigvtype
- Xdesc.c: fix printing of bows/arrows/picks, needed new p1_use define, and
- X rearrange code in objdes() switch statement
- Xtreasur1.c, treasur2.c: remove -100 tohit from books, was being printed, and
- X is silly anyways
- Xconstant.h, externs.h, save.c, treasur2.c: change object_ident[] from
- X MAX_OBJECTS to OBJECT_IDENT_SIZE = 7*64, see object_offset() in desc.c
- X to see why this is necessary
- X---------- 1/13
- Xexterns.h, misc2.c, store1.c: deleted obsolete references to treasure_type
- Xdesc.c: always print toac field if known2 and non-negative
- Xconfig.h, io.c, misc1.c: eliminated BUGGY_CURSES define, caused too much
- X trouble, just assume that can never print in last column of screen
- Xconstant.h, desc.c, misc1.c, moria2.c, spells.c, treasur1.c, types.h:
- X created special_names table to hold all possible name2 strings,
- X name2 changed to an int8u which holds index to special_names table
- Xexterns.h, main.c, treasure1.c: sort_objects() function deleted, sorting now
- X done by init_t_level using O(n) bin sort, into sorted_objects[] array
- Xfiles.c, misc2.c: object_list[] references that assumed it was sorted now
- X indirect through sorted_objects[] array
- Xmain.c, variable.c: player_init indexes now point into object_list instead
- X of inventory_init
- X------- 1/14
- Xconstant.h, externs.h, main.c, store1.c, treasur1.c, treasur2.c, variable.c:
- X deleted inventory_init array, stores objects now in object_list,
- X MAX_OBJECT adjusted, MAX_DUNGEON_OBJ defined, store_choice[] fixed
- Xall: put all objects in object_list, trap_list, door_list, store_door,
- X gold_list, up_stair, down_stair, rubble, much, blank_treasure,
- X scare_monster are not separate variables anymore
- Xall: invcopy now takes an object_list index as second parameter, name field
- X deleted from inven_type and fields rearranged
- X----------- 1/15
- Xstore1.c: search_list() deleted, use i_ptr->index instead to get raw item cost
- Xsave.c: obsolete treasure_type references deleted, save files work again
- Xcreature.c, magic.c, misc2.c, prayer.c, save.c, wands.c: fixed long/short
- X problems with shift, mostly change (1 << i) to (1L << i)
- Xall: add new register declaration, check indentation, fix 32/16bit int
- X problems
- Xconstant.h: change version number to 5.0.11
- X------------- 1/17
- Xspells.c: aggravate was not initiallized in aggravate_monster()
- Xmonsters.c: novice rogue now evil like other rogues
- Xmisc2.c: 2 "... learn ... new spells ..." messages changed to print prayers
- X instead for priests
- Xmoria2.c: drop_throw(), "The %s hits %s" changed to "The %s hits the %s."
- Xmany: fixed problems with setting of free_turn_flag
- X----------- 1/19
- Xmisc2.c: fix inven_carry(), to stack store/dungeon items properly
- Xdesc.c: objdes(), set p1_use = IGNORED for food and potions, changed
- X is_a_vowel(tmp_val[1]) to [2]
- Xmoria2.c: "exceed weight limit?" message now prints item name also
- Xdesc.c, spells.c, staffs.c, wands.c: empty wands are not incribed empty if
- X known2, empty removed when wands are recharged
- Xdesc.c: put spaces between inscribed words
- Xdungeon.c: always inscribe majik when character notices this, not just for
- X inventory items as that helps priests more than fighters
- Xstore1.c: sell_price(), succeed only if both item->cost and item_value() are
- X positive
- Xcreature.c: don't increase a number of attacks when monster repelled in
- X make_attack(), i.e. no damage done so shouldn't learn about damage
- Xmoria1.c: regenhp and regenmana, could get chp/cmana equal to max and _frac
- X non-zero, change c > max test to c >= max test
- Xconstant.h, dungeon.c, misc2.c: hp and mana were printed while in store/inv,
- X fix calc_hitpoints() and calc_mana() to set flags instead of printing,
- X in dungeon.c, checks flags and print values
- X---------- 1/20
- Xstore2.c: redisplay store prices if charisma changes during the inven_command
- X calls (actually just redraw everything)
- Xmoria2.c: monster_death(), dump must be set to 0 is number is 0
- Xconstant.h, moria2.c, recall.c, spells.c: recall printing of treasure changed,
- X instead of setting CM_ bits, store largest number of treasure ever
- X generated in those 5 CM_TREASURE bits, changed monster_death() to set
- X the bits the new way, changed uses of monster_death() to replace old
- X treasure bits with new ones, the vague print out treasure amounts
- X replace with printout of precise number of treasures generated
- Xexterns.h, moria2.c: monster_death() changed to int32 monster_death()
- Xmoria1.c: new_spot() contained line of code "i = randint(10)" that did not
- X belong there, was formerly testing code
- Xdesc.c: objdes(), force zero charges to always print, also, always print
- X digging plusses even if zero
- Xmain.c: items that initialize players inventory are marked store_bought(),
- X this is needed so that dagger/armor bonuses will be shown for them
- Xdesc.c: objdes(), fixed printing of doors, known1() clear the tried flag,
- X magic_init() don't let scroll names end with a blank
- Xmisc2.c: gain_spells(), call calc_mana() if py.misc.mana == 0, this is
- X for characters who did not know any spells before the 'G' command,
- X can't gain spells if blind/no light/confused
- Xmoria1.c: infinite loop entered with 'id' and screen_change, also, 'n' to
- X the continuing with inventory prompt did not work, must clear
- X doing_inven before returning from inven_command() in these cases
- Xdesc.c: identify(), don't merge items in equip list, only merge items that
- X are single stackable
- Xmisc2.c: inven_carry(), inven_check_num(), fix item stacking, items can only
- X stack if they are both identified or both unknown (store items are
- X always identified)
- Xconstant.h: change version number to 5.0.12 and distribute
- X------------ 1/21
- Xdesc.c: objdes() bug, change p1_use = IGNORED to p1_use == IGNORED
- Xmoria2.c: move_char(), moving into a wall is no longer a free turn
- Xmisc2.c: gain_spells(), priests no longer need book before can learn spells
- X from it, mages still need the books, calc_spells() delete unused
- X var spells[], remove limit of 23 from number of new spells
- Xdungeon.c: made scribe_object() a free turn again
- Xrecall.c: only print monster speed if at least one movement flag known
- Xunix.c: missing */ after Gakk!! -CJS-.
- Xdesc.c: stacking did not work right, fixed known1_p() to return OD_KNOWN1
- X instead of TRUE for store items, so that known1_p() == known1_p()
- X will work consistently
- Xmonsters.c: creeping coins hit instead of bite, and touch instead of breath
- Xvariable.c: fixed problems with temple/alchemist store inventories
- Xdesc.c, store1.c: fixed food prices, only check unknown if subval puts it
- X among the molds/mushrooms
- X------------- 1/24
- Xmisc2.c, types.h: change inscrip back to char *, fix inscribe() to malloc
- X space for string, and then copy inscription into the malloced space,
- Xsave.c: fixed (compatibly) to write/read new inscriptions
- Xdesc.c: free malloced inscription space in invcopy
- Xdeath.c, misc1.c: delete max tcptr code
- Xconstant.h, desc.c, misc1.c: define new const ID_SHOW_TOHIT, in magic_treasure
- X set this bit for every weapon,digging tool,missile,bow, in objdes()
- X print out tohit/todam if this bit set and object identified, this
- X makes it easy to tell ident weapons from unident weapons
- Xmain.c: char_inven_init() must set ID_SHOW_TOHIT flag for initial weapon
- Xdeath.c, constant.h, misc1.c: change MAX_TALLOC from 225 to 150,
- X delete temporary code which printed out max tcptr values
- Xmisc2.c: allow inscriptions of up to 24 characters
- Xconstant.h: change version number to 5.0.13 and distribute
- X-------------- 1/26
- Xwizard.c: wizard_create(), initialize the name2 and inscrip fields to 0,
- X init the ident field to known2 and storebought
- Xconstant.h: changed MAX_TITLES from 60 to 45
- Xdesc.c: magic_init(), wrote to a char *tmp; modified to write to a vtype
- X string
- Xrecall.c: change printing of treasure again, only print 'sometimes' is 60% is
- X only bit set, otherwise always print 'often' if only one object, for
- X two objects, print 'often' only if 60% and 90% are only bits set
- Xscrolls.c: recharge scrolls not used up when read, fixed setting of used_up
- Xspells.c: res = TRUE; moved out of if-stmt so only needed once
- Xtreasure.c: change wiz obj name from "& wizard object" to "{wizard object}"
- X---------- 1/29
- Xmoria2.c: tunnel(), give player attack on creature if it is in the way
- Xmisc2.c: gain_spell(), remove limit of 22 on learning spells, fix print_spells
- X so that it will only show the first 22 spells
- Xconstant.h, desc.c, misc1.c: change ID_SHOW_TOHIT to ID_SHOW_HITDAM, set this
- X bit for gauntlet/rings of slaying, and irritation/enveloping cloaks,
- X fix objdes() so that it only prints both tohit/todam if this bit is set
- X otherwise, only prints one number, if either of tohit/todam nonzero
- Xdesc.c, treasure.c: remove "the entrance to the " from store doors and put
- X in objdes() in desc.c
- Xmisc2.c: put_misc2(), add "Exp to Adv." to character display
- Xconstant.h, desc.c, misc1.c: added defines for ID_NOSHOW_P1 and ID_SHOW_P1
- X to improve printing of object names, objdes() always prints p1 if
- X ID_SHOW_P1 set, and never prints it if NOSHOW set, these override
- X the default p1_use setting, NOSHOW added to sustain stat rings,
- X SHOW added to clumsy/weak gloves, boots of speed/stealth/slowness,
- X helms of int/wis/infra/might/lordliness/magi/beauty/seeing/
- X stupid/dull/weak/ugly, cloaks of stealth
- Xcreature.c: increase effect of aggravate_monster attack from range of 5 to 20
- Xspells.c: dispel_creature(), prt_exp() was only called when visible creatures
- X died, now always called when creature dies
- Xmisc1.c: added messages to compact_objects() and compact_monsters() so that
- X can tell if they are ever called
- Xstore1.c: rings/amulets which are not known2 now have base value from object
- X list instead of real value
- Xmoria2.c, staffs.c, wands.c: cast level to int, so that calculations will be
- X done with signed arithmetic, in openobject() change chance of opening
- X a chest, instead of -2*level use -level, this help eliminate chests
- X which are impossible to open
- X--------- 1/30
- Xrecall.c: print ' at normal speed' for monsters with mspeed = 1
- X--------- 2/10
- Xspells.c: turn_undead, speed_monsters, sleep_monsters2, and dispel_creature
- X modified so that they only affect creatures in los of player
- Xexterns.h, misc2.c, variable.c: new array spell_order[], holds order in which
- X spells are learned, in calc_spell() spells are now remembered in
- X the order that they were learned, and forgotten in the reverse order
- X learned, in gain_spell() must modify spell_order when spell learned
- Xmain.c: spell_order initialized in inven_char_init to all 99s
- Xsave.c: save/restore spell_order, for patch_level <= 13 savefiles create
- X a reasonable spell_order on the fly
- Xmisc2.c: was erasing wrong line in gain_spells, change `j+2' to `j+1'
- Xall: change file names to be 8.3 characters long
- Xconstant.h: change version number to 5.0.14 and release
- X---------- 2/10
- Xdungeon.c: change rogue-like wiz help key from ^? to \
- Xall: merged in Mac sources, all initialized variables are now in variable.c,
- X rearranged directory structure
- X---------- 2/11
- Xall: merged in VMS sources
- Xchanged to 5.0.15 and distribute
- X--------- 2/13
- Xmoria2.c: carry(), printed 'worth of emeralds..' removed '.' from string
- Xdesc.c: crowns did not print out AC because it is zero, add special case
- X to objdes() so that tval == 33 (crowns) always have AC printed out,
- X change (+5 charges) to (5 charges)
- X----------- 2/14
- Xmoria2.c: inven_throw() created second copy of pointer to malloced
- X inscription, it now creates new inscription for new object
- Xmoria1.c: inven_command(), wear option copied malloced inscription,
- X create new inscription for new object
- Xmisc2.c: inven_destroy(), free inscription of just deleted object,
- X clear inscrip pointer of last objects previous location, so that
- X it will not be freed, inven_drop(), create new inscription for
- X new item, inven_carry() create new inscription for new item,
- X scribe_object() free space for old insription since it is deleted
- Xconfig.h, externs.h, misc2.c, moria1.c: rename remove() to takeoff() to
- X avoid naming conflict with library routines
- Xexterns.h, misc2.c, store1.c: deleted join_names(), no longer doing anything
- X useful, and was wrongly creating duplicate pointers to malloc blocks
- Xmoria2.c: make moving into walls a free turn again, but player can not attack
- X invisible creatures in walls by moving into wall (hence preventing
- X him from using 6 free turns to search for invis creature), must
- X tunnel into wall instead, which always takes a turn
- Xdungeon.c, externs.h, moria2.c: pass direction to tunnel() instead of point
- X digging to, eliminates a lot of duplicate code, tunnel() now checks
- X confusion, and tries to tunnel in random direction if confused
- Xtreasure.c: clone monster wands changed from level 2 to level 15, makes them
- X recharge less, max 6 new charges instead of max 18 new charges
- Xfiles/version.hlp: add Dan Bernstein's name to credits
- Xmagic.c, variable.c, wands.c: change stinking cloud from 16 to 12 damage as
- X it was too close to lightning bolt at 18, reduce mana for mage/ranger
- X from 4/6 to 3/5
- Xmoria1.c: show_inven() and show_equip(), don't print first two spaces when
- X col is zero, since will blank the whole screen anyways
- Xmoria2.c: py_attack(), only cleared confuse_monster flag if monster survived
- X attack, now always clear this flag and try to confuse monster
- X-------------- 2/16
- Xall: add in diffs to get MSDOS version working again, add files from binary
- X PC-Moria distribution
- Xtypes.h: for PC, use 'unsigned char var : 1' to reduce sizeof cave_type
- X from 5 to 4
- Xdesc.c, misc1.c, misc2.c, moria1.c, moria2.c, save.c, wizard.c, types.h:
- X change inven_type inscrip field from pointer to an 13 char array,
- X mallocing storage for inscriptions does not work, results in
- X dangling pointers when inven_types are copied
- Xsave.c: add 'time' to savefiles, use this to calculate age of savefile
- X instead of using stat, much more portable, and prevents cheating,
- X if time is newer than current time, set age to 0, when save file
- X check to see if current time greater than start time, if not,
- X then save start time plus one day in save file
- Xmac.c: delete getfileage since no longer used
- Xrecall.c: change knowdamage(), add damage parameter so that higher damage
- X attacks take longer to learn than lower damage attacks
- Xmonsters.c: jellies and molds no longer have treasure
- Xsave.c: two places have (*str != NULL), changed to (*str != '\0')
- Xsave.c: remove support for pre 5.0.13 versions, rd_item() no longer needs
- X patch_level
- Xmonsters.c: move crystal ooze from level 31 to level 40, to make raising
- X crystal oozes for treasure much more dangerous
- X--------------- 2/19
- Xall: added defines for tvals, and substituted every where in program
- X---------- 2/21
- Xms_misc.c, io.c: remove all uses of mvprintw() for ibmpc port, since PC
- X curses also pulls in the fp library if mvprintw is used
- Xdungeon.c: in the recover from blindness code, the disturb() call must
- X be before the creatures(FALSE) call
- Xgetch.c, io.c, Makefile: more fixes for the VMS port of umoria, new getch.c
- X file, and new copy of (4.87) io.c file
- X---------- 2/22
- Xall: check again for numbers that should be constants
- Xconstant.h: change version number to 5.0.17
- Xexterns.h, main.c, moria2.c, signals.c, treasure.c: compile with gcc -Wall
- X and fix all reported errors
- X--------- 2/26
- Xprayer.c: change (!class[].spell == PRIEST) to (class[].spell != PRIEST)
- Xstore2.c: for good bargaining, use final_ask not min_buy in sell_haggle()
- Xdungeon.c: change "Sorry.." to "Sorry."
- Xmisc1.c: for gloves/gauntlets, p1 and ID_SHOW_P1 set in wrong place
- Xcreature.c: make_attack(), creature could be visible at start of attack but
- X invisible at end due to a teleport, set notice/visible appropriately
- X before monster attacks, and don't use m_ptr->ml afterwards
- Xmonsters.c: creeping coins always carry gold now, 1d2 for copper, 1d2+60
- X for silver, and 1d2+90 for gold
- Xtreasure.c, wizard.c: change name of wizard items to empty string, and
- X inscribe them with "wizard item"
- Xdesc.c: problem with rubble/stone-to-mud, change rubble case from like stairs
- X to be like doors
- Xmoria1.c: show_equip(), change non-weight limit from 57 to 60, change weight
- X limit from 49 to 52 chars, for show_inven(), change limits from
- X 66/74 to 68/76 characters
- Xcreature.c, magic.c, prayer.c, spells.c, wands.c: fix get_flags(),
- X fire_ball(), fire_bolt() and breath() to use defined constants for
- X attack types
- Xmoria1.c: show_inven(), show_equip(), make sure that col never less than zero
- Xall: merged in Atari ST diffs from Stephen A. Jacobs
- X--------------- 2/27
- Xcreature.c: fixed bug with doors, always open/light door instead of only
- X opening/lighting them when in los of player
- Xmoria2.c: when bash open door, only break it 50% of the time to be consistent
- X with code in creature.c
- Xall: delete some obsolete files, annotate a few others, put README files
- X in the subdirectories to explain what is present
- Xsave.c: fix old savefile compatibility code to work with new version numbers
- Xconstants.h: change version number to 5.1.0 and publicly announce
- X---------- 2/28
- Xrecall.c: creature is worth... sprintf() call used %ld instead of %d
- Xmoria2.c: look_ray(), every place GRADF multiplied by y, cast it to long
- X to prevent overflow of 16 bit ints
- Xms_misc.c: were still two refs to 'byteint', changed to 'int8u'
- XMLINK.LNK: updated for umoria5.0, add undef and recall, change treasur[12]
- X to treasure
- Xcreate.c: delete sleep(1) call in character rerolling code
- Xdeath.c: put "#ifndef L_SET" around the #define L_SET
- Xio.c: ifdef out suspend code, for USG systems with BSDisms that have SIGTSTP
- X defined but don't actually implement it
- Xio.c: change name of variable 'border' to 'screen_border' to avoid naming
- X conflict on SGI/SYS V machine
- XINSTALL: moved from doc subdirectory to root directory, and brought up to date
- X---------------- 3/1
- Xmisc2.c: two places where (1L << j) occurred, and j could be 99 (unknown
- X spell from spell_order[]), this is an undefined operation, fixed
- X source to not shift if j == 99
- X------------------- 3/3
- Xmisc1.c: set_options(), typing '-' on line 0 gave error, change i=max to
- X i=max-1
- Xstore1.c: item_value(), calculating digging tool values wrong, subtract off
- X objects initial p1 plusses before multiplying p1 by 100
- Xdungeon.c: for paralysed/resting, move cursor to player before refresh call
- Xcreature.c: disenchanter bat attacks could put tohit/todam/toac below zero,
- X fixed so that they can not go below zero
- Xmoria1.c: if have MAX_SHORT hp/mana, then could get overflow in regenhp/mana
- X routines, added checks for overflow
- Xdungeon.c, io.c: save on EOF code did not work, in inkey(), remove casts to
- X char in eof test, remove call to feof(), in dungeon(), add !eof_flag
- X to innermost while loop to ensure it exits on error
- Xsave.c: in sv_write(), clear death flag if eof_flag or panic_save set, so
- X player can restart game to see tombstone
- Xmain.c: set death flag if hit points are negative, can happen if a HANGUP
- X savefile or panic savefile is restored
- Xsave.c: if get_char(), don't overwrite died_from string if player is dead
- Xmain.c: if specify -r or -o, force rogue_like to appropriate value after
- X read the savefile, since get_char() will modify rogue_like_commands
- Xmoria1.c: search(), "have found a trap.." fixed, removed extra period
- Xmonsters.c: added CD_NO_SLEEP flag to jellies, oozes, elementals and the
- X gelatinous cube
- Xdungeon.c: fix "which level" wizard prompt, limited to level 99 max
- X----------- 3/4
- Xall: merged in more Mac diffs, Mac version should compile now
- Xwizard.c: stealth max 87 should be 18 in printed string
- Xdesc.c: identify(), if cursed incscribe with ID_DAMD, unsample(), do not
- X clear the ID_DAMD flag, since an unsampled item is still cursed
- Xconfig: change version number to 5.1.1 and release
- X------------ 3/5
- Xmonsters.c: added CD_NO_SLEEP flag to creeping coins
- Xrecall.c: recharge(), change chance of failure from randint((num+40)/10)=1
- X to randint((num+40-i_ptr->p1-i_ptr->level)/10)=1 to make it harder
- X to recharge high level and highlly charged wands
- Xrecall.c: change j from int to int32u, since it is used with flag fields,
- X change two %d uses of it to %ld
- Xdesc.c: objdes(), don't print ID_TRIED value for store bought items
- Xmoria2.c: a slow dart trap now has no effect if have free action
- Xio.c: must ifdef out the tbuf.c_cc code, since this causes the program to
- X fail for some reason
- X--------------- 3/13
- Xsignals.c: add void to USG signal_hander definition
- Xexterns, ms_misc.c: move fopen declaration from externs.h to ms_misc.c, and
- X make static, and make FILE * not struct _iobuf
- Xms_ansi.c: include stdio.h
- Xgenerate.c: change #if DEBUG to #ifdef DEBUG
- Xconfig.h, generate.c, types.h: added ifdefs for IBMPC_TURBO_C
- X--------- 3/16
- Xmoria1.c: inven_command() "Wear" prompt changed to "Wear/Wield"
- Xmonsters.c: earth elementals/spirits can now move through walls
- Xspells.c: wall_build(), for earth elementals, increase their hit points
- Xfiles.c: helpfile(), can ESC out now
- Xspells.c: cloning a monster will wake it up now
- Xdungeon.c: allow two-char control character sequences to be used with
- X repeated commands (deleted else from "else if (command == '^')")
- Xroglcmds.hlp: document how to avoid problem with repeated dig left command,
- X i.e. '13^H' doesn't work, type ^ then H, or type SPACE then ^H
- X--------- 3/19
- Xunix.c: initialize num_chars to zero in check_input(), in case FIONREAD absent
- X---------- 3/21
- Xall: fix most SYS_V lint errors
- X----------- 3/23
- Xdungeon.c, io.c: calling inkey() when check_input true is wrong since it traps
- X ^R and does other stuff, instead call new function raw_inkey(), which
- X only calls getch
- Xio.c: flush(), occasionally caused loss of output, instead of using fancy
- X ioctls, drain input by using check_input/raw_inkey
- X--------- 3/25
- Xdungeon.c, io.c, unix.c, atarist.c: AIX can't check to see if input is
- X pending, but can do non-blocking read, so check_input changed so
- X that it consumes input when called
- Xconstant.h: change version number to 5.1.2 and distribute
- X-------- 3/26
- Xsave.c: when resurrect, clear poisoned flag and food flag to prevent character
- X from immediately dying again
- Xmain.c, misc2.c, unix.c, save.c: fix some BSD lint errors
- Xmoria1.c: remove unnecessary flush() call from take_hit()
- Xcreatures.c, misc1.c, externs.h, variable.c: fixed problem with calls to
- X compact_monster() within creatures() by adding a horrible hack,
- X new variable hack_monptr defined to hold current creature() monptr
- X---------- 3/27
- Xvariable.c: add infra 3/2 for elf/half-elf, were both previously 0,
- X increase gnome infra from 3 to 4
- Xconfig.h, death.c, dungeon.c, externs.h, main.c, misc2.c, signals.c:
- X modify wizard mode code, no longer need password or correct UID to
- X enter, prints disclaimer then asks for confirmation
- Xatarist.c, death.c, misc2.c, ms_misc.c, save.c, signals.c: eliminate all
- X getuid() etc. code, only place these are still used is in main.c
- X and unix.c
- Xall: merge wizard/god mode, god mode nolonger exists
- Xio.c, unix.c: problems with flush() on EOF, don't call check_input if EOF,
- X also, check_input returns zero if got an error on the read, also
- X inkey() clears msg_flag on EOF to prevent infinite loops exit_game/
- X msg_print/inkey/exit_game/etc...
- Xmoria2.c: monster_death(), increase tries from 10 to 20 so that treasure will
- X be created more often
- Xconstant.h: increase MAX_MALLOC from 101 to 125 to reduce compacting monsters
- X messages, increase MAX_TALLOC from 150 to 175 because it is possible
- X to get compacting objects message during level generation
- Xconstant.h: BTH_HIT deleted, no longer used
- X----------- 3/28
- Xmoria2.c: facts(), multiply damage for missile by 2/3/4 instead of adding when
- X use proper weapons, makes missiles much more useful
- Xsave.c: write store info and time into save file even if dead, so that can
- X be restored on a resurrection
- Xconstant.h: change version to 5.1.3
- X-------- 3/30
- Xconstant.h, externs.h, files.c, misc2.c, moria1.c, moria2.c, staffs.c,
- Xwands.c, variable.c: modify how misc abilities vary with level, new variable
- X class_level_adj, which holds the new adjustment values, bth, bthb,
- X device, disarm and save affected
- Xexterns.h, misc2.c, moria2.c: critical_hits() has fourth paramter, that
- X indicates whether to use CLA_BTH or CLA_BTHB class level adj
- Xmoria2.c: penalty for attacking invisible creatures modified, was minus
- X lev * BTH_LEV_ADJ-1, now minus lev * BTH_LEV_ADJ/2, hence warriors
- X have less penalty than mages/priests
- Xcreature.c, externs.h, misc2.c, moria2.c: test_hit has a fifth paramter, that
- X indicates whether to use CLA_BTH or CLA_BTHB (or even CLA_SAVE)
- Xio.c: add abort() calls to move_cursor_relative(), print(), and put_buffer()
- X to help find bugs in the code
- Xsave.c: eliminate support for versions 5.0.11 to 5.0.13
- Xmisc2.c: get_spell(), only say 'unknown spell' if it is actually an alphabetic
- X character typed
- Xtreasure.c: delete one ring of adornment and one amulet of adornment,
- X add arrows at level 15, and bolts at level 25
- X--------- 3/31
- Xstore1.c: change missile cost to 5*pluses instead of 10*pluses, since missiles
- X appear in groups of 20 or so, this is comparable to normal weapons
- X which are 100*pluses
- Xdistribute 5.1.3 sources
- X---------- 4/3
- Xexterns.h: ifdef out definition of errno for MSDOS
- Xio.c: moved process.h include for MSDOS from middle of file to start
- Xio.c: in print(), put_buffer(), and move_cursor_relative(), clear msg_flag
- X before printing error message, prevents problems with '-more-' prompt
- Xrecall.c: roff_recall(), don't set normal movement bit near beginning,
- X also delete code that prints 'never moves' if all move bits clear
- Xspells.c: teleport monster will wake it up
- Xscrolls.c: reading a second word of recall scroll does not reset timer
- Xspells.c: wall building now heals Xorns in addition to earth elementals
- Xspells.c: drain life damage increased from 50 to 75, to match other 50th level
- X wand damages
- Xconstant.h, creature.c, moria2.c, variable.c: defined new class level adj
- X CLA_MISC_HIT and replace all test_hit uses of CLA_SAVE with this,
- X document that this is identical to save, and assumes all values same
- Xtreasure.c: two potions named poison, change first to weakness (lose str)
- X---------- 4/4
- Xsave.c: add some __GNUC__ ifdefs so that the UNIX style code will be used,
- X not the code for the broken atari st MWC libraries
- X---------- 4/6
- Xunix.c: two include files, sys/time.h and sys/resource.h are actually BSD
- X specific, put #ifndef USG around them
- X---------- 4/9
- Xdesc.c: remove all uses of "%+d", because AtariST/MWC and convex and probably
- X others do not support it
- Xspells.c: replace_spot(), clear lr flag, so that after destruction scroll,
- X destroyed areas will not be lit by a light scroll in a room
- Xcreature.c: let monsters eat other monsters of equal exp, helps prevent
- X using oozes as treasure factories
- Xmoria2.c: mon_take_hit(), if kill Balrog, always update recall info even if
- X Balrog invisible, since will always know it was the Balrog (winner!)
- Xrecall.c: sleep values too hard to learn, change test from r_wake > sleep to
- X (r_wake*r_wake)>sleep
- X-------- 4/13
- Xcreature.c, moria2.c: mon_take_hit() was called within creatures() when
- X monsters were trapped inside a wall, bracket call in creature.c with
- X code to set hack_monptr, and add code to mon_take_hit() to check it
- Xcreature.c: add code at end of creatures() loop to fix2_delete_monster() in
- X case monster died during movement (maybe it was in a wall?)
- Xexterns.h: add DGUX to USG ifdef for the 'extern int sprintf()' declaration
- Xio.c: added code to save/restore local mode word of tty driver, i.e.
- X TIOCLSET and TIOCLGET ioctl calls
- Xsave.c: for atarist && __GNUC__, call fopen with "rb" and "wb" for binary mode
- Xio.c, unix.c: for atarist && __GNUC__, don't include <sys/wait.h>
- Xexterns.h: define sprintf as int (), if defined(atarist)
- X------------ 4/14
- Xexterns.h, unix.c: three new functions tilde(), topen(), and tfopen()
- X which perform ~ expansion for file names, in externs.h, define open to
- X topen and fopen to tfopen for unix machines
- Xconfig.h, dungeon.c, main.c, save.c, unix.c: add support for ANDREW
- X distributed file system, SECURE define in config.h, disallows
- X inferior shells, also instead of giving up setuid priviledges at
- X start, calls ANDREW library functions bePlayer(), beGame(), and
- X Authenticate()
- Xunix.c: add ifdefs to use select() when compiling for xenix
- X------------- 4/15
- Xcreature.c, externs.h, files.c, io.c, main.c, misc1.c, moria2.c, recall.c,
- Xsave.c, treasure.c:
- X more Atari ST MWC fixes, eliminate fdopen(), make loc_symbol() return
- X unsigned char, all (var & long_const) constructs assign long const to
- X temp var first,
- X------------ 4/16
- XMakefile: fixed problems with 'make install'
- X----------- 4/19
- Xatarist.c: add #include <stdio.h> at start, and #endif at end
- Xmisc2.c: tohit_adj() toac_adj() todis_adj() todam_adj() all used cur_stat
- X instead of use_stat like they should have
- X---------- 4/20
- Xmoria2.c: mon_take_hit code of 4/13 wrong, use monptr instead of i at end
- Xmisc2.c: remembering code wrong, add (i < 32) to stop it at end of spell list
- Xmoria1.c: when inven full and take off object, check for object under
- X player before allowing/asking her to drop object
- Xsave.c: for atarist MWC port, ifdef out all of the open() calls, and only
- X leave the fopen() stuff in
- Xmisc1.c: compact_monsters(), don't set delete_any if fix1_delete_monster()
- X is called, because it does not decrement mfptr, call abort() if
- X cur_dis goes below zero (i.e. can't delete any monsters)
- Xall: run lint on 4.3BSD and SYS V
- Xconstant.h: change version number to 5.1.4 and distribute
- X----------- 4/27
- Xdungeon.c: add prt_map() at top after creatures(FALSE) call for ATARIST_MWC,
- X fixes display problems for some reason
- X---------- 5/1
- Xmoria1.c: inven_command(), clear msg line is ESC typed at "Drop all?" prompt
- X---------- 5/3
- Xall: eliminated upd_log(), and plog variable
- Xdoc/*: update all documentation, except moria.ms
- X---------- 5/4
- Xall: visit every subdirectory, create README or ERRORS files as needed,
- X make everything as up to do as possible, split files greater than
- X 60K so that they can be posted to comp.sources.games easily
- Xall: deleted all tmp.* files
- Xexterns.h, moria1.c, moria2.c, et al: moved functions out of moria1.c and
- X moria2.c to reduce their size to less than 60K, many functions not
- X moved were made static
- Xdungeon.c, externs.h, main.c, misc2.c, save.c, variable.c: new variable
- X to_be_wizard, allows resurrect without entering wizard mode,
- X resurrect sets noscore = 0x1, wizard mode sets noscore = 0x2,
- X prt_winner prints "Is/Was wizard" or "Resurrect" is noscore set
- X----------- 5/5
- Xmisc1.c: moved see invisible from slay animal to slay undead weapons
- Xdoc/moria.ms: updated documentation to reflect changes from 4.873 to 5.1,
- X added section which explains crowns, added some sections from
- X Chris J Stuart's BRUCE Moria's documentation
- X--------- 5/7
- Xmonsters.c: ogre mage is now evil
- Xfiles.c: added extern int error for MSDOS
- Xmoria.ms: proof read it again
- Xmisc1.c: reduce plus to dam for slay dragon arrows from +10 to +3, no
- X longer need such high damages because ptodam is multiplied now
- X when used with right weapon
- XMakefile: test and fix 'make install'
- Xibmpc/ms_ansi.c: change two escape characters to \033
- Xmac/moria.r: change many control characters to \xxx, update version info
- X strings to 5.1.5
- Xconstant.h: change the version number to 5.1.5 and distribute
- X--------- 5/9
- Xconstant.h, mac/moria.r: change the version number to 5.2.0
- Xsave.c: fix support code for 5.0 savefiles, because of minor version number
- X change, update compatibility code for 5.1 and 5.2 savefiles
- Xsave.c: save/restore value of died_from string
- X------- 5/10
- Xscrnmgr.r, scrntest.r: these files had control characters also, changed
- X '...' to \311
- Xresource.hqx: recompiled the mac resource files
- Xmacscore.c, mac.c: changed control characters '...' to \311
- Xall: distribute version 5.2.0
- X----------- 5/14
- Xdeath.c, externs.h, io.c, ms_misc.c: Turbo C changes, void sleep() instead
- X of unsigned sleep(), don't call reset_term() before exiting, ifdef
- X out definition of sleep() in ms_misc.c, declare signal handler as
- X void not int
- Xgenerate.c, types.h: change IBMPC_TURBO_C defines to the proper TURBOC define
- Xio.c: shell_out(), MSDOS code parameter to inkey() call deleted
- Xexterns.h: count_msg_print() changed from (int) to (char *)
- Xio.c: get_check(), add code to use 'y' if LINT_ARGS defined, pause_exit()
- X add code to use 'delay' for MSDOS machines
- Xms_misc.c: clear_screen(0,0) changed to clear_screen()
- Xmain.c: set stack size for TURBOC by declaring the _stksize variable
- Xmisc2.c: player_saves(), split expression up because MPW C couldn't handle it
- Xsave.c: include time.h for for the Mac, delete var 'i' in save_char (unused),
- X get_char() add code for MAC to return FALSE if savefile doesn't exist
- Xmac.c: add call to initsavedefaults() in main()
- Xmac/ERRORS: document problem with mac Makefile
- X-------- 5/15
- Xexterns.h: remove decl of py_bash(), which is in moria2.c and static
- X--------- 5/17
- Xdungeon.c: move search_off() call after check_view(), as panel_* variables
- X must be valid before search_off() is called
- X-------- 5/18
- Xall: 7 files did not end with newlines, 5 hqx files, and origcmds.hlp,
- X misc/README also did not end with a newline
- X-------- 5/21
- Xconstant.h, version.hlp, moria.r: change version number to 5.2.1
- XScrnMgr.doc: split all lines greater than 80 characters, to make the file
- X more portable
- X--------- 5/22
- Xdeath.c: in mac sources, there was a 'true' instead of a 'TRUE'
- Xms_misc.c: Turbo C sscanf() incorrectly reads a newline from a blank line,
- X add check for newline to code that reads configuration file
- Xspells.c: door_creation(), called popt() before calling delete_object()
- X which could then invalidate the value returned by popt, moved
- X popt() call after the delete_object() call
- X----------- 5/25
- Xcreature.c: fix the invincible/invisible monster bug, multiply_monster()
- X was creating children on top of the parent, thus killing the parent
- X for carnivorous monsters
- Xdeath.c, externs.h, generate.c, io.c, main.c, ms_misc.c, signals.c, types.h:
- X change all TURBOC defines to __TURBOC__
- Xutil/printit: new version of the printit program by Carl Hommel, fixed up
- X to be somewhat more portable and to use only moria defined constants
- X-------- 5/27
- Xplayer.c, tables.c, variable.c: Turbo C can not accept any file with more than
- X 64K global variables, so variable.c split into three parts, also
- X updated all makefiles to refer to all three files
- Xmac files: all three mac Makefiles modified to delete obsolete references to
- X CInterface.o and CRuntime.o, scrnmgr Makefile modified to automatically
- X combine the two ScrnMgr.c parts, README updated to document a problem
- X with the Makefile not appending resources and text files sometimes
- X---------- 5/31
- Xall: released umoria 5.2.1
- Xibmpc/ms_misc.c: corrected warn() function to use va_list, the old function
- X was not strictly correct
- X---------- 6/4
- Xmisc2.c: prt_stat_block() must also call prt_study()
- Xmisc2.c: random_object() could create objects outside of map boudaries,
- X added an in_bounds() call to fix
- X------------- 6/6
- Xmain.c: changed 'if (p = getenv(...))' to 'if ((p = getenv(...)) != NULL)'
- X to avoid compiler warnings
- Xmoria1.c: rest_on(), add check to make sure rest_num fits in short
- Xibmpc/umoria.prj: new file, a project file for Turbo C 2.0
- X------------- 6/9
- Xio.c: HP-UX does not have VEOL2, added #ifdef VEOL2 around its use
- Xdungeon.c: clear message line after change_character(), since as ESCAPE
- X exit does not
- Xmoria1.c: for 'x' and 'w' commands, clear heavy_weapon flag before calling
- X check_strength, so that always get heavy message when wielding heavy
- X weapon, and never get light message when wielding light weapon
- Xscrolls.c: identify scroll can move arbitrarily far after ident_spell(),
- X replace simple 'moved one down' check with loop to search until found
- Xmain.c: fixed starup code so that don't get 'savefile doesn't exist'
- X message anymore when starting a new game
- Xall: apply fix to all uses of long constant with & | << operators to avoid
- X a Mark Williams C bug on the Atari ST
- Xexterns.h, files.c: removed MSDOS declaration of errno from files.c, and
- X remove ifndef MSDOS from errno decl in externs.h
- Xmisc1.c: changed name of variable 'clock' to 'clock_var' to avoid problem
- X with a mac compiler (not sure which one)
- Xio.c: every io.c file, remove '\0' as alias for ESCAPE from get_com() and
- X get_comdir() (MAC only function)
- Xmoria1.c: light_dam() calls inven_damage(set_lightning_destroy, 3) which
- X gives it a small chance of destroying objects in player's pack,
- X this makes it just like the other *_dam() functions
- Xspells.c: teleport_to(), add call to in_bound() to make sure player will
- X be teleported to somewhere inside the dungeon
- X------------- 6/10
- Xconfig.h: add note about using GCC on an Atari ST
- Xmain.c, save.c, undef.c: eliminated the unused _new_log() function
- Xdeath.c, dungeon.c, externs.h, save.c, undef.c, variable.c: eliminated the
- X mostly unused log_index variable, the few uses of it were replaced
- X with references to character_saved
- Xexterns.h, files.c, io.c, undef.c: init_scorefile() implemented, same as
- X in umoria 4.87
- Xmain.c, undef.c: eliminate unused function init_files()
- Xconstant.h, moria.r, version.hlp: change version number to 5.2.2
- X----------- 6/11
- Xibmpc/ms_misc.c: added space to GRAPHICS scanf, to try to eliminate problem
- X with Turco C
- Xdeath.c, externs.h, files.c, save.c, variable.c: extensive changes to
- X implement the scorefile, total_points(), highscores(), display_
- X scores(), set_fileptr(), rd_highscore(), and wr_highscore() defined
- X scorefile holds 1000 entries max, has one sex/race/class entry per
- X non-zero uid, has live characters also
- Xunix/Makefile: fix the treatment of score file, don't copy over old one,
- X just use touch to create one if it doesn't exist
- Xundef.c: finally eliminated
- X---------- 6/13
- Xall: lint under 4.3 BSD and AIX 2.2.1 (SYS V)
- Xscores: readd scores file, since it makes micro distributions much easier
- Xdeath.c: modify savefile for single user machine, so that it tries to
- X prevent a single character from appearing multiple times in the
- X savefile, checks for identical names, and killed by = (saved)
- Xplayer.c: eliminated the unused dsp_race[] array
- Xdeath.c: added code to implement flock() for systems which don't have it,
- X based on code written by CJS for BRUCE Moria
- X---------- 6/17
- Xall: fixes for VMS, define USG for VMS, merge in fixes from Todd Pierzina
- X---------- 6/23
- Xscrolls.c: for curse weapon, call py_bonuses(-1) before clear flags so
- X that attributes will be turned off
- Xmoria1.c: calc_bonuses(), handle AC just like everything else, previously
- X did not add in AC bonus if armor was cursed
- Xcreature.c, moria2.c: doors weren't being broken when bashed, change
- X "randint(2) - 1" to "1 - randint(2)"
- X----------- 7/14
- Xall: merge in some changes indiciated by warnings/prototypes generated by
- X MSC 5.x
- Xrecall.c: compute monster kill exp in long, to avoid overflow of int
- Xall: added AMIGA support
- Xamiga/: new directory to hold support files for the amiga
- Xmain.c: variable result was not initialized to false
- X------------- 7/15
- Xall: merge in more VMS patches
- Xdeath.c, dungeon.c: fixed display_scores() and 'V' command problems
- Xcreature.c, dungeon.c, misc2.c, moria1.c: new feature '*' rest until
- X reach max mana and hp, print error message for illegal rest count
- Xall: removed improper define of NULL, new define CNIL for (char *)0, used
- X instead of NULL where appropriate, eliminate strange include orders
- X that the previous NULL define required
- Xio.c: ifdefed out the include for termio.h, as this caused it to be included
- X twice on some systems (curses.h includes it also) causing problems
- Xmacrsrc.h: changed MAX_RESTART from 37 to 36
- X--------- 7/21
- Xms_misc.c: fixed reading of empty lines from config file for Turbo C
- X-------- 7/22
- Xio.c: fix Amiga code for flush()
- Xtypes.h: reduce size of cave_type structure for Amiga/Aztec C 5.0
- Xdeath.c: fix display_scores(), so that it only shows entries belonging to
- X current player when show_player is true
- X--------- 8/29
- Xmisc2.c: deleted some redundant code in gain_spells() where it calculates
- X which spells a player can learn
- Xspells.c: recharge(), could call randint() with 0 or negative numbers, check
- X for these cases before calling randint()
- X--------- 9/8
- Xmoria1.c: inven_command(), when drop/remove object and inven/equip are both
- X empty, set inven weight to zero, just to be safe
- Xdungeon.c: jamdoor(), when jam a door, decrement inven_weight by weight of
- X one spike
- Xmoria1.c: inven_command(), make spikes wieldable objects, fight with them
- X like missile weapons, i.e. they disappear after use
- Xdesc.c: objdes(), add damage multiplier of bows to their name
- Xexterns.h, io.c, misc1.c, save.c variable.c: new option sound_beep_flag, so
- X that players can turn off bad character beep if desired
- Xdesc.c, misc2.c: modify known1_p() to return TRUE for objects which never
- X have a color, modify objdes() to work with the new convention,
- X modify inven_carry() so that objects are added to the inventory
- X sorted by subval if they are known1_p()
- X---------- 9/9
- Xmisc1.c: add_food(), fix so that does not use f_ptr->slow to set f_ptr->food
- X value, this makes it much less likely to overflow the food level
- Xmisc2.c: inven_carry(), yesterday's insert in order fix does not work for
- X items which can be unknown1p, only insert items ordered by subval if
- X they are always known1p, i.e. object_offset() returns -1
- Xexterns.h, misc1.c, misc2.c, save.c variable.c: new option display rest/repeat
- X counts, since these counts make resting at 1200 baud or less
- X unbearably slow, people need to be able to turn them off
- Xstore2.c: get_haggle(), let RET default to the last inc/dec amount when
- X haggling
- Xmisc1.c: compact_monsters(), return FALSE if could not delete any monsters
- X instead of aborting, popm() return -1 if could not allocate monster
- X (i.e. compact_monsters() failed), place_win_monster() abort if popm()
- X fails which should never happen, place_monster()
- Xexterns.h: place_monster() now int type not void,
- Xcreature.c, misc1.c, spells.c: fix users of place_monster() to check result,
- X and fail if place_monster() failed, really only necessary for the
- X calls in creature.c, these fixes fix the monster list overflow bug
- Xdungeon.c, externs.h, misc1.c: change compact_monsters() from static to
- X extern, call it from within main loop in dungeon.c if there are less
- X than 10 spaces left in the monster list, compact_monsters() is much
- X more likely to be successful when called here than when called from
- X creatures()
- X----------- 9/11
- Xsignals.c: delete extra definition of error_sig for ATARIST_MWC
- Xatari_st/README: update with GCC and Turbo C info
- Xfiles.c: fix typo, filname1 -> filename1
- X--------------- 9/18
- Xmac.c, ScrnMgr1.c: replace uses of KeyMapLM with GetKeys() call
- X------------- 9/19
- Xmisc1.c: m_bonus(), could overflow on 16 bit machines when level >= 263
- X when calculating stand_dev
- Xdeath.c, externs.h, save.c: store the encryption byte for each savefile record
- X immediately before it in the scorefile, makes the scorefile more
- X robust in the face of a system crash, rd_highscore(), wr_highscore()
- X no longer pass the encryption byte
- Xdeath.c: added version numbers to the savefile
- Xdeath.c, externs.h, save.c, variable.c: add max_score to savefile, which is
- X the maximum score the character has reached so far, total_points()
- X modified to use the larger of the computed score, and the value of
- X max_score, this prevents a "(saved)" message on the score file for
- X a dead character, which died having fewer points than when it was
- X last saved
- X----------- 9/26
- Xdeath.c, externs.h, main.c, save.c, types.h, variable.c: new global variable
- X birth_date, set to time when character created, saved in save files
- X and scorefile, when loading character check to see if the a character
- X in the scorefile has the same race/sex/class/uid/birth_date and
- X its died_from is not "(saved)", in which case this character will not
- X be scored
- Xmisc2.c: print "Duplicate" on screen for such duplicate characters
- Xall: update all documentation, README, and other misc descriptive files
- Xall: add fixes for Atari ST/Turbo C 2.0
- Xall: lint on Sun3/uVAX/MIPS/RT_PC
- Xrecall.c: when printing out depth of monster, print Balrog as 50 not 100
- X----------- 10/3
- Xall: fix all problems reported by maniscan/cshar, except for control-L
- X characters on a line by themselves
- X----------- 10/7
- Xcreature.c: mon_move(), cast m_ptr->fy-1 to int, so that negative values
- X will correctly compare to it, in the wall building code
- Xspoilers: new file, lists spell damages
- Xmisc2.c: prt_experience(), always check whether exp is greater than max_exp,
- X previously did not when player was at level 40
- Xcreature.c: mon_move(), set the recall CM_ATTACK_ONLY bit when a monster
- X should have moved but did not, instead of the old method of setting it
- X when a non-moving monster attacked
- Xstore2.c: get_haggle(), fix bugs in the automatic increment code, also, when
- X reach final offer, set the automatic increment to the required diff,
- X so that player need only hit return to bid the final amount
- Xmoria2.c: tunnel(), before checking for tunneling into a invisible monster,
- X check to make sure player is tunneling somewhere which has an effect,
- X otherwise, player can use this to 'detect' invisible monsters in
- X open spaces by trying to tunnel there
- Xmoria1.c: calc_bonuses(), base AC should always be visible, as long as the
- X item is not cursed
- X------- 10/8
- Xspells.c: td_destroy2(), should not destroy chests, not disarms and unlocks
- X them instead
- Xmisc2.c: put_misc3(), clear_from(14) not 13, was clearing the gold value
- Xfiles.c: file_character(), add the "Max Exp" and "Exp to Adv" fields to
- X the info written to a file, to match the on screen display
- Xfiles.c: file_character(), set fd to -1, not NULL, code was closing stdin
- X (== 0 == NULL) when could not open file
- Xdeath.c: exit_game(), clear character_saved before calling highscores(),
- X prevents inkey() from recursively calling exit_game() when eof on
- X stdin has been detected
- Xall: released 5.2.2 sources
- X----------- 10/23
- Xdeath.c: highscores(), must do fseek() after reaching EOF before changing
- X read/write mode, previously only did this for VMS, now do this for
- X all systems
- X----------- 10/26
- Xconfig.h, death.c, io.c: fix VMS errors, declare 'string' in death.c
- X duplicate_character(), fix typos in other files
- Xdungeon.c: for VMS, after calling kbhit(), must consume one character
- Xvms/Makefile: fixed, mostly change constants.h to constant.h
- X------------ 10/30
- Xdeath.c, externs.h, files.c, save.c: define STDIO_LOADED after including
- X stdio.h, then use it to control declarations in externs.h
- Xconstant.h, death.c: define SCOREFILE_SIZE as 1000, and use it in death.c
- Xmoria2.c: cast_spell(), when don't have enough mana, use 'gods may think you
- X presumptuous' message instead of 'summon your limited strength'
- X----------- 11/4
- Xibmpc/moria.cnf: add ^M, since otherwise MSDOS moria can't read file properly
- Xio.c: include stdio.h explicitly, and define STDIO_LOADED, so savefile
- X can be closed when shelling out
- Xstore2.c: get_haggle(), clear increment when invalid increment entered
- Xstore2.c, variables.c: last_store_inc contradictory declarations, changed both
- X to int16
- Xexterns, misc2.c, sets.c, spells.c: set_*_destroy changed to take inven_type
- X pointer instead of tval, modified so that (Rx) items won't be
- X destroyed by attacks of type x
- Xdeath.c: for single user systems, use birth_date instead of name when
- X looking for matching characters in savefile
- Xdeath.c: MSDOS setmode() needs file descriptor, not FILE pointer
- Xfiles/*: removed all TABS, since some systems do not handle them properly,
- X specifically, Turbo C on the Atari ST and IBM-PC
- Xmisc1.c: rings of searching cost was 100*p1, amulet of searching cost 20*p1,
- X change both to 50*p1
- Xmac/macio.c, ibmpc/tcio.c: modify beep() so that it uses the new option flag
- Xdesc.c: changed the (*2) string for bows to (x2)
- Xspells.c: slow monster and confuse monster modified to wake up monster if
- X the attacks fails
- Xspells.c: wall_to_mud() and dispel_creature(), print messages even if
- X monster not visible since the effects are visible/audible
- Xmoria2.c: for fire/acid/gas traps, print the trap message first, and then
- X damage an item
- Xtreasure.c: change name of lose memories potion to lose experience, so it
- X won't be confused with monster memories
- Xspells.c: trap_creation(), don't create a trap under the player, to prevent
- X strange occurances such as ending up under a falling rock
- Xmoria2.c: tunnel(), when wielding heavy weapon, make tunneling more difficult
- X----------- 11/6
- Xvms/getch.c: New code for kb_hit(), which was tested and works under VMS 5.2
- X the old code did not work for VMS 5.2
- X----------- 11/9
- Xmisc1.c: compact_monsters(), distance test was backwards!, now delete monsters
- X farther away first, allow a final pass with distance of 0,
- X never delete the Balrog during compaction
- X---------- 11/21
- Xdoc/history: rewrote history file to bring it up-to-date
- Xmisc2.c: gain_spells(), don't need to be able to read spell books if learning
- X priestly spells, don't fail if blind or no light
- Xdeath.c: fix #ifdef typo around <time.h> include
- X----------- 12/1
- Xstore2.c: when good bargainer, change string to "final offer", and allow
- X return to accept final offer
- Xplayer.c: change rogue start inv from Soft Armor to Cloak, so that it is the
- X same as the other non-Warrior classes
- Xdungeon.c: decrement command count after do_command() instead of before,
- X so that all counted commands will work right, this fixes 3^P
- X--------- 12/5
- Xdeath.c: display_scores(), fix VMS bug, truncate uid to a short before
- X comparing against the uid in the score file record, also move
- X the uid computation outside the loop to speedup the procedure
- Xio.c: put_buffer (), for Atari ST, was printing the untruncated out_str
- X instead of tmp_str
- X--------- 12/14
- Xatari_st/curscomp/curses.[ch], death.c, files.c, io.c, signals.c:
- X add Atari ST TC fixes for the new (in 5.2.2) code
- END_OF_FILE
- if test 51602 -ne `wc -c <'OChanges'`; then
- echo shar: \"'OChanges'\" unpacked with wrong size!
- fi
- # end of 'OChanges'
- fi
- if test -f 'source/misc4.c' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'source/misc4.c'\"
- else
- echo shar: Extracting \"'source/misc4.c'\" \(2618 characters\)
- sed "s/^X//" >'source/misc4.c' <<'END_OF_FILE'
- X/* source/misc4.c: misc code for maintaining the dungeon, printing player info
- X
- X Copyright (c) 1989-92 James E. Wilson, Robert A. Koeneke
- X
- X This software may be copied and distributed for educational, research, and
- X not for profit purposes provided that this copyright and statement are
- X included in all such copies. */
- X
- X#ifdef __TURBOC__
- X#include <stdio.h>
- X#endif
- X
- X#include "config.h"
- X#include "constant.h"
- X#include "types.h"
- X#include "externs.h"
- X
- X#ifndef USG
- X#include <sys/types.h>
- X#include <sys/param.h>
- X#endif
- X
- X#ifdef USG
- X#ifndef ATARIST_MWC
- X#include <string.h>
- X#endif
- X#else
- X#include <strings.h>
- X#endif
- X
- X
- X/* Add a comment to an object description. -CJS- */
- Xvoid scribe_object()
- X{
- X int item_val, j;
- X vtype out_val, tmp_str;
- X
- X if (inven_ctr > 0 || equip_ctr > 0)
- X {
- X if (get_item(&item_val, "Which one? ", 0, INVEN_ARRAY_SIZE, CNIL, CNIL))
- X {
- X objdes(tmp_str, &inventory[item_val], TRUE);
- X (void) sprintf(out_val, "Inscribing %s", tmp_str);
- X msg_print(out_val);
- X if (inventory[item_val].inscrip[0] != '\0')
- X (void) sprintf(out_val, "Replace %s New inscription:",
- X inventory[item_val].inscrip);
- X else
- X (void) strcpy(out_val, "Inscription: ");
- X j = 78 - strlen(tmp_str);
- X if (j > 24)
- X j = 12;
- X prt(out_val, 0, 0);
- X if (get_string(out_val, 0, (int)strlen(out_val), j))
- X inscribe(&inventory[item_val], out_val);
- X }
- X }
- X else
- X msg_print("You are not carrying anything to inscribe.");
- X}
- X
- X/* Append an additional comment to an object description. -CJS- */
- Xvoid add_inscribe(i_ptr, type)
- Xinven_type *i_ptr;
- Xint8u type;
- X{
- X i_ptr->ident |= type;
- X}
- X
- X/* Replace any existing comment in an object description with a new one. CJS*/
- Xvoid inscribe(i_ptr, str)
- Xinven_type *i_ptr;
- Xchar *str;
- X{
- X (void) strcpy(i_ptr->inscrip, str);
- X}
- X
- X
- X/* We need to reset the view of things. -CJS- */
- Xvoid check_view()
- X{
- X register int i, j;
- X register cave_type *c_ptr, *d_ptr;
- X
- X c_ptr = &cave[char_row][char_col];
- X /* Check for new panel */
- X if (get_panel(char_row, char_col, FALSE))
- X prt_map();
- X /* Move the light source */
- X move_light(char_row, char_col, char_row, char_col);
- X /* A room of light should be lit. */
- X if (c_ptr->fval == LIGHT_FLOOR)
- X {
- X if ((py.flags.blind < 1) && !c_ptr->pl)
- X light_room(char_row, char_col);
- X }
- X /* In doorway of light-room? */
- X else if (c_ptr->lr && (py.flags.blind < 1))
- X {
- X for (i = (char_row - 1); i <= (char_row + 1); i++)
- X for (j = (char_col - 1); j <= (char_col + 1); j++)
- X {
- X d_ptr = &cave[i][j];
- X if ((d_ptr->fval == LIGHT_FLOOR) && !d_ptr->pl)
- X light_room(i, j);
- X }
- X }
- X}
- END_OF_FILE
- if test 2618 -ne `wc -c <'source/misc4.c'`; then
- echo shar: \"'source/misc4.c'\" unpacked with wrong size!
- fi
- # end of 'source/misc4.c'
- fi
- echo shar: End of archive 3 \(of 39\).
- cp /dev/null ark3isdone
- MISSING=""
- for I in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 ; do
- if test ! -f ark${I}isdone ; then
- MISSING="${MISSING} ${I}"
- fi
- done
- if test "${MISSING}" = "" ; then
- echo You have unpacked all 39 archives.
- echo "Now run "bldfiles.sh" to build split files"
- rm -f ark[1-9]isdone ark[1-9][0-9]isdone
- else
- echo You still need to unpack the following archives:
- echo " " ${MISSING}
- fi
- ## End of shell archive.
- exit 0
-