Hi All. Summary -------- This email covers the following topics: o Coins being an OBJ rather than a *slot* in the char_data o Coin weight o Objsave files and coins It was inspired after i had a quick skimmer over the coins snipper found on the circlemud ftp site. Thoughts --------- I was just reading through the coins snippet on ftp site, and noticed this... <snip from coins.patch> In Structs.h ************* change some of the spares in rent_info to the following: int plat; int silver; int copper; in char_point_data change the following: - int money; + int money[4]; /* Four coin types: Platinum, Gold, Silver, Copper */ <end snip> PS. Maybe make it int money[NUM_MONEY_TYPES]; so it becomes more robust in da future. -- ANYWAYS -- I have yet to read through the rest, but what are other peoples thoughts about NOT making the structure of the player (char_data) hold the coins info, but coins are of an OBJ TYPE? eg. v0 == exchange type 1, v1 == exc. type 2, etc.. ie. v0 == copper, v1 == silver, v2 == gold, v3 == platinum OR for other muds... v0 == 1cent coin, v1= 10 cent coin v2 == 1 dollar coin / note, v3 = 10 dollar coin / note you get the drift. then, coins could have weight....... and then again, the inventory could list 1000 lines saying a copper coin a gold coin unless you have your code changed... [1000] a copper coin Then again, u would have an exception in the DO_INVENTORY command so it doesn't like OBJ_MONEY =) but then weight would have to be changed, yes? currently it is.. hmm *checks code* /* ================== Memory Structure for Objects ================== */ struct obj_flag_data { .... int weight; /* Weight what else */ .... }; so either i should check for all places where OBJ WEIGHT is checked (eg. inventory - how much can be held, etc) becuase a coin is not of weight == 1 == 1 lbs? it would be much light, so i would either change weight to a float or 1 weight == .001 lbs or something like that. Bascically -> to have coins as an object --WHICH HAS WEIGHT--, then the current weight system needs to be modifed and existing objects need to be updated to co-inside with the new weight system. Also, you would need to consider if coin weight is an issue -> do u like players running around with 100,000 gold coins? [I HATE IT - but that's me] And the last note, which ties into using INVENTORY problem listed above, if i have 1000 coins in my inventory (even though i do not see them because of the exception), then what would the players object save file look like?? pretty big, yes? Conclusion ---------- Hmmm .. so it does look like making coins of type OBJ_MONEY not necessarily the best thing out.... But i could be mistaken and proven wrong. It does restrict money to 4 types (v0->v3) or does it???? Some thoughts would be nice from fellow circ programmers please. -PK- +------------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html | +------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 04/10/01 PDT