Trinitycore: [3.3.5] Added Missing Calendar events and updated game_event to match for the next 5 years.

Created on 10 Jan 2020  Â·  39Comments  Â·  Source: TrinityCore/TrinityCore

So currently, Lunar Festival, Love is in the air, Pilgrim's Bounty, Children's week, Noblegarden and Harvest Festival are missing from the Calendar.
I have added the missing Calendar events for the next 5 years and updated game_event to match.
I adjusted the start dates based on retail current start dates and the lengths based on what the Calendar shows ingame so it matches.

EDIT: This part is no longer relevant, thanks to @Ovahlord this can now be done serverside. still wont be blizzlike unless we update the dates the same way blizzard does, but at least the duration can now be changed on the calendar.

The one event that lasts a bit longer due to this is Lunar festival, it shows 21 days on the Calendar which we cant change as far as I'm aware, so I just made it match.
Before anyone says 21 days is not blizzlike, I know it's not and we won't get blizzlike unless we update the dates to match the real-world events like blizzard does, this would need clientside edits.
If you don't want it to be 21 days, you can always adjust the length, but it won't match the Calendar if you do.

NOTE: I had to set holidayStage to 0 because 1 seems to block the game_event values. For example: if I change the occurrence to 365 days, it will not change and it will instead stay at 360 days ingame.

Tests Made:
Changed my system date to 2026, checked the events are on the Calendar until 2025.
Changed my system date to just before some of the events were about to start and checked they start at the correct time.

TrinityCore rev. a149261e94b6 2020-01-09 23:10:46

-- Lunar Festival. Holiday ID: 327.
UPDATE `game_event` SET `start_time`='2020-01-24 00:01:00', `holidayStage`='0', `occurence`='525600', `length`='30240' WHERE  `eventEntry`=7;
SET @HOLIDAYID := 327;
SET @DATEID := 14;
DELETE FROM `holiday_dates` WHERE `id`=@HOLIDAYID AND `date_id` IN (@DATEID, @DATEID+1, @DATEID+2, @DATEID+3, @DATEID+4, @DATEID+5);
INSERT INTO `holiday_dates` (`id`, `date_id`, `date_value`) VALUES -- DONE.
(@HOLIDAYID, @DATEID,   335921152), -- 2020-01-24.
(@HOLIDAYID, @DATEID+1, 352681984), -- 2021-01-23.
(@HOLIDAYID, @DATEID+2, 369459200), -- 2022-01-23.
(@HOLIDAYID, @DATEID+3, 386236416), -- 2023-01-23.
(@HOLIDAYID, @DATEID+4, 403013632), -- 2024-01-23.
(@HOLIDAYID, @DATEID+5, 419774464); -- 2025-01-22.

-- Love is in the air. Holiday ID: 423.
UPDATE `game_event` SET `start_time`='2020-02-08 00:01:00', `holidayStage`='0', `occurence`='525600', `length`='20160' WHERE  `eventEntry`=8;
SET @HOLIDAYID := 423;
SET @DATEID := 10;
DELETE FROM `holiday_dates` WHERE `id`=@HOLIDAYID AND `date_id` IN (@DATEID, @DATEID+1, @DATEID+2, @DATEID+3, @DATEID+4, @DATEID+5);
INSERT INTO `holiday_dates` (`id`, `date_id`, `date_value`) VALUES -- DONE.
(@HOLIDAYID, @DATEID,   336707584), -- 2020-02-08.
(@HOLIDAYID, @DATEID+1, 353468416), -- 2021-02-07.
(@HOLIDAYID, @DATEID+2, 370245632), -- 2022-02-07.
(@HOLIDAYID, @DATEID+3, 387022848), -- 2023-02-07.
(@HOLIDAYID, @DATEID+4, 403800064), -- 2024-02-07.
(@HOLIDAYID, @DATEID+5, 420560896); -- 2025-02-06.

-- Pilgrim's Bounty. Holiday ID: 404.
UPDATE `game_event` SET `start_time`='2020-11-23 00:01:00', `occurence`='525600', `length`='10080', `holidayStage`='0' WHERE  `eventEntry`=26;
SET @HOLIDAYID := 404;
SET @DATEID := 11;
DELETE FROM `holiday_dates` WHERE `id`=@HOLIDAYID AND `date_id` IN (@DATEID, @DATEID+1, @DATEID+2, @DATEID+3, @DATEID+4, @DATEID+5);
INSERT INTO `holiday_dates` (`id`, `date_id`, `date_value`) VALUES -- DONE.
(@HOLIDAYID, @DATEID,   346390528), -- 2020-11-23.
(@HOLIDAYID, @DATEID+1, 363167744), -- 2021-11-23.
(@HOLIDAYID, @DATEID+2, 379944960), -- 2022-11-23.
(@HOLIDAYID, @DATEID+3, 396722176), -- 2023-11-23.
(@HOLIDAYID, @DATEID+4, 413483008), -- 2024-11-22.
(@HOLIDAYID, @DATEID+5, 430260224); -- 2025-11-22.


-- Children's Week. Holiday ID: 201.
UPDATE `game_event` SET `start_time`='2020-05-01 00:01:00', `occurence`='525600', `length`='10080', `holidayStage`='0' WHERE  `eventEntry`=10;
SET @HOLIDAYID := 201;
SET @DATEID := 16;
DELETE FROM `holiday_dates` WHERE `id`=@HOLIDAYID AND `date_id` IN (@DATEID, @DATEID+1, @DATEID+2, @DATEID+3, @DATEID+4, @DATEID+5);
INSERT INTO `holiday_dates` (`id`, `date_id`, `date_value`) VALUES -- DONE.
(@HOLIDAYID, @DATEID,   339738624), -- 2020-05-01.
(@HOLIDAYID, @DATEID+1, 356515840), -- 2021-05-01.
(@HOLIDAYID, @DATEID+2, 373293056), -- 2022-05-01.
(@HOLIDAYID, @DATEID+3, 390070272), -- 2023-05-01.
(@HOLIDAYID, @DATEID+4, 406274048), -- 2024-04-30.
(@HOLIDAYID, @DATEID+5, 423051264); -- 2025-04-30.


-- Noblegarden. Holiday ID: 181.
UPDATE `game_event` SET `start_time`='2020-04-13 00:01:00', `occurence`='525600', `length`='10080', `holidayStage`='0' WHERE  `eventEntry`=9;
SET @HOLIDAYID := 181;
SET @DATEID := 13;
DELETE FROM `holiday_dates` WHERE `id`=@HOLIDAYID AND `date_id` IN (@DATEID, @DATEID+1, @DATEID+2, @DATEID+3, @DATEID+4, @DATEID+5);
INSERT INTO `holiday_dates` (`id`, `date_id`, `date_value`) VALUES -- DONE.
(@HOLIDAYID, @DATEID,   338886656), -- 2020-04-13.
(@HOLIDAYID, @DATEID+1, 355663872), -- 2021-04-13.
(@HOLIDAYID, @DATEID+2, 372441088), -- 2022-04-13.
(@HOLIDAYID, @DATEID+3, 389218304), -- 2023-04-13.
(@HOLIDAYID, @DATEID+4, 405979136), -- 2024-04-12.
(@HOLIDAYID, @DATEID+5, 422756352); -- 2025-04-12.


-- Harvest Festival. Holiday ID: 321.
UPDATE `game_event` SET `start_time`='2020-09-29 00:01:00', `occurence`='525600', `length`='10080', `holidayStage`='0' WHERE  `eventEntry`=11;
SET @HOLIDAYID := 321;
SET @DATEID := 14;
DELETE FROM `holiday_dates` WHERE `id`=@HOLIDAYID AND `date_id` IN (@DATEID, @DATEID+1, @DATEID+2, @DATEID+3, @DATEID+4, @DATEID+5);
INSERT INTO `holiday_dates` (`id`, `date_id`, `date_value`) VALUES -- DONE.
(@HOLIDAYID, @DATEID,   344391680), -- 2020-09-29.
(@HOLIDAYID, @DATEID+1, 361168896), -- 2021-09-29.
(@HOLIDAYID, @DATEID+2, 377946112), -- 2022-09-29.
(@HOLIDAYID, @DATEID+3, 394723328), -- 2023-09-29.
(@HOLIDAYID, @DATEID+4, 411484160), -- 2024-09-28.
(@HOLIDAYID, @DATEID+5, 428261376); -- 2025-09-28.
Branch-3.3.5a Feedback-PatchFix

Most helpful comment

Okay good news, the duration of the events is in fact sent by the packet so it can be modified. Just need to think about a nice way to do this and it will be done.

All 39 comments

inb4 @illfated appears and tells you that you should sql markdown ;D

Havent checked the events yet, Feast of Winter Veil, Hallow's End and the other events that you dont cover still work correctly?

meh, how do I do that? xD

the other events are not effected and currently work. but will need updating at some point though. As will the ones I have changed in 5 years.

nvm, done.

How did you actually come up with these numbers? Did you just extract them from a newer client?

@Jinnaix : Thank you for the irony/slight sarcasm. 😄

@natnat201193 can you tell us how you calculated it?
we dont have any documentation about that.

@Keader @Ovahlord
I used the blizztime calculator found here https://model-changing.net/files/file/66-wow-blizztime-calculator/

Then once I added the values to the database, I used:
UPDATE `holiday_dates` SET `date_value` = `date_value` & ~0x3FFF; -- All holidays start at 00:00 in 3.3.5 + some unneeded bits
found in https://github.com/TrinityCore/TrinityCore/commit/951fa46fe9b14a9e275ac9306b2346959e40e3e5

then I just extracted the updated values

I actually have no idea how the values are calculated from that Calculator, but the source code is included in the download if anyone wants to check it out.

It would be nice if these dates could be just added to the database in an actual date format and have the core convert it to a code instead.

cool, ty.

oh and when using the Calculator for these events, I only checked the Use Year box and kept Use Day of the Week unchecked.

Lunar Festival End: 2020/02/07 not 2020/02/13 (It's the only error, everything else is correct)

image

Read the original post...
I explained that as far as I'm aware, we cannot currently change the end dates shown in the Calendar without clientside edits. Only the start dates, the reason lunar festival is that long is because it was that long the last time blizzard updated it in the 3.3.5 client. If you look in the Holidays.dbc, you will see that Lunar festival is 504 hours long, as in 21 days, which is in line with the duration of the last Lunar festival that occurred in 3.3.5.
@Killyana

if you look back in time on the Calendar, you will see older Entries also show 21 days. so unless someone can find a way to modify the end date shown on the calendar without clientside edits, we are kinda stuck on that part.

The one event that lasts a bit longer due to this is Lunar festival, it shows 21 days on the Calendar which we cant change as far as I'm aware, so I just made it match.

Before anyone says 21 days is not blizzlike, I know it's not and we won't get blizzlike unless we update the dates to match the real-world events like blizzard does, this would need clientside edits.
If you don't want it to be 21 days, you can always adjust the length, but it won't match the Calendar if you do.

From what I've seen in the dbc files, the client actually has the correct duration in different columns. I did not check yet in how far packets can influence the column selection but I might find a way.

yeah, if someone can find a way to do it, that would be fantastic.
Also, I think all events with a Holiday ID should not be in game_event, they should be in a new table specifically tailored to handling those events the way blizzard does. Not something I have the Knowledge to implement, otherwise I would.

Data in the dbc is correct (504h = 21 days), the original duration in wotlk was 21 days and it was changed in later expansions:
https://wow.gamepedia.com/Lunar_Festival#Dates

2012 | January 23 | January 22 - February 11 (21 days)
-- | -- | --
2013 | February 10 | January 27 - February 9 (14 days)

yup

they actually change it based on the Chinese lunar new year.

"It appears that Blizzard moves the dates of this event to conform to the real-life Chinese Lunar New Year on which this festival is based."

Year | Lunar New Year date | Lunar Festival dates
-- | -- | --
2006 | January 29 | January 27 – February 14
2007 | February 18 | February 16 – March 8
2008 | February 7 | February 5 – 23
2009 | January 26 | January 24 – February 12
2010 | February 14 | February 14 – March 7
2011 | February 3 | January 23 – February 12
2012 | January 23 | January 22 - February 11
2013 | February 10 | January 27 - February 9
2014 | January 31 | January 20 - February 3
2015 | February 19 | February 16 - March 2
2016 | February 8 | February 1 - February 15
2017 | January 29 | January 21 - February 4
2018 | February 16 | February 17 - March 3
2019 | February 5 | January 28 - February 11

https://wow.gamepedia.com/Lunar_Festival

Okay, so the first mistake that I have figured out right away is: events start at 1:00 AM, not 0:00. I have picked Pilgrimm's Bounty's very first event time and it's exactly:
161824832

The date of the provided BlizzTime is: TimeZone: 0, Year: 2009, Month: 11, Day of Month: 22, Day of Week: 0, Hour: 1, Minutes: 0

So accordingly the times need to be corrected. I have checked all times up to 2013 and they always start at 1 AM. I have written a little tool for this to check and this is the absolute number that the dbc data have

nice, I only set them all to 00:00 because of what was said in https://github.com/TrinityCore/TrinityCore/commit/951fa46fe9b14a9e275ac9306b2346959e40e3e5

UPDATE `holiday_dates` SET `date_value` = `date_value` & ~0x3FFF; -- All holidays start at 00:00 in 3.3.5 + some unneeded bits

And I can't remember what they were in 3.3.5, it's been too long and I never took much notice of events back then.

I'm a total noob here, been using the updated Jeutie's Repack for 3.3.5 (I guess now it's called the AC-Web Repack but that was the start). How do I use these updates, please? I see on HeidiSQL that I can copy-paste the code text up there to the bottom window in places, but I don't know which database to put the changes into and don't want to mess up my game. Is it world->holiday_dates? World->game_events? World->event_scripts? I don't know what to do. Thanks for any help.

I'm a total noob here, been using the updated Jeutie's Repack for 3.3.5 (I guess now it's called the AC-Web Repack but that was the start). How do I use these updates, please? I see on HeidiSQL that I can copy-paste the code text up there to the bottom window in places, but I don't know which database to put the changes into and don't want to mess up my game. Is it world->holiday_dates? World->game_events? World->event_scripts? I don't know what to do. Thanks for any help.

Double click the world database, paste the SQL into the query box and Execute. The query selects the Holiday_dates table already if it exists. then restart the server.

Here some data about what event is suposed to start when:

  • Noblegarden: 0:00am, Sunday
  • Children's Week: 0:00am, Sunday
  • Harvest Festival: 0:00am, Monday
  • Lunar Festival: 6:00am, Saturday --> later it got corrected to 0:00am, Saturday (2013 entry)
  • Pilgrim's Bounty: 1:00am, Sunday --> consistent throughout all years
  • Love is in the Air: 0:00am, Sunday

These were pulled from DBC data by using their first entry.

I'm a total noob here, been using the updated Jeutie's Repack for 3.3.5 (I guess now it's called the AC-Web Repack but that was the start). How do I use these updates, please? I see on HeidiSQL that I can copy-paste the code text up there to the bottom window in places, but I don't know which database to put the changes into and don't want to mess up my game. Is it world->holiday_dates? World->game_events? World->event_scripts? I don't know what to do. Thanks for any help.

Double click the world database, paste the SQL into the query box and Execute. The query selects the Holiday_dates table already if it exists. then restart the server.

Hmm I must not have done something right. Followed those directions, then closed everything down and restarted, and none of the holidays are there still. I copy-pasted all of the updates up there to the query window like you said. I don't know how to save; thought it auto-saved changed like that. There's no button to execute.

Edit: Nevermind, got it! Just needed to right-click in the query window and click "Run". There they are! Thanks again! :D
We're all gearing up for Chun Jie at home and I wanted to see when the Lunar Festival stuff was this year, and it wasn't there! So glad this wasn't just a my client issue.

Okay good news, the duration of the events is in fact sent by the packet so it can be modified. Just need to think about a nice way to do this and it will be done.

87c79c9485cbb9536912e1566174c717946c1537 there you go. You may now fully update holidays including their correct duration. Technically you could make them last the entire year now lol.

@Ovahlord guess clientside edits are not needed afterall, nice one <3

so, the only way I can update Lunar festival to start on a Saturday is by using the previous Saturday, if I try to use the following Saturday, it's going to overlap with Love is in the Air by a day. this is possibly the same for some others. I don't think the day of the week really matters much or the time even.

considering that still is not blizzlike, as I mentioned previously. blizzard update a lot of these dates based on real-world events. so the only way to make it blizzlike would be to specify different dates constantly that are exactly the same as blizzards current dates, we don't currently have support for that in game_events.
At least not without having to update the dates every year.

This is why we really need a new table just for events with a holiday ID, something that is very much like the holidays.dbc with date1, date2, date3 etc.

And I'm talking about something to replace game_event for these events, not holiday_dates.

or something to make these holidays use the dates in holiday_dates only instead of using occurrence and length from game_event

so I'm not quite sure what you want me to do, I think just using the current dates and times, for now, is fine.
Just updating the lunar festival duration in game_event and holiday dates should be ok until/unless a proper system to handle it how blizzard does is put in to place.

It's also a pain in the ass to update all of these all over again with my current method.
If someone can update the blizztime calculator to produce a fully accurate date code, that would help.

I've written a small tool that lets you read and generate date times up to hours:
https://github.com/The-Cataclysm-Preservation-Project/Packet-BlizzTime-tool

nice, I'm not quite sure how to compile that seeing as there is no solution added though. the only thing I can really compile is hello world and TC/other wow cores, cause guides :p
I'm not really a coder, can only do basic things here and there working with examples.

Sorry @Killyana didn't really think about it at the time, but with the current Lunar festival length, its going to overlap with Love is in the air and cause issues with spawns, included SQL below to correct it.

UPDATE `game_event` SET `length`='20160' WHERE  `eventEntry`=7;
UPDATE `holiday_dates` SET `holiday_duration`='336' WHERE  `id`=327;

Do you mean

UPDATE `game_event` SET `length` = 20160 WHERE `eventEntry` = 7;
UPDATE `holiday_dates` SET `holiday_duration`=336 WHERE `id`=327;

... or is length and holiday_duration purely text content?

@illfated I did ``` how do I do the SQL one xD

@natnat201193 You do

``sql UPDATEgame_eventSETlength= 20160 WHEREeventEntry= 7; UPDATEholiday_datesSETholiday_duration=336 WHEREid`=327;
```

But I think illfated was asking why you used ' ' over your numbers for length and holiday_duration if I understand correctly

ty and that's cause I just adjusted the values and copied the SQL that was produced by Heidi SQL, didn't write it out myself as I did with the others.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Rushor picture Rushor  Â·  3Comments

jerbookins picture jerbookins  Â·  3Comments

funjoker picture funjoker  Â·  3Comments

DDuarte picture DDuarte  Â·  3Comments

Jildor picture Jildor  Â·  3Comments