Arx-Game / arxcode

A text-based/web game using Evennia.
MIT License
47 stars 42 forks source link

Timezone Support for Events #28

Open rozzingit opened 6 years ago

rozzingit commented 6 years ago

Is your feature request related to a problem? Please describe. I am lucky! I live in server time. Others are not so lucky and have to go through the process of converting event times to figure out when they are in their home timezones.

Describe the solution you'd like How I've seen it done on other codebases involved people being able to set their timezones on themselves (would be great for it to be shared across alts, probably) and then looking at @cal would give them event dates/times in their own timezone, and when they would create new events, they could put in the time in their home timezone and it should convert for others.

So server time is always American Eastern. Sao sets her personal timezone as being American Pacific. Now when she looks at the +events list, at specific events on the game, or at the event list on the website, they show up with their times displaying her timezone. When she makes a new event, it takes the time she puts in and treats it as Pacific and then translates that to the other timezones.

TehomCD commented 6 years ago

We could mimic timezone support in some hacky way, like storing someone's offset in an Attribute and then converting timezone displays in some places with it. However, this wouldn't work easily for places where a timestamp is stored as text, like board posts: you'd need to do some regex where it finds things that look like a timestamp and converts them, and that'd be pretty much on a case-by-case basis wherever. True timezone stuff with timezone-aware datetime objects in the database is not a trivial thing to do, and would both require database work and presentation stuff everywhere they're used.

wahoo2 commented 4 years ago

DEAR GOD PLEASE, even if it's just for @cal