Login
User Name:

Password:



Register
Forgot your password?
Vote for Us!
tintin++ ogg sound player script for linux
Author: Robert Smith
Submitted by: Vladaar
6Dragons ogg Soundpack
Author: Vladaar
Submitted by: Vladaar
6Dragons 4.4
Author: Vladaar
Submitted by: Vladaar
LoP 1.46
Author: Remcon
Submitted by: Remcon
LOP 1.45
Author: Remcon
Submitted by: Remcon
Users Online
CommonCrawl, Bing, DotBot

Members: 0
Guests: 10
Stats
Files
Topics
Posts
Members
Newest Member
481
3,739
19,386
619
Alexander
Today's Birthdays
There are no member birthdays today.
Related Links
» SmaugMuds.org » Bugfix Lists » AFKMud Bugfix List » [Bug] Formatting in the showc...
Forum Rules | Mark all | Recent Posts

[Bug] Formatting in the showclass command looks ugly
< Newer Topic :: Older Topic > AFKMud 2.0

Pages:<< prev 1 next >>
Post is unread #1 Jan 6, 2007, 9:53 am
Go to the top of the page
Go to the bottom of the page

Samson
Black Hand
GroupAdministrators
Posts3,643
JoinedJan 1, 2002

Bug: Formatting in the showclass command looks ugly
Danger: Trivial - Output formatting only.
Discovered in: AFKMud 2.0
Found by: Samson
Fixed by: Samson

---

act_wiz.cpp, do_showclass

Locate:
   ch->pagerf( "&wStarting Weapon:  &W%-5.5d &wStarting Armor:     &W%-5d\r\n", Class->weapon, Class->armor );
   ch->pagerf( "&wStarting Legwear: &W%-5.5d &wStarting Headwear:  &W%-5d\r\n", Class->legwear, Class->headwear );
   ch->pagerf( "&wStarting Armwear: &W%-5.5d &wStarting Footwear:  &W%-5d\r\n", Class->armwear, Class->footwear );
   ch->pagerf( "&wStarting Shield:  &W%-5.5d &wStarting Held Item: &W%-5d\r\n", Class->shield, Class->held );
   ch->pagerf( "&wMax Skill Adept:  &W%-3.3d &wBaseThac0: &W%-5.5d &wThac0Gain: &W%f\r\n",
               Class->skill_adept, Class->base_thac0, Class->thac0_gain );


Change to:
   ch->pagerf( "&wStarting Weapon:  &W%-6d &wStarting Armor:     &W%-6d\r\n", Class->weapon, Class->armor );
   ch->pagerf( "&wStarting Legwear: &W%-6d &wStarting Headwear:  &W%-6d\r\n", Class->legwear, Class->headwear );
   ch->pagerf( "&wStarting Armwear: &W%-6d &wStarting Footwear:  &W%-6d\r\n", Class->armwear, Class->footwear );
   ch->pagerf( "&wStarting Shield:  &W%-6d &wStarting Held Item: &W%-6d\r\n", Class->shield, Class->held );
   ch->pagerf( "&wBaseThac0:        &W%-6d &wThac0Gain: &W%f\r\n", Class->base_thac0, Class->thac0_gain );
   ch->pagerf( "&wMax Skill Adept:  &W%-3d ", Class->skill_adept );


The formatting tags in this command made the output on the left side look ugly because it was adding leading zeros to the numbers which was not desired. It would also mess up the flow if a vnum was > 5 digits. So it makes room enough for 6 digits to be nicely displayed.
       
Pages:<< prev 1 next >>