In depth Guide for Slavers Of Skyrim

Chapter:	Player conquere location, manage and defend or lose
Modul: Player Claim Modul
-------------------------------------------
Written for: Stage 2
in the year of: 2025
Month: 1
Day: 07
-------------------------------------------
___________________________
Player Claim location:
----------------------------

when palyer clear a slaver base lcoation, may chose claim to it self.
this means the control ower the location given to the player, player become the owener of that place.
this open up new activitys to the player, and options.

conquering a location not a easy task, and shuld newer been!

To start the procces player need cast the spell: SLOS conquere location spell
This start the conquer location quest, the quest used to check the player curent location valid for conquer.

Requirement here:
-its a location
-location has slaver base keyword
-location has one of the slaver base type keyworld: marketplace, slave camp, slave owener base
-no slaver character preset
-player has avible conquere location quest that not running but can be started

in case all requirment meet the slaver base calimed by player.
display the location speciific user interface menu

if player has no capture faction need to give it to it.
if player has no spell toget acces the slaver base user interfacce need give it to it.

capturing slaver base need generate a event that can be proccesed by the slaver guild entity and other sub modules, like attack player conquered location.

the avible playerclaim quest can be found:
SLOSPlayerClaimQuestList

active list registered here:
SLOSPlayerClaimActiveQuestList 

Active locations:
SLOSPlayerClaimActiveLocList 

in case the first location that player going to claim a special quest started:
SLOSPlayerClaimlocationHandlerQST

this quest assigned to store the location list player conquered and keep track varius variables.

___________________________
Conquered locations and restart:
----------------------------

Upon system restart if called from the slos script manual - debug menu-restart core:
the system preserve your slaves, your mercanarys and your locations.
this means all you own got safly stored away as the system reset occur.

if for any reason you stop the mod script modul( SLOS Core ), on next start up you realsie all your slaves and conquered or brought location gone.
Reason for this: when the scripting core stopped evrything go stop, all your mercanarys going to be deleted, all your slaves freed, all location you conquered given back to former oweners.
This happen becuse evry change that made repreented by quests that running and active but as core scripting system stops this quest too stopped.

___________________________
Player buy locations:
----------------------------
other possible way to buy certin slaver bases, this can be done via talking shady figure, asking to buy special workplace.

This case no need fight or use any violance to conquere the location its freely given to the player if location control quest avible.

The location after brought act as any other slaver base, only difference claiming this location not triger negative response from any slaver faction.

___________________________
Signaling player control a location:
----------------------------

Player added a faction:
SLOSPlayerClaimLocationFaction

this means player own at least 1 location
player added this faction when first get owener of a location.
Olny got removed from this faction when lose control all of its location.

___________________________
Player Claim location handler:
----------------------------

this sub modul in charge to control, procces, register the events around player controled locations/bases.
started to run when player claim the first location and shut it down if player lost the control of the last location.

=======================
Dialoge options:
=======================

1 - Slave realeted options:
-in slave market player can buy or sell slaves - to do this player need inside slave market, need to go the slave want buy/sell and tell the slave going to buy it. this trigger the dialoge of selling buying.
-player can order its salves to fallow - this assigns slave to player storage
-player can order slaves to stay this base, its used when player inside a player owned location. this command assign slave to local storage
-realsie slave - remove slave from slavery

Player slaves stored inside the player owened location storage OR the player personal slave storage.
Player personal slave storage exist on player location handler quest.
if a salve added to player personal storage the slave recive the fallow player package so its goign to fallow as long as player not put on local storage.
local storage order salve to sadbox.

player slaves Flagged as when inside player personal storage: SLOSPlayerSlaveFaction
player slaves flagged when on player owened location as: SLOSPlayerClaimLocSlaveFaction

2 - Mercanary realted options:
2 - A - hiring mercanarys:
-Player can recuit mercarys using Shady figures, this give Whatan mercanarys to player

in case of hireing mercanarys are created by placeatme() command.

2 - B - Orders to mercanarys:
-player can order its mercanrys to fallow the player or stay ( this add / remove mercanary to/from SLOSPlayerFollowItFaction , if in this faction they follow the player using follow package )
-dissmis this case mercanry leaves player service, dismissed mercanary removed from the game using delete() command.

2 - C - Mercanary managment and other rules:
-player mercanarys stored insdie the PlayerMercanaryArray. The sieze of array limit how many mercanry player has at the time.
-Mercanrys removed only when got killed or dissmised.
-Mercanarys valid targets for slave capture both the slaver guild members and to the player

___________________________
Player manage the claimed locations:
----------------------------

Slave traders work as usual and move betewn slaver bases transporting the slaves.
they dont care who owns the slaver base as long got payed and they pay to.
if you own slaver bases that slave trader use they going to birng you slaves and buy from you.

Slave traders are neutral in general even if you enemy to slaver guild the traders come and go unharmed! Bussnies most go on!
Owened slaves weakly produce you gold income.

___________________________
Reasons to attack player owened location:
----------------------------

if player manage to ruin the trus of Slaver Guild OR Ring of Zenithar OR conquer any of this location.
The faction going to send a strike team to take back the location.
Faction strike team composition depend on varius factors that depend on the entity internal status.

More details found in:
006-EntityModul-SlaverGuild-Strike
006-EntityModul-LocalLordEntity-Strike

___________________________
Player Defense of claimed locations when attacked:
----------------------------

Local Lord forces Or Slaver guild goign to attack player base.
Both cases player has limited time to arrive the attacked base and defend it with mercanarys.
The attackers can be captured by player if using the right slaver weapon and its charged.

in Slaver Guild case if slaver guild capture the player during the attack the slaver guild attack considered Victory!
Same hold true if player leave the defended location when under attack by slaver guild.

Local Lord forces conduct raid on slaver bases that aim free the slaves, and defeat the resident of slaver base.
in case player controlled slaver base attacked by local lord forces the player only lose control of slaver base if that originaly belonged to Ring of Zenithar.

When the attackers reach the slaver base player get messaged by the system with all revelant infromation.
Plus the attacked salver base show new goal to defend the slaver base and change jornual too!
Player mercanarys play a critical role in defense as evry single mercanary that defending the base grant +1 hour to player reach the location before the raid/sige ends.

================
Technical data:
================
-All attacker can be captured
-Attackers come from a rally point, Slaver Guild attackers from a hidden slaver base, local lord forces come from a jarl place.
-if the attack succsesful player lose:
---all slaves that working/stored on the attacked base
---all mercanarys that inside the slaver base
---if this is the last player claimed slaver base: player lose ability to buy slaves, hire mercanarys