Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!utgpu!water!watmath!clyde!rutgers!im4u!ut-sally!seismo!rochester!pt.cs.cmu.edu!andrew.cmu.edu!jld# From: jld#@andrew.cmu.edu.UUCP Newsgroups: rec.games.empire,comp.sources.d Subject: Another Bug Fix to Empire 1.1 Message-ID: Date: Thu, 23-Apr-87 16:50:42 EST Article-I.D.: andrew.cUXcmmy00WAByX40JS Posted: Thu Apr 23 16:50:42 1987 Date-Received: Sat, 25-Apr-87 07:28:06 EST Organization: Carnegie-Mellon University Lines: 52 Xref: utgpu rec.games.empire:75 comp.sources.d:603 ReSent-Date: Thu, 23 Apr 87 17:51:08 edt ReSent-From: postman#@andrew.cmu.edu ReSent-To: nntp-xmit#@andrew.cmu.edu Return-path: X-Andrew-Authenticated-as: 248 X-Trace: MS Version 3.22 on sun3 host mansfield, by jld (248). To: outnews#ext.nn.rec.games.empire@andrew.cmu.edu, outnews#ext.nn.comp.sources.d@andrew.cmu.edu The fix to update.c that corrects the "rolling civilians" bug brings out another bug in update.c. It should only do an update of a sector if the last time that sector was updated is < the current turn number, not <=. The <= causes the program go into infinite recursion if there is a loop in delivery routes (even if each path of the loop is a different item). Below is a diff of the update.c file which shows both bug fixes (both are one line changes). *** update.old Thu Apr 23 17:11:59 1987 --- update.c Thu Apr 23 17:49:37 1987 *************** *** 31,37 verbose = selup & UP_VERBOSE; quiet = selup & UP_QUIET; if( sect.sct_lstup == 0 ) return(0); ! if( sect.sct_lstup <= curup ) goto X160; sect.sct_lstup = curup; return(1); X160: --- 31,37 ----- verbose = selup & UP_VERBOSE; quiet = selup & UP_QUIET; if( sect.sct_lstup == 0 ) return(0); ! if( sect.sct_lstup < curup ) goto X160; sect.sct_lstup = curup; return(1); X160: *************** *** 197,203 amt = funit * q; shipper = sect.sct_owned; putsect(x, y); ! if( getsect(dx, dy, UP_NONE) == -1 ) goto X3404; if( shipper == sect.sct_owned ) goto X3612; if( sect.sct_chkpt != 0 ) goto X3612; X3404: --- 197,203 ----- amt = funit * q; shipper = sect.sct_owned; putsect(x, y); ! if( getsect(dx, dy, UP_TIME | UP_ALL) == -1 ) goto X3404; if( shipper == sect.sct_owned ) goto X3612; if( sect.sct_chkpt != 0 ) goto X3612; X3404: Jay Davis jld@andrew.cmu.edu