migrate to int ids for location primary key + manual event_name
authorxangelo <git@xangelo.ca>
Sun, 18 Jun 2023 10:12:36 +0000 (06:12 -0400)
committerxangelo <git@xangelo.ca>
Sun, 18 Jun 2023 10:12:36 +0000 (06:12 -0400)
commit281fa0ac7deb8dd281d8eb1677d77cd98409c75b
tree09f3a0e615e6de0893b185324ec300ba66b7ec33
parent700898b7dbaa98761ac1a9aeee86540769fce888
migrate to int ids for location primary key + manual event_name

Rather than generating the event name from the id/type of the location
we've instead made the id's autoincrementing integers with a custom
event_name field that defines the event they trigger.

It makes it a lot easier to build generic functionality and we can
always swap the id's to uuids if we really care that much.
12 files changed:
migrations/20230618095248_location_events.ts [new file with mode: 0644]
public/assets/bundle.js
seeds/cities.ts
seeds/monsters.ts
src/client/index.ts
src/events/explore/server.ts
src/events/windcross-events/server.ts
src/server/api.ts
src/server/monster.ts
src/shared/inventory.ts
src/shared/map.ts
src/shared/monsters.ts