Resource icon

[Easter 2014] Raised Easter Bunnies & Marshmallow Ducklings 1.01

No permission to download
Requirements
Client 7.0.34.22
Characters atleast [X] days old logging in between publish day and 12:01 AM 5/1/2014 will receive an Easter Gift!
easterbunny-png.1322

  • An Easter Bunny raised in one of Sosaria’s various cities, with a chance at a rare location!
  • The Easter Bunny comes in eight (8) different vest colors.
  • 8 possible rare locations! [Add as many as you like]
  • 5 possible rare hues! [Add as many as you like]
  • Once every 24 hours the Easter Bunny will prepare an edible marshmallow duckling that can be eaten.
  • Marshmallow ducklings come in six (6) different colors.
marhmallowduckling-png.1323



How old shall account be in order to obtain Easter Gift?
GiftGiving.cs - Line 60 (by default I have this set to 7 days, adjust as you like)
Code:
public virtual TimeSpan MinimumAge{ get{ return TimeSpan.FromDays( 7.0 ); } }

Note: GiftGiving.cs should already be in your Scripts\Misc\Gifts folder, if not then use this copy.


What day shall the Easter gift giving begin and end?
HappyEasterBasketGiver.cs - Line 15 & 16
Code:
public override DateTime Start{ get{ return new DateTime( HolidayConfig.m_CurrentYear, 4, 16 ); } }
public override DateTime Finish{ get{ return new DateTime( HolidayConfig.m_CurrentYear, 5, 1 ); } }

IMPORTANT NOTE! Be sure the START date is at least 1 day later than your latest restart. Example: If you want to give out gifts starting on 4-20-14 then set the date to 4-20-14 but be sure you restart your server on or before 4-19-14. If you do not follow this procedure not all players will get the gift.

Year Tagging!
Included in this package is the HolidayConfig.cs
Take notice in RaisedEasterBunny.cs and the HolidayConfig.cs files to see how to use this in your own holiday scripts. This will allow you to reuse the same gifts another year without the need to code another just to show a different date.


THE EASTER BUNNY!
Code:
/* Script Name: Easter Bunny
* Author(s): Tecmo [email protected]
* Version: 1.00
* Release Date: 2014.04.16
* Copyright: The Ninth Virtue © 2014 Tecmo http://www.ninthvirtue.com
* Free to use, edit and redistribute. Please leave header intact.
* Purpose: EA Item obtained @ Easter Holiday
* Characters atleast 7 days old logging in between publish day and 12:01 AM 5/1/2014 will receive an Easter Gift! •
* An Easter Bunny raised in one of Sosaria’s various cities (26), with a chance at a rare location (8)! •
* The Easter Bunny comes in eight (8) different vest colors •
* Once every 24 hours the Easter Bunny will prepare an edible marshmallow duckling that can be eaten •
* Marshmallow ducklings come in six (6) different colors.
*/
Customize the details of the Easter Bunny to your liking...

Important Note: If using GiftGiving be sure to restart your server with this Easter Package before 12:01 AM of the day you wish to start the gift giving. This is suggested to prevent "I didn't get my gift" pages.
Code:
  #region Config
/* What months will you allow the Bunny to give gifts? */
/* Jan = 1, Feb = 2, Mar = 3, Apr = 4, May = 5, Jun = 6, Jul = 7, Aug = 8, Sep = 9, Oct = 10, Nov = 11, Dec = 12 */
/* Note: Starting month must be a lesser or equal to ending month! */
private int m_StartingMonth = 3; //Will allow Bunny to start giving gifts on the 1st day of this month. [Default: 3]
private int m_EndingMonth = 4; //Will allow Bunny to give gifts up to the last day of this month. [Default: 4]

private TimeSpan m_GiftTimer = TimeSpan.FromHours(24); //Time that will expire before Bunny will give another gift. [Default: TimeSpan.FromHours(24)]
private double m_GiftChance = 0.05;//Chance to gift a rare gift such as Chocolate Jellybeans [Min value of 0.01 to Max value of 1.00, Default: 0.05]

private static int[] m_NormalHues = new int[] { 17, 33, 1196, 1359, 1366, 1372, 1378, }; //Default = Official Servers
private static int[] m_RareHues = new int[] { 1151, 1157, 1175, 1283, 1289, }; //Custom Hues
private bool AllowRareHueOnAll = false; //Do you want Rare Hue chance for all or just Rare Locations? If true the chance to get rare hue on all is same as RareLocationChance (below).
private double m_RareLocationChance = 0.05;//Chance that Easter Bunny will be shown as being raised in a Rare Location.

private static string[] m_RareLocations = new string[]
{
"King Blackthorn's Castle",
"Bet-Lem Reg", /*Ilshenar: Pixie village*/
"Lakeshire", /*Ilshenar: Home city of the Meer people*/
"Mireg", /*Ilshenar: Home city of the Meer people (native spelling)*/
"Mistas", /*Ilshenar: Ruined city*/
"Montor", /*Ilshenar: Ruined city*/
"Reg Volom", /*Ilshenar: Home of the Ethereals*/
"Ver Lor Reg", /*Ilshenar: Gargoyle City*/
};
#endregion
  • easterbunny.png
    easterbunny.png
    15.3 KB · Views: 247
  • marhmallowduckling.png
    marhmallowduckling.png
    7.7 KB · Views: 194
  • Like
Reactions: Mogster
Author
Tecmo
Downloads
65
Views
1,052
First release
Last update
Rating
0.00 star(s) 0 ratings
Back