Jump to content

Recommended Posts

Sorry if I missed this earlier in the thread. For the odds on event I was trying to figure out how they work in practice. For example in release events it shows normal release having 0% chance and say, simple slavery as 50% chance, if its 0 and 50 does that mean the simple slavery event would happen every time, or do default events just show as zero and will happen if the other events (such as 50% for simple slavery) do not trigger?

 

Also speaking of events like single slavery, is it possible to have it as a potential "daily" event as well. I know it can be set as a release event but that would make it the same odds whether it's a pickpocketing sentence or a  murder one. I was trying to make it so such an event is never certain but the odds of it happening scale to the severity of the bounty that got you locked up (like with a mod that extends the possible maximum jail sentence to 100 days depending on bounty, making the chance per day of being sold into slavery 2% per day. Otherwise is there any other way to make the odds of simple slavery or execution if that's available later scale with bounty severity?

Link to comment
17 hours ago, Lockou said:

Sorry if I missed this earlier in the thread. For the odds on event I was trying to figure out how they work in practice. For example in release events it shows normal release having 0% chance and say, simple slavery as 50% chance, if its 0 and 50 does that mean the simple slavery event would happen every time, or do default events just show as zero and will happen if the other events (such as 50% for simple slavery) do not trigger?

Those are relative probabilities. which means that in this example SS would always trigger if its conditions are met (it requires your crime severity to be at medium or high).

An event which is set to 0% will never fire.

Exception is the Default Event. Even when set to 0%, it will fire if nothing else is available or has its conditions met.

 

I´m still working on the API and the documentation, but since you seem to be eager, i´ll give you a quick tutorial:

-In the scripts folder, theres a file called "pamaPA_ExampleEvent.psc". This is a template for new events.

I´ve added plenty of comments there to help users, but there are 2 Important functions you want to look at

 

1: the condition check

Bool Function CheckPluginConditions(Actor Prisoner, Actor Follower, Actor thisLocationsDetainee, Faction JailorCrimeFaction, int crimeSeverity, int currentDay, int maxDay, int NumberMisconducts, int restraintSeverity, Armor currentCuffs, ObjectReference PrisonBed)
	

the argument "crimeSeverity" ranges from 1-3, 1 being petty crime, 3 being major crime.

 

If you want the daily 2% chance you described, you'd have to write the function into something like this:

Bool Function CheckPluginConditions(Actor Prisoner, Actor Follower, Actor thisLocationsDetainee, Faction JailorCrimeFaction, int crimeSeverity, int currentDay, int maxDay, int NumberMisconducts, int restraintSeverity, Armor currentCuffs, ObjectReference PrisonBed)
	if utility.randomInt(2, 100) <=2
    		return true
  	else
  		return false
  	EndIf
EndFunction

Im sure you can figure out how to implement some scaling with crimeSeveity.

 

keep in mind this 2% chance would be multiplied with the MCM propability, so youd have to leave that one at 100%

 

 

2: The function Body "ExecuteEvent"

Not gonna give you the full exerp here, since the comments should point you in the right direction. You could also take a look at the inluded SS event script and copy from there.

 

 

Now, since you want it as a daily, rather than a Release event, you just have to attach the finished script to an alias pointing at the player (as written in the docs), and set the inherent properties like this:

Doc.jpg.c681db5d14450dd9dccc1ce80c2ab8a0.jpg

 

(If you want to be lazy, you could ofc just copy the esisting SS event, rename it, and set the properties accordingly.)

 

 

As mentioned, the API isn't finished yet. but this will work if you need it right now.

Link to comment

Heh sorry, I have never done skyrim modding before (other then installing mods ) I was even just curious if it was in the realm of possibility or not . though looking into what you said. I opened up the psc file for the simple slavery with a text editor and can't find where i would set the daily or release event parameter, and just wanted to check, in that screenshot, what software is being used? The screenshot cuts off the name of the program

 

Is it possible to quickly edit an event from release to daily somehow? (had originally thought i could like set simpleslavery from release to daily with a small edit but cannot find it) or would that cause everything to go catastrophically haywire? Was thinking of installing https://www.nexusmods.com/skyrim/mods/10060/ to make it longer then 7 days and have it be a tiny "suspense" chance with each day, making longer sentences more dangerous for the character, the rest of the parameters for how it sends them to simpleslavery would be the same I suppose? (unless I am wrong)

Link to comment

Heh, this gives me some event ideas.

 

  • Solitude: Sybille Stentor shows up for a little snack OR a torture session. (Technically lore friendly as per commentary from Melaran!)
  • Solitude: Erikur drops by for some "fun". (Could be dependent on if the player is an elf variety and female.)
  • Solitude: Bjartur (the woman in the cell) gets smacked around along with the player.
  • Riften: Sibbi Blackbriar tells the guards he wants a little "action". (Female dependent.)
  • Riften: Wylandriah needs a test subject to try out her latest potion. (Eyesight turns colors, catch a disease, nothing happens, or even teleportation.)
  • Riften: Maven's had a bad day and takes it out on a prisoner. ?
  • Riften: Threki the Innocent gets smacked around along with the player.
  • Whiterun: Nazeem shows up to inflict some pain instead of the torturer.

  • Windhelm: Rolff Stone-Fist (the annoying guy when you first enter) shows up to both give the player a piece of his mind and maybe some lashes. (If player is anything but Nord/Imperial/Breton.)

  • General: Guards want some "fun" from the player. (Should probably be switchable for each hold. Riften is likely the only one where it makes sense aside from Markarth which isn't covered here.)

Might implement a few these myself if I get a moment. :face_dragon:

Link to comment
On 6/15/2021 at 11:05 PM, Lockou said:

Heh sorry, I have never done skyrim modding before (other then installing mods ) I was even just curious if it was in the realm of possibility or not . though looking into what you said. I opened up the psc file for the simple slavery with a text editor and can't find where i would set the daily or release event parameter, and just wanted to check, in that screenshot, what software is being used? The screenshot cuts off the name of the program

I see.

The Software here is the Creation kit. You wont get anywhere without that.

Also, editing .pcs files has no effect on the game. The game gets its information from the corresponding .pex files.

The psc´s are merely used by the compiler to generate said .pex files

 

On 6/15/2021 at 11:05 PM, Lockou said:

Is it possible to quickly edit an event from release to daily somehow?

Not a really "quick way". just editing the script properties which determine the Event type could be done with TESVEdit, but you´d have to make a minor edit to the papyrus script as well, since Release Events have a slightly different structure than Daily/punishing Events.

But without any basic knowledge about modding, you probably wont get far.

 

On 6/15/2021 at 11:05 PM, Lockou said:

Was thinking of installing https://www.nexusmods.com/skyrim/mods/10060/ to make it longer then 7 days

This has absolutely nothing to do with the "Days" used by PA.

Link to comment
On 5/23/2021 at 10:35 AM, Pamatronic said:

HOWEVER, a quick test revealed, that the PAPYRUS engine would Deadlock if  DD`s SKSE plugin was present. why?

Because it changes the native game functions which are responsible for equipping/unequipping Items.

 

Curious. The plugin never used to do this. I actually just checked the plugin source (bundled with the mod), and no, it does not modify native game functions. The unequip/equip is just handled by standard papyrus events (OnUnequipped). All that the SKSE plugin does is speed up looking for devices / iterating over inventory.

 

The entirety of the SKSE plugin's logic lives in this function, and helper functions for this function (All of which appears to be unchanged since I wrote it years ago):

  TESForm* FindMatchingDevice(StaticFunctionTag* base, Actor* obj, BGSKeyword* kwd) {
    if (!obj) {
      _MESSAGE("ReEquipExistingDevice received NULL obj.");
      return NULL;
    }
    ExtraContainerChanges* containerChanges = static_cast<ExtraContainerChanges*>(obj->extraData.GetByType(kExtraData_ContainerChanges));
    tList<InventoryEntryData>* inventory = containerChanges->data->objList;
    if (!containerChanges || !inventory) {
      _MESSAGE("ExtraContainerChanges failed.");
      return NULL;
    }
    // _MESSAGE("FindMatchingDevice(%s)", GetName(obj->baseForm));
    for(int i=0;i<inventory->Count();i++) {
      TESForm* tmp = inventory->GetNthItem(i)->type;
      if (!tmp) {
	_MESSAGE("Failed to look up item %d.", i);
	return NULL;
      }
      // _MESSAGE("Item %d: %s", i, GetName(tmp));
      if (FormHasKeyword(base, tmp, kwd)) {
	//	_MESSAGE("Found. Returning %s", GetName(tmp));
	return tmp;
      }
    }
    return NULL;
  }

 

Admittedly it's been years since I maintained the project, but I'm surprised to see so much misinformation flying around.

Edited by Min
Link to comment

@Min Didnt notice the .dll source files at first glance and jumped to conclusions because of that. I apologize.

I just couldn't imagine a mod causing a total game freeze just by papyrus means, even when not actively interacting with it.

But it seems I underestimated DD, apparently it doesn't need a .dll to achieve that.

Link to comment
On 6/19/2021 at 12:16 PM, bigglebojiggle said:

Just wanted to add that while you say Go To Bed is partially compatible, Immersive Beds has been working just fine with this mod for me.

Nice to know, but considering the large amount of reported issues with Immersive beds on the Nexus page, I don't feel comfortable recommending it as an alternative to GotoBed.

I´ll probably do a compatibility patch for GoToBed at some point.

 

On 6/19/2021 at 12:16 PM, bigglebojiggle said:

Anyway, do you have plans to implement different types of punishment later on? Different devices/more scenes?

Sure. working on it right know.

Kate here seems to be just as eager as I´am ?

20210619034314_1.jpg.a9e5c0b86798b15e03bddb590a019cf6.jpg

Link to comment
On 6/17/2021 at 1:45 PM, Pamatronic said:

 

This has absolutely nothing to do with the "Days" used by PA.

 

Ah, then I am likely barking up the wrong tree to begin with for getting the effect I was going for, might just try it in a more basic way

 

Just to check, when you set odds for release effects in mcm, do they apply if you already in prison but before release? Or are the release events already set in stone when you first enter prison? Or can the odds for release events be changed in mcm while in the cell?

Link to comment
7 hours ago, Pamatronic said:

Nice to know, but considering the large amount of reported issues with Immersive beds on the Nexus page, I don't feel comfortable recommending it as an alternative to GotoBed.

I´ll probably do a compatibility patch for GoToBed at some point.

 

Sure. working on it right know.

Kate here seems to be just as eager as I´am ?

20210619034314_1.jpg.a9e5c0b86798b15e03bddb590a019cf6.jpg

 

Ah cool. I'm liking the mod so far coupled with SexLab Adventures. Adds a nice change for my usual playstyle

Link to comment
15 hours ago, Pamatronic said:

Nice to know, but considering the large amount of reported issues with Immersive beds on the Nexus page, I don't feel comfortable recommending it as an alternative to GotoBed.

I´ll probably do a compatibility patch for GoToBed at some point.

 

Sure. working on it right know.

Kate here seems to be just as eager as I´am ?

20210619034314_1.jpg.a9e5c0b86798b15e03bddb590a019cf6.jpg

I've been using Go To Bed with this quite happily - just need to change activation method to keypress (for GTB)

Link to comment
2 hours ago, 43deadwood said:

I've been using Go To Bed with this quite happily - just need to change activation method to keypress (for GTB)

 

Only possible in the LE version. The SE version for some reason got rid of the key activation method. ?

 

  • Version 1.4.0

    • added sleepwear
    • removed activation by Key and Power ?

 

That is unless there's another SE version roaming around.

Link to comment

the mod equips the char with ankle chains. and this causes the char to walk very slow. i cant unequip it and it makes this mod very grindy because the walk is even slower than vanilla. i tried togelling god mode, try to forcefully unequip through console, but nothing works.

please let me know how to fix this

Link to comment

As always, I appreciate how you make your work as focused as possible for the concept and to do it well. That said, I noticed something during a test of the mechanics with the Riften jail - after being released, the doors out were also locked with an Expert lock. This happened after a pair of whipping scenes.

 

I also noticed that each scene you trigger counts as being jailed in the statistics; not a big deal, but I figured it'd be good to mention.

 

Also, is it intended to be in jail naked? It automatically drew commentary from the prisoner behind the wall :P May be worth making this a setting for players to decide on.

Link to comment
On 6/26/2021 at 12:30 PM, LD5 said:

As always, I appreciate how you make your work as focused as possible for the concept and to do it well. That said, I noticed something during a test of the mechanics with the Riften jail - after being released, the doors out were also locked with an Expert lock. This happened after a pair of whipping scenes.

Right, the Vanilla Release would return youtzo the outside, so this wouldn't be a problem. I´ll do something about that.

 

On 6/26/2021 at 12:30 PM, LD5 said:

I also noticed that each scene you trigger counts as being jailed in the statistics; not a big deal, but I figured it'd be good to mention.

Technical Side effect. Large parts of the Vanilla prison system seems to be handled by native functions, rather than papyrus ones. which limits my capability to interact with the thing.

I have to re-imprison the player to ensure that stuff like locked doors, guard aggression triggers, and escape detection is properly reset after a scene.

Not a perfect solution, but It took me 4 RL years to even notice the statistics, so i believe this is an acceptable tradeoff.

 

On 6/26/2021 at 12:30 PM, LD5 said:

Also, is it intended to be in jail naked? It automatically drew commentary from the prisoner behind the wall :P May be worth making this a setting for players to decide on.

Thats intended. The changed prison outfit is a part of the esm, rather than scripted, which makes it impractical as a user setting.

If someone really doesn't want that, he can use TESVEdit to remove the edits to the crimeFactions. Alternatively, any other mod which modifies crimeFactions will overwrite this setting anyway.

Link to comment
Quote

I have to re-imprison the player to ensure that stuff like locked doors, guard aggression triggers, and escape detection is properly reset after a scene.

 

That explains some things. Was doing some testing just now for a mod that adds more prisoners. (Not the one here, a different one.) And sure enough, due to using leveled lists, the prisoner sharing your cell when you go in is different when you "wake up" after a beating. ?

 

One semi-big issue: if people are using any mods that start Sexlab anims between NPCs randomly there is a chance of a crash after the player is done getting smacked around. If the NPCs involved in the anim are temporary (like more prisoners, etc) than those NPCs will be zapped when the player is "put back into jail". Thereby causing a big mess. ?

 

EDIT: I noticed the crash only will occur if the player "wakes up" while a temporary NPC is involved in an animation. Otherwise no issues. Still: turn that stuff off in jail folks! ?

Edited by Nessa
Link to comment

Hi. I have another question about this mod.

It will work with Sexist/Derogatory Guards ?

 

Thanks in advance for replay.

 

Regards

Also... on Nexus is old and criminaly underappreciated mod called Suspicious City Guards https://www.nexusmods.com/skyrim/mods/65681 

I was wonder can you implemented to make work yours mod with Suspicious City Guards... That means if player doing something wrong in City ( public place ) can go to "yours" mod prison cell ( to add more flavout to yours mod 

Edited by LenaLachrymosa
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more information, see our Privacy Policy & Terms of Use