DragonPrime - LoGD Resource Community
Welcome Guest
  • Good morning, Guest.
    Please log in, or register.
  • March 22, 2019, 07:00:45 AM
Home Forums News Downloads Login Register Advanced Search
* * *
DragonPrime Menu
Login
 
 
Resource Pages
Search

Pages: [1] 2   Go Down
  Print  
Author Topic: Mount Age  (Read 5764 times)
0 Members and 1 Guest are viewing this topic.
Enhas
Guest
« on: August 04, 2005, 06:21:23 PM »

After reading the Riding Accident Module thread, I had the idea to make this (and I've tested it pretty well.. there still may be a bug or two but I doubt it):

Mount Age is a Module where over time, mounts can get weaker, or even die.

- On and after 75 (default) game days of owning your mount, there is a 1 in 5 chance on newday that your mount will fall asleep.  You'll wake it up, and it'll be in such a daze / tired that it'll start with half of its usual buff rounds.

- On and after 200 (default) game days of owning your mount, there is a 1 in 10 chance on newday that your mount will die of old age.  You will lose your mount (duh), and 25% of your turns for that day.

Admin Settings:

- After how many game days can mounts weaken (default 75)
- After how many game days can mounts die (default 200)
- ID # of Prize Mount (if available, and viewonly)

http://dragonprime.net/users/Enhas/mountage.txt
« Last Edit: August 05, 2005, 02:02:02 PM by Enhas » Logged
Elessa
Faerie
Mod God
*****
Offline Offline

Posts: 3598


short, sweet and to the point


View Profile
« Reply #1 on: August 04, 2005, 07:46:34 PM »

ye truly possess a devious mind. granted i saw the hint given to create such a thing by another devious mind.

however, to follow through with it, is very wicked indeed.  Wink
« Last Edit: August 04, 2005, 08:02:54 PM by Elessa » Logged

Uuma ma ten rashwe, ta tuluva a lle

Play the latest beta version here on LoGD DragonPrime - Axebridge
Enhas
Guest
« Reply #2 on: August 04, 2005, 08:37:16 PM »

Oops, I noticed something that I forgot about.. if you'd buy the same mount that you have, the age would stay the same on the newer mount (ie. if you had a 65 day Gelding, the new Gelding would be 65 days).

Fixed this, and updated version to 1.01.  Same link.
Logged
Elessa
Faerie
Mod God
*****
Offline Offline

Posts: 3598


short, sweet and to the point


View Profile
« Reply #3 on: August 04, 2005, 08:39:28 PM »

what if in one day i sell my gelding, buy a pony, sell the pony and repurchase a gelding? will the gelding still be sixty-five days old?
Logged

Uuma ma ten rashwe, ta tuluva a lle

Play the latest beta version here on LoGD DragonPrime - Axebridge
Enhas
Guest
« Reply #4 on: August 04, 2005, 08:40:56 PM »

No, anytime you switch / lose mounts now the day pref gets reset to zero (either on newday or when you buy/trade a mount).

Edit: Deleted an unneeded hook after a bit more testing, now version 1.02.
« Last Edit: August 04, 2005, 09:01:15 PM by Enhas » Logged
Enhas
Guest
« Reply #5 on: August 04, 2005, 10:57:50 PM »

Updated to 1.03 (I update some stuff a lot, heh).

Now works correctly with Prize Mounts.

Your Prize Mount is immune to age, weakness, and old age death.  The age of the old mount is also kept in another pref, and is set back once you lose your Prize Mount.  Example:

You had a Gryphon at age 84, and were awarded a Black Unicorn Prize Mount for three days.  During those three days, the Black Unicorn will not age, or be affected by weakness or old age effects.  After those three days are up and you get your Gryphon back, it will be 85 days old (84 days, +1 for newday.. before I fixed this, when you got your mount back it would be back down to 1 day old!).

Same link.
« Last Edit: August 05, 2005, 04:35:30 PM by Enhas » Logged
Kendaer
Guest
« Reply #6 on: August 05, 2005, 07:31:34 AM »

Rather than having to manually keep the prize mount in sync you could use the code to ask the prizemount what it's mount id was.

if (is_module_active("prizemount")) {
    $mountid = get_module_setting("mountid", "prizemount");
} else {
    $mountid = -1;
}

(and of course check anywhere you'd use the mountid to make sure it's !== -1 Smiley)

Much saner than keeping the setting in two places where I gaurentee one day you will update one and forget to update the other.
Logged
Enhas
Guest
« Reply #7 on: August 05, 2005, 02:01:35 PM »

Thanks for the tip, I'm not quite PHP inclined.. Tongue

Anyways, I added that code, and it works well.  Now you no longer need to manually add the prize mount id in, it will do it automatically if the Prize Mount module is active.

Updated to 1.05, same link:

http://dragonprime.net/users/Enhas/mountage.txt
Logged
Nightborn
Guest
« Reply #8 on: October 28, 2005, 06:29:40 AM »

Hm, one aspect of roleplaying:

If you want to keep your mount... why not "refresh" it or let it be "reborn" at the full cost of a new mount of that type (or even more) ... if I use the mount naming mod from Sichae, this would affect roleplay if you say "oh, well, this is dragon # 342" ... this mod is in fact good to balance gameplay. Smiley

why not hook in the stables and make an option to "reset" the game days of the mount. won't be a problem ... I guess Smiley

I am using this on 2 servers to keep gems at bay.
Logged
Dannic
Guest
« Reply #9 on: October 28, 2005, 06:24:23 PM »

how about degrading the amount of extra travel the mount gives with age as well.

Just another idea.  
Logged
sixf00t4
Mod God
*****
Offline Offline

Posts: 1916



View Profile WWW
« Reply #10 on: November 04, 2005, 10:35:08 AM »

I updated this module to use object prefs, so now each mount can have its own expiration date.  I think this is the way it should be, maybe even worthy of core? wink wink, nudge nudge.

see attachment.
Logged

Nightborn
Guest
« Reply #11 on: November 04, 2005, 10:42:27 AM »

how about refreshment or "fountain of youth" for the same price?

just to let them keep the "original" yet spend gems?
Logged
sixf00t4
Mod God
*****
Offline Offline

Posts: 1916



View Profile WWW
« Reply #12 on: November 04, 2005, 11:20:47 AM »

how about refreshment or "fountain of youth" for the same price?

just to let them keep the "original" yet spend gems?
hey, I added what i wanted out of the module, what's your deal? Lips Sealed Tongue Kiss

We'll see what Enhas says, if he doesnt want to add it, and you don't feel like it either, i may be inclined to take over the module and add that as an option...
Logged

Enhas
Guest
« Reply #13 on: November 04, 2005, 03:42:24 PM »

Feel free to add what you want to it.

The settings for seperate weak/die per mount is a pretty good idea, I don't know why I never thought of it..  Cool
Logged
Enhas
Guest
« Reply #14 on: November 05, 2005, 02:06:37 PM »

Something you should change though:

"ageweak"=>"After how many game days can mounts weaken,int|75",
"agedie"=>"After how many game days can mounts die,int|250",

'can mounts' in both should be changed to 'this mount', since the weak/die setting is per-mount now, to avoid a little confusion..  Wink
Logged
Pages: [1] 2   Go Up
  Print  
 
Jump to:  


*
DragonPrime Notices
Play LoGD on Dragonprime

Support Us
No funds raised yet this year
Your help is greatly appreciated!
Recent Topics
DragonPrime LoGD
Who's Online
35 Guests, 0 Users
Home Forums News Downloads Login Register Advanced Search