RunUO Community

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

[2.x] Fishing Event Prize Kit

Hammerhand

Knight
A seer on a server I staff on wanted to do a 2 day fishing event w/ 1st, 2nd & 3rd place going to the players with the biggest (heaviest) fish. And he wanted the big fish to show the date & time caught because they had to be caught within the 2 day event to be eligible. So.. enter me.. I did that. The Big Fish now show the date & time they were caught. Then I have an idea of my own (shocking, aint it?) of modifying the TaxidermyKit (which already does trophys of the big fish) to show that same date & time on the trophy. I figured the addon deeds could be used as part of the prizes, or in a trophy room. Enter boo~boo's, issues & other fun stuff. So there I am, yelling for help in script support & got saved by ViWinfii. After a series of tests, we ended up with a fully functioning Fishing Event TaxidermyKit which can be placed in your customs folder with no worry of it interferring with the original. Just merge or over-write the BigFish.cs (Scripts/Items/Resources/Fishing) file in your server with this one & you're ready to listen to your players whining about not being able to catch a big fish to win all the glorious prizes they think they are getting. Pics included in this post are of a big fish with date/time & of the finished trophy.

 

Attachments

  • Fishing Event prize kit.rar
    4.4 KB · Views: 47

ViWinfii

Sorceror
Oh, one thing I noticed in FishingEventTaxidermyKit.cs, at line 84, you may need to edit for this to give the correct CaughtTime:

Code:
            public DateTime CaughtTime { get { return m_CaughtTime; } }

Also, unless you want staff to be able to edit CaughtTime after a fish is caught, you may want to take out or comment out the CommandProperty on line 395 for CaughtTime in the class FishingEventTrophyDeed.
 

ViWinfii

Sorceror
The player time. When you set up a public function for accessing the time when the player catches the fish, you don't want that function to return DateTime.Now, you want it to return your private DateTime that you set up when the fish is caught...which should be the private m_CaughtTime that is defined just a few lines above your public CaughtTime.
 

Hammerhand

Knight
Changed those & also removed the Command property for the weight. So that cant be changed either. I did notice that they were changable in [props, but didnt connect it until you mentioned that. Thx. File re-uploaded.
 

ViWinfii

Sorceror
On a closer look, I think some of the data in TrophyInfo is redundant, since the CaughtTime is being sent (and saved in each step) from BigFish to FishingEventTrophyDeed to FishingEventTrophyAddon back to FishingEventTrophyDeed. The CaughtTime variable is never accessed from TrophyInfo in any of those steps. I guess you could leave it in as is because it works right now.

*edit* pmed you about this :) It's my fault that the data is redundant.
 

_Epila_

Sorceror
Seems that you can have access to deep waters by Magincia docks. If the Big Fish catch logic is using the SpecialFishingNet.FullValidation() method, it will read the map and search for water tiles on the Map instead of the statics(?). Magincia docks are built over deep water; so you don't need a boat to reach the deep water and catch the big fish or anything else
It is not RunUO's fault, but just to warn that this can happen
 

Attachments

  • magincia_deep.jpg
    16.4 KB · Views: 23

Hammerhand

Knight
Big fish just require 80+ skill, a pole & deep water (boat optional depending on prankster staff members). I wont tell the players they can fish off Mag dock if you wont. ;)
 

Sachin Esha

Wanderer
Family LOVES this fishing script Hammerhand, thank you ! Not sure the purpose of the Mag. addon .cs unless its to give you more deep water to fish in, but love the script, Nice work !
Thank you
 

Hammerhand

Knight
No, its just saying that the Magincia docks are built over deep water, so you dont need a boat there to fish in deep water. You can actually stand on the docks & fish for the big fish. ;)
 

Sachin Esha

Wanderer
Ahhh ok, well We LOOOVEEEE the script, i wish there were more fishing event type scripts, once i learn C# better, i have several ideas i hope to turn into scripts. :cool:
 
Top