Extensions:World Expansion

From Lorekeeper Wiki
Revision as of 11:12, 28 April 2023 by Preimpression (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
World Expansion
Description Adds some worldbuilding functionality to LK sites
Author(s) Preimpression
Status testing
Github extension/world-expansion
LK Version 2.0.0
Contains a Migration






Referred to in-site as World Expanded.

World Expansion adds the following to Lorekeeper:

  • Locations (and Types)
  • Events (and Categories)
  • Figures (and Categories)
  • Fauna (and Categories)
  • Flora (and Categories)
  • Concepts (and Categories) - Thanks Mercury!
  • Factions (and Categories), Faction Ranks - Thanks Mercury!

Installation

  1. Pull the branch and fix and conflicts manually.
  2. Migrate to add tables with the command: php artisan migrate
  3. Add site settings and world page with the command: php artisan add-world-expansion
  4. Add to extension tracker: php artisan update-extension-tracker
  5. Use the command php artisan add-faction-currency to add the faction standing currency.

Configuration

If you want to add more Display Styles for locations, they are housed in the Location model.

To edit the main World page (found at site.com/world/info), you may edit it at the same place as regular Pages. If you remove the page with the key world, the page will break.

Settings

There are settings in the Site Settings that will need to be toggled in order to:

  • Allow users to have locations attached as their homes
  • Allow characters to have locations attached as their homes
  • Set time limits to how often users can change their own home locations and factions
  • Allow users to have factions attached
  • Allow characters to have factions attached
  • Identify the currency used to track faction standing. This is added and set automatically as part of the php artisan add-faction-currency command.

Display of Associated Things

Most of the associated parts (items, locations, etc) on individual pages have commented-out versions that are the thumbnails of the various items/locations/etc.

Usage

Notice: If you delete any categories, the things within those categories will be deleted.

In order to create locations or factions, you will need to add a location type or faction type. Once the following are created, you will be able to attach or add:

  • Locations: (Users/Characters) Specialized Styles (such as Island of Man vs Man Island), Gallery Submission (from the submission side)
  • Events: Figures, Locations
  • Figures: Items, Faction
  • Fauna: Items, Locations
  • Flora: Items, Locations
  • Concepts: Items, Locations
  • Factions: (Users/Characters) Events, Figures, Locations, Ranks

Faction Ranks

Ranks are created within the create/edit faction form. Ranks may be:

  • Closed (finite, manually set by staff), or
  • Open (infinite, available to regular members of the faction).

Filling positions on closed ranks is available once the rank has been created. These positions can be filled by any figure, user, or character that is a member of the faction.

Open ranks by must have a set breakpoint (the minimum amount of standing a faction member must have to have that rank). Standing is tracked via a currency, which is the same across all factions. It may be customized as desired. Open ranks and standing are supported for both users and characters.

If a user or character leaves their current faction/switches factions, their faction standing is reset to 0 and they are removed from any closed ranks they held. Figures are also removed from any closed ranks if their faction is switched.

Faction pages display the faction's ranks (if it has any), with leadership (closed ranks) in one column and membership (open ranks) in another; leadership ranks display both information about the rank itself as well as any members with that rank, while open ranks display only rank information including breakpoint. This section also links to a page listing all user/character members of a faction, which displays the member's name, rank (if they have one), and current standing.

Frequently Asked Questions

Is this on v.2.0.0 release branch?

Yes!, thanks to Mercury, who also added Concepts and Factions!

Does everything need a category to create?

No, only 'factions' and 'locations' need a category/type to create.

I don't want to use Categories for XYZ

They're required by the extension, so my suggestion is to create one category, such as "Faction" or "Location" and simply use that for all of your factions or locations.

I want to link more things, like characters to figures, etc

You'll need to do several things. For this reason, unless multiple sites want a particular link added, I'll leave this up to you.

  1. Create a migration for a table to link many-to-many
  2. Create a model for this new link
  3. Edit the controller, service, and form to include this new link (Look at existing links)
  4. Edit the existing models to have Relations to the new Model you created
  5. Edit the blades to show the newly linked things.

I'm possibly missing some important things, but if you look at the existing links you should be able to figure them out!

Troubleshooting

No errors are currently known - if you find any issues, let me know on the Discord! (Uri#2154)

See Also

Extensions:Page_Categories by Juni also has Lore Pages, which are awesome!