Login
User Name:

Password:



Register
Forgot your password?
Vote for Us!
Development
Nov 28, 2018, 10:10 am
By Keirath
First Immortal
Oct 12, 2018, 12:02 pm
By GatewaySysop
Bug in do_climb( )
Jun 5, 2018, 5:31 pm
By joeyfogas
question on overland code
May 31, 2018, 10:03 am
By joeyfogas
KaVir's Protocol Snip
May 15, 2018, 7:57 pm
By joeyfogas
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: 15
Stats
Files
Topics
Posts
Members
Newest Member
481
3,740
19,397
635
JenniRosen
Today's Birthdays
There are no member birthdays today.
Related Links
» SmaugMuds.org » Codebases » AFKMud Support & Development » Random Treasure System
Forum Rules | Mark all | Recent Posts

Random Treasure System
< Newer Topic :: Older Topic > W X Y Z resets

Pages:<< prev 1 next >>
Post is unread #1 Aug 26, 2013, 1:29 pm
Go to the top of the page
Go to the bottom of the page

Matteo2303
Apprentice
GroupMembers
Posts57
JoinedAug 25, 2003

I'm porting AFKMUD random-treasure system from C++ to C Smaug
I notice that in AFKMUD codebase are added some specific random resets:
Z like (O)bject, "W" like (P)ut, X like (E)quip and Y like (G)ive...
But why? Isn't more simple use standard O, P, E, and G and check if the reset object is OBJ_VNUM_TREASURE ?
In this case we need just add some reset args to (O), (P), (E) and (G) for control generate_random. Same result but with more semplicity I think.

bye
matteo
       
Post is unread #2 Aug 26, 2013, 5:45 pm
Go to the top of the page
Go to the bottom of the page

Remcon
Geomancer
GroupAdministrators
Posts1,874
JoinedJul 26, 2005

well there are different amounts of arguments for each of the new ones
       
Post is unread #3 Aug 28, 2013, 12:31 am
Go to the top of the page
Go to the bottom of the page

Matteo2303
Apprentice
GroupMembers
Posts57
JoinedAug 25, 2003


Remcon said:

well there are different amounts of arguments for each of the new ones


Yes, but imho is much better and simple add optional args to standard G, E, P, O rather than adding new W, Z, X, Y.

However I notice another thing in do_socket function:
stralloc_printf( &item->socket[0], "%s", capitalize( arg ).c_str(  ) );


I don't know if it is wanted but in this case if I have a rune called "Test" and a player digits "socked tes" the socket[0] assume "Tes" name and not "Test". Isn't better use rune->name?

Bye!
       
Post is unread #4 Aug 28, 2013, 12:26 pm
Go to the top of the page
Go to the bottom of the page

Remcon
Geomancer
GroupAdministrators
Posts1,874
JoinedJul 26, 2005

I agree lol.
       
Pages:<< prev 1 next >>