DragonPrime - LoGD Resource Community
Welcome Guest
  • Good morning, Guest.
    Please log in, or register.
  • June 25, 2017, 05:12:28 AM
Home Forums News Downloads Login Register Advanced Search
* * *
DragonPrime Menu
Login
 
 
Resource Pages
Search

Pages: [1]   Go Down
  Print  
Author Topic: Holes (Forest Special)  (Read 4135 times)
0 Members and 1 Guest are viewing this topic.
BraveBrain
Guest
« on: February 21, 2004, 02:34:16 AM »

This patch is a special that started as a small idea (based on an old rock patch I've seen) and kinda evolved.

What does it do?
It adds a certain amount of holes to the forest (Default: 5).
When a player arrives he/she falls into the hole and looses random hp according to that specific (numbered) hole's settings (Default: Min 25% Max 75%. Based on the user's max hp).
What if the user dies?
If the user dies his/hers gold will be left in that specific hole.
What if the user survives?
If the user survives he/she will find the gold others have previously lost in that specific hole. The maximum amount of gold to be found can be limited to a specified multiplier of the user's level (Default: 0=unlimited).
If you i.e. set the max gold found multiplier to 1000 a level 1 user can find up to 1000 gold and a level 4 can find up to 4000, but only if there is that much gold in that specific hole.
If there's more gold in the hole than the user can find the rest of the gold will remain in the hole for the next surviving victim.
Are there other benefits/backdrafts?
The user gets a 1 in 30 chance of finding one gem if he/she survives.
The user gets an option of looking for more holes if he/she survives (Limited to one time. If he/she survives the second hole he/she will return to the forest).
No matter the outcome, a small notice will be added to the news in order to get people engaged. If people see that one player died in a hole and left 20.000 gold in there they will really want to fall into the same hole. But, if they at all get to this special, will they find that same hole? Will they survive themselves if they do? Tongue

Installation:
Detailed information in readme_holes.txt.
(Up to one addition to patchsettings.php)
If you don't want to change the default settings all you need to do is to upload it to your special directory on your server.
To be able to change the settings (i.e. adding/removing holes or setting a max-gold limit) you need to install the patch Game Settings -> Patches (thread link) or in another way add settings for the holes setup.
The settings for this patch are already included in that patch's file as an exmaple (patchsettings.php <Download PatchSettings>)

Note!
I've created this patch in kinda like a tutorial way.
It is full of comments about what it does and how, all of which can be removed.
These comments are there to help newbies getting started creating patches of their own.
Keep in mind the importance of not unbalancing your game by creating/adding bad patches though.
I kindly ask that you leave the patch details on top though (author and such).

I hope you'll like it. Have fun!  Grin
Logged
Arune
Member
Mod God
*****
Offline Offline

Posts: 718


Arune Vai - khatfield


View Profile WWW
« Reply #1 on: February 21, 2004, 02:38:44 AM »

Sounds interesting, I like the concept.

Going to try it out when I have some time..I'll let you know how it works out Smiley
Logged
BraveBrain
Guest
« Reply #2 on: February 21, 2004, 02:45:22 AM »

ty Wink

I originally made to test out PatchSettings, and then it evolved enough for me to dare post it.. hehe
Logged
BraveBrain
Guest
« Reply #3 on: February 21, 2004, 12:36:37 PM »

Well, I see that I should have checked out the forum a bit more before posting...  Undecided
I posted the Holes special event in the Modder's Area, but I guess it belongs in here instead.

Here's the link to the original post with description and download link.
Logged
BraveBrain
Guest
« Reply #4 on: February 24, 2004, 06:08:44 PM »

People on our lotgd have started noticing the holes now.
Some with rage (those that died) and soem grinning from ear to ear (those finding some of the dead ones' gold)  Tongue

Someone asked (as a joke) how much gold it would take to get a map of the holes.
Even if it was a joke it made me realize that more can be made out of them.
I'll consider various ways of doing just that...
Logged
BraveBrain
Guest
« Reply #5 on: February 24, 2004, 06:11:13 PM »

Ooops! I just realized I didn't include the link to Holes.zip <Here it is!>

Sorry'bout that...
 Embarrassed
Logged
strider
Guest
« Reply #6 on: February 24, 2004, 06:57:29 PM »

No worries mate, I'll move it over here and merge it...
Logged
BraveBrain
Guest
« Reply #7 on: February 25, 2004, 02:13:29 PM »

Thanks
Logged
Zanzaras
Captain of the Guard
***
Offline Offline

Posts: 219


*Snipe*


View Profile
« Reply #8 on: February 28, 2004, 10:22:30 PM »

 Cheesy

Cool! I'm adding this to my server. Very cool idea.
.
.
.
Just pulled this down and looked at it and I've got to say, that is some of the neatest coding I've seen! I'm always picky about the neatness/readability of the mods I write/download. Usually I go through and clean everything up so I can read it better. I won't have to touch this one at all! Thank you! Thank you! Thank you!

(Yeah, I'm weird. Messy code is one of my pet peeves, so sue me*. Tongue )



*The "So sue me" statement was meant as a joke. Please don't. I need to keep my last 2 quarters for food of some type.
« Last Edit: February 28, 2004, 10:54:21 PM by Zanzaras » Logged

"Intelligence is like a river, the deeper it is the less noise it makes."
Zanzaras
Captain of the Guard
***
Offline Offline

Posts: 219


*Snipe*


View Profile
« Reply #9 on: March 04, 2004, 11:08:06 PM »

BraveBrain,

I've been using your holes forest special on my site. So far everyone likes it. I did make one modification though. I changed it so that finding a second hole was not automatic. The player who falls in the first hole now has a 50/50 shot to find a second hole if he tries to look for one. The additional code begins after your second visit comment.

} else { // Second visit. They come from a hole
        $Found2ndHole=rand(1,4);
        if (($Found2ndHole==1)or($Found2ndHole==2))
        {output("`n`%You explore the area hoping to find other holes that may contain gold. After searching for several minutes and finding nothing, you get bored and decide to move on.`n");
         addnav("Return to the Forest","forest.php");
         $FoundHole=false;
        }
        if (($Found2ndHole==3)or($Found2ndHole==4))
        {output("`n`%You explore the area hoping to find gold in other holes. A twig snaps behind you and you spin around in a defensive posture expecting an attack. As you do so, you sidestep into the underbrush and find another hole the hard way!`n");
         $FoundHole=true;
        }
}
if ($FoundHole==true)
{$FoundHole=false;
    .
    . (the rest of your original code)
    .
}
« Last Edit: March 04, 2004, 11:08:26 PM by Zanzaras » Logged

"Intelligence is like a river, the deeper it is the less noise it makes."
Pages: [1]   Go Up
  Print  
 
Jump to:  


*
DragonPrime Notices
Version 1.1.2 is the current supported version and is available for download.

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