Register forum user name Search FAQ

Gammon Forum

Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the password reset link.

Due to spam on this forum, all posts now need moderator approval.

 Entire forum ➜ SMAUG ➜ SMAUG coding ➜ Editing %d

Editing %d

It is now over 60 days since the last post. This thread is closed.     Refresh page


Posted by Zunit1920   (10 posts)  Bio
Date Mon 12 Dec 2005 02:36 AM (UTC)
Message
How would i go about editing %d/%s/%f used in this situation

pager_printf_color( ch, " &z[&g%d&w/&G%d&z]", obj->value[4], obj->value[5] );


This has nothing to do with my last post
Top

Posted by Conner   USA  (381 posts)  Bio
Date Reply #1 on Mon 12 Dec 2005 02:40 AM (UTC)
Message
Ok, I'm confused, what are you trying to edit the %d for? Are you changing the values to non-integers?

-=Conner=-
--
Come test your mettle in the Land of Legends at telnet://tcdbbs.zapto.org:4000
or, for a little family oriented medieval fun, come join us at The Castle's Dungeon BBS at telnet://tcdbbs.zapto.org
or, if you just want information about either, check our web page at http://tcdbbs.zapto.org
Top

Posted by Zunit1920   (10 posts)  Bio
Date Reply #2 on Mon 12 Dec 2005 03:57 AM (UTC)
Message
well its mainly %f i wanna edit, right now it is a numbers intiger and it has 6 decimals no matter what and i wanna change it to have 2

right now:
2.100000

I want:
2.10

Get what im saying?

I just need the file that i would change that in
Top

Posted by Nick Gammon   Australia  (23,173 posts)  Bio   Forum Administrator
Date Reply #3 on Mon 12 Dec 2005 05:53 AM (UTC)
Message
Change %f to %.2f

- Nick Gammon

www.gammon.com.au, www.mushclient.com
Top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


17,215 views.

It is now over 60 days since the last post. This thread is closed.     Refresh page

Go to topic:           Search the forum


[Go to top] top

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.