-
June 2nd, 2023, 03:25 #171
I've been having issues adding leap years to my calendar.
I'm trying to do something similar to the Gregorian, but extra days on years that are multiples of two (instead of four), not multiples of 10 (instead of 100) except for multiples of 50(instead of 400).
Unfortunately, the extra days are not being added.
Experimentally, I've tried applying rollover days and that appears to work, however I do not want them.
-
June 2nd, 2023, 13:54 #172
You are missing a <periodvarcalc> tag in your module db.xml.
For example, in the gregorian calendar you have both a lunardaycalc tag so that the days of the week line up correctly on the calendar (ie, if Feb 28 is a Wed, then Mar 1 is a Thur). And it has a periodvarcalc to add days to Feb when the conditions are correct.
Code:<lunardaycalc type="string">MKgregorian</lunardaycalc> <lunarweek> <day1 type="string">Sunday</day1> <day2 type="string">Monday</day2> <day3 type="string">Tuesday</day3> <day4 type="string">Wednesday</day4> <day5 type="string">Thursday</day5> <day6 type="string">Friday</day6> <day7 type="string">Saturday</day7> </lunarweek> <periodvarcalc type="string">MKgregorian</periodvarcalc>
For support with any of my extensions, visit my #mattekure-stuff channel on Rob2e's discord https://discord.gg/rob2e
-
June 2nd, 2023, 22:13 #173
-
June 7th, 2023, 00:09 #174
- Join Date
- Oct 2020
- Location
- Washington DC
- Posts
- 8
I want to do the Mayan calendar which has two calendars that interlink and the same day combination only repeats every 52 years.
-
June 9th, 2023, 02:26 #175For support with any of my extensions, visit my #mattekure-stuff channel on Rob2e's discord https://discord.gg/rob2e
-
July 3rd, 2023, 03:32 #176
Out of curiosity, does anyone know how to do a month with two different lengths of the week (7 day/8 day)?
We have a setting that has a 7 day week, a fortnight which consists of two weeks with a Festival day inbetween, and a month that consists of two fortnights (30 days). I figured the easiest way is to code the first and third week as 8 days, and the 2nd and 4th as 7 day weeks.
Right now, our workaround is to just make a 15 day week, with seven of the days repeating themselves. But this is ... inelegant to look at.
-
January 3rd, 2024, 23:20 #177
- Join Date
- Aug 2023
- Posts
- 11
How many moons can this track?
-
January 3rd, 2024, 23:23 #178
This thread is about creating custom calendars, it does not do anything with moons. You might get better answers with this moon tracking extension. https://forge.fantasygrounds.com/shop/items/172/view
For support with any of my extensions, visit my #mattekure-stuff channel on Rob2e's discord https://discord.gg/rob2e
-
January 3rd, 2024, 23:42 #179
- Join Date
- Aug 2023
- Posts
- 11
I was under the impression that the lunar day handler had a lunar tracking function?
Also, will that extension handle 'moons' whose period is greater than a year?Last edited by GM Ithril; January 3rd, 2024 at 23:45.
-
January 3rd, 2024, 23:50 #180
Ah, super easy mistake to make, and mostly my fault. Too much code on the brain when I named it. Inside the FG calendar system is a function which returns the day of the week a particular date falls on. So for example, if you were to pass it the Mar 3, 1542, it would return some value which represents Sun-Sat. That function is called a lunar day handler (I dont know why, I didnt name it) and has nothing to do with the moon. The extension attached is a generic form of that function which allows for calendars without leap years to easily calculate what day of the week a particular date falls on. Without it, each calendar would have to include its own custom extension with this function defined.
For support with any of my extensions, visit my #mattekure-stuff channel on Rob2e's discord https://discord.gg/rob2e
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks