Login
User Name:

Password:



Register
Forgot your password?
Vote for Us!
Couple bugs
Dec 12, 2017, 5:42 pm
By Remcon
Bug in disarm( )
Nov 12, 2017, 6:54 pm
By GatewaySysop
Bug in will_fall( )
Oct 23, 2017, 1:35 am
By GatewaySysop
Bug in do_zap( ), do_brandish( )
Oct 18, 2017, 1:52 pm
By GatewaySysop
Bug in get_exp_worth( )
Oct 10, 2017, 1:26 am
By GatewaySysop
LOP 1.45
Author: Remcon
Submitted by: Remcon
LOP Heroes Edition
Author: Vladaar
Submitted by: Vladaar
Heroes sound extras
Author: Vladaar
Submitted by: Vladaar
6Dragons 4.3
Author: Vladaar
Submitted by: Vladaar
Memwatch
Author: Johan Lindh
Submitted by: Vladaar
Users Online
CommonCrawl, Yandex, Yahoo!, Sogou, Bing, DotBot

Members: 0
Guests: 8
Stats
Files
Topics
Posts
Members
Newest Member
477
3,705
19,232
608
LAntorcha
Today's Birthdays
There are no member birthdays today.
Related Links
» SmaugMuds.org » Bugfix Lists » SmaugFUSS Bugfix List » [Bug] Buffers being assigned ...
Forum Rules | Mark all | Recent Posts

[Bug] Buffers being assigned but never actually used
< Newer Topic :: Older Topic >

Pages:<< prev 1 next >>
Post is unread #1 Sep 3, 2005, 11:07 am
Go to the top of the page
Go to the bottom of the page

Samson
Black Hand
GroupAdministrators
Posts3,639
JoinedJan 1, 2002

Bug: Buffers being assigned but never actually used
Danger: Trivial - Lack of output, unnecessary buffer use
Found by: Remcon
Fixed by: Remcon

---

update.c, advance_level

Locate:
   /*
    * bonus for deadlies 
    */
   if( IS_PKILL( ch ) )
   {
      add_mana = ( int )( add_mana + add_mana * .3 );
      add_move = ( int )( add_move + add_move * .3 );
      add_hp += 1;   /* bitch at blod if you don't like this :) */
      sprintf( buf, "Gravoc's Pandect steels your sinews.\n\r" );
   }


Change to:
   /*
    * bonus for deadlies 
    */
   if( IS_PKILL( ch ) )
   {
      add_mana = ( int )( add_mana + add_mana * .3 );
      add_move = ( int )( add_move + add_move * .3 );
      add_hp += 1;   /* bitch at blod if you don't like this :) */
      send_to_char( "Gravoc's Pandect steels your sinews.\n\r", ch );
   }


update.c, gain_exp

Locate:
   /*
    * Deadly exp loss floor is exp floor of level
    */
   if( IS_PKILL( ch ) && modgain < 0 )
   {
      if( ch->exp + modgain < exp_level( ch, ch->level ) )
      {
         modgain = exp_level( ch, ch->level ) - ch->exp;
         sprintf( buf, "Gravoc's Pandect protects your insight.\n\r" );
      }
   }


Change to:
   /*
    * Deadly exp loss floor is exp floor of level
    */
   if( IS_PKILL( ch ) && modgain < 0 )
   {
      if( ch->exp + modgain < exp_level( ch, ch->level ) )
      {
         modgain = exp_level( ch, ch->level ) - ch->exp;
         send_to_char( "Gravoc's Pandect protects your insight.\n\r", ch );
      }
   }


shops.c, appraise_all

Locate:
   char buf[MAX_STRING_LENGTH], *pbuf = buf;


Change to:
   char buf[MAX_STRING_LENGTH];


Locate:
   if( total > 0 )
   {
      send_to_char( "\n\r", ch );
      sprintf( buf, "$N tells you, 'It will cost %d piece%s of gold in total.'", total, cost == 1 ? "" : "s" );
      act( AT_TELL, buf, ch, NULL, keeper, TO_CHAR );
      strcpy( pbuf, "$N tells you, 'Remember there is a 10% surcharge for repair all.'" );
      act( AT_TELL, buf, ch, NULL, keeper, TO_CHAR );
   }


Change to:
   if( total > 0 )
   {
      send_to_char( "\n\r", ch );
      sprintf( buf, "$N tells you, 'It will cost %d piece%s of gold in total.'", total, cost == 1 ? "" : "s" );
      act( AT_TELL, buf, ch, NULL, keeper, TO_CHAR );
      act( AT_TELL, "$N tells you, 'Remember there is a 10% surchurge for repair all'", ch, NULL, keeper, TO_CHAR );
   }


The above fixes are more or less things that got overlooked, though one does wonder why the lack of output in two of them was never noticed after all these years.....
       
Pages:<< prev 1 next >>