Jump to content

OSA | Skyrim Ascendancy Engine


Recommended Posts

 

Ive updated FNIS like so many blogs have said to so im at abit of a loss

 

There is a difference between updating FNIS and running FNIS.  Did you run GenerateFNISforUsers.exe?

 

Probably where im going wrong then... how do i run it? Just search for it in program files and point and click or is it more intricate than that? If it turns out to be really easy and i just overlooked it im going to kick myself haha

Link to comment

I need an expert here.

Since papyrus felt really clogged as of late I decided to turn logging back on and I'm getting the huge log files people complained about in the past where errors lines such as "<unknown self>.osa.IsAllowed() - "OSA.psc" Line 296" quickly pile up.
What's really weirding me out is that the couple of posts I found where the person with the issue had it resolved just mention updating to version 1.085 solved the issue. And since my current version is 1.085B I'm at a bit of a loss as to why I'm getting an issue that was seemingly terminated.

I've tried messing with the save files between cleaning and uninstalling OSA but whenever I do so it crashes on save, and I don't think the last time I was able to do a clean without breaking them was that long ago. If anyone has an idea please let me know.

Link to comment

I need an expert here.

 

Since papyrus felt really clogged as of late I decided to turn logging back on and I'm getting the huge log files people complained about in the past where errors lines such as "<unknown self>.osa.IsAllowed() - "OSA.psc" Line 296" quickly pile up.

What's really weirding me out is that the couple of posts I found where the person with the issue had it resolved just mention updating to version 1.085 solved the issue. And since my current version is 1.085B I'm at a bit of a loss as to why I'm getting an issue that was seemingly terminated.

 

I've tried messing with the save files between cleaning and uninstalling OSA but whenever I do so it crashes on save, and I don't think the last time I was able to do a clean without breaking them was that long ago. If anyone has an idea please let me know.

 

I've recently seen some of what you're talking about, although we didn't see it while testing 1.085B.  As far as I can tell, it doesn't break your game, it just spams the log.  I'll see if I can figure out what causes it.

Link to comment

 

...

Cool, hope you find it. In case this sparks any ideas I'll mention that lately I've been frequently merging follower esp's so many NPC's I've interacted with have probably been rebuilt into new ID's. Plus with all the messing around I've been doing there's a chance I might have saved during a scene at some point, if that can lead to an issue.

Link to comment

 

 

...

Cool, hope you find it. In case this sparks any ideas I'll mention that lately I've been frequently merging follower esp's so many NPC's I've interacted with have probably been rebuilt into new ID's. Plus with all the messing around I've been doing there's a chance I might have saved during a scene at some point, if that can lead to an issue.

 

 

I'll put it this way.  I would not save while a scene is running.

Link to comment

I'm really wanting to make a module more of a just test. Though could someone point me to a guide per say to make a OSA module?

What are you aiming for? You can check the OSA nexus description and find some guides under "Developer Manual", download the test module there to look at a simple example and check Kinkys post here for a bit more info regarding modules.

There's still a lot of info undocumented but I'm sure any questions you have here will be answered eventually, I've poked my nose into it myself so I'll pitch in if I can.

Link to comment

OSA 1.08*

 

Install instructions:

 

 

...

 

 

I just installed OSA and it asked me whether I wanted to overwrite the same files from SexLab?

I answered yes but I am not really sure what the correct answer is.

 

Did anyone have this issue and how die you answer it?

I figured OSA is the master so Sexlab must the overwritten.

No such problem with Osex.

 

I have to wait an see what happens I guess.

 

regards

Pat

 

Link to comment

 

OSA 1.08*

 

Install instructions:

 

 

...

 

 

I just installed OSA and it asked me whether I wanted to overwrite the same files from SexLab?

I answered yes but I am not really sure what the correct answer is.

 

Did anyone have this issue and how die you answer it?

I figured OSA is the master so Sexlab must the overwritten.

No such problem with Osex.

 

I have to wait an see what happens I guess.

 

regards

Pat

 

 

 

You should let SL overwrite OSA or you should download PapyrusUtil from Nexus separately and install it, letting it overwrite anything it needs to overwrite.

Link to comment
Guest ffabris

OK, so questions from a modder's perspective ... but first one thing: any way to change the font size? I had some text on screen that is too tiny to be legible. I have no idea what it says. And this is in a 1024x768 window.

 

Anyway, wanting to explore how to write mods that make use of this, I looked at the papyrus interface. Nice and simple. :) But, given that I'd like to trigger specific types of scenes (based on the story line), is there any way to determine, run-time, what scenes are installed, and what type they are? I'd rather not hard-code a list, as that would exclude any new scenes that might be created in the future. The only sample code I've seen is in Amorous Adventures, and that seems to always use "Auto" for the scene, which presumably means "run a scene at random".

 

Thanks in advance. :)

 

Added: Since this hasn't been addressed yet, i'll add to it rather than making a new post.

 

Is there a way for a script to know when a scene ends so that a quest-type story can continue? From what I've seen, thee isn't, which rules using OSA for quite a large portion of mods.

 

How about multiple scenes at the same time? Example scenario would be a brothel, where you might want to have several NPCs making out while the player haggles for "company". ;)

Link to comment

...

Seems like at least the issue isn't necessarily related to version upgrading or adding the mod midgame, it can happen to a fresh savegame. I've recently started a new game and checked the logs after firing OSA once in a while, I've come across the issue twice so far, but I can't manage to replicate it, all I can say is that it happens as soon as the scene gets fired up, whether from a keybind or manually through the OSA menu.

 

- The scene will still fire successfully;

- Both times the target NPC was about to sit down, I've tried to replicate this condition but further attempts didn't trigger the issue;

 

I come from a programming background but I'm new here, tried my hands at the scripts but came out disapointed after realizing they get baked into the savegames, ouch. That must be a huge headache for modders. This might not be the best place to ask, but is there any way to force a savegame to update a script?

It might be a bit early for me to start throwing suggestions but I'd advice to add breaks/limiters to the "while" cycles, if the content of the cycle fails the cycle can keep on living forever stressing the engine.

 

I'll keep trying to learn more and keep my eye on further instances of this issue showing it's head.

Link to comment

...

 

Welp, I'm both happy and confused. Keep in mind what I'll say pertains the old save I talked about a few days ago, so it'd likely have older scripts baked in it:

I'm not 100% sure but I reckon the infinite loop for this issue is the first while in the "setActors" function.

Since part of the issue seemed to be that empty actra values (=None) were being fed to the "isAllowed" function I thought to add this filter to the function and if that didn't clear the issue I'd see where it would lead me next:
 
if(actra==None)
return false
endif
 
For some reason beyond my noobness it actually picks up on the modified "isAllowed" function, so this runs successfully, but I can't seem to touch the other functions that freak out after this one (baked in?).

 

Now, for funsies I decided to make that return true and see how the rest of the script would deal with empty actras being passed, since I don't have a good understanding of the rest of the script I can't be sure if this was safe (dunno how well osa.setModule and osa.start might've dealt with the empty actra), but doing this allowed it to end that infinite loop and end that processing thread (I assume). At least papyrus seems more responsive now and isn't handing out further errors.

Perhaps more importantly, I was now able to use a script cleaner on a save, load it, and save again without it crashing.
 
Hopefully you can salvage something out of this wall of text, if not sorry for my rambling. But yeah, still don't know what causes this to begin with.
Link to comment
Guest ffabris

I come from a programming background but I'm new here, tried my hands at the scripts but came out disapointed after realizing they get baked into the savegames, ouch. That must be a huge headache for modders. This might not be the best place to ask, but is there any way to force a savegame to update a script?

The only way to have data persist between game sessions is to have it in the save. At least using the "vanilla" game engine. PapyrusUtil offers JsonUtil, which allows data to be saved in a json file, but I guess such a system wouldn't work for all game data.

Link to comment

 

I come from a programming background but I'm new here, tried my hands at the scripts but came out disapointed after realizing they get baked into the savegames, ouch. That must be a huge headache for modders. This might not be the best place to ask, but is there any way to force a savegame to update a script?

The only way to have data persist between game sessions is to have it in the save. At least using the "vanilla" game engine. PapyrusUtil offers JsonUtil, which allows data to be saved in a json file, but I guess such a system wouldn't work for all game data.

 

 

What confuses me is why go as far as saving scripts/functions into the save itself? My best guess is that they decided to do that to avoid issues when those scripts are removed or changed but I wonder if there wouldn't be a less agressive way to go around it that'd terminate the script and reset affected vanilla values. But like I said, I'm new to this so I'm fine with a "take it as it is" stance, it just pains me to think of the headaches it must cause. o_o'

 

On the same note, the other day I was messing around with the Creation Kit and making my first script. Took me some time to realize properties were being saved (I assume in some sort of cache) and linked to savegames as soon as I loaded the savegame (no saves were made after a load), it confused the hell out of me as I kept making changes to the script that wouldn't get reflected when I restarted the game and loaded again.

 

[EDIT] I understand why caching is used and it's purpose, but I'd expect the Creation Kit to clear it when making changes, know what I mean? QoL stuff for the modders. [/EDIT]

Link to comment
Guest ffabris

 

 

I come from a programming background but I'm new here, tried my hands at the scripts but came out disapointed after realizing they get baked into the savegames, ouch. That must be a huge headache for modders. This might not be the best place to ask, but is there any way to force a savegame to update a script?

The only way to have data persist between game sessions is to have it in the save. At least using the "vanilla" game engine. PapyrusUtil offers JsonUtil, which allows data to be saved in a json file, but I guess such a system wouldn't work for all game data.

 

 

What confuses me is why go as far as saving scripts/functions into the save itself? My best guess is that they decided to do that to avoid issues when those scripts are removed or changed but I wonder if there wouldn't be a less agressive way to go around it that'd terminate the script and reset affected vanilla values. But like I said, I'm new to this so I'm fine with a "take it as it is" stance, it just pains me to think of the headaches it must cause. o_o'

 

On the same note, the other day I was messing around with the Creation Kit and making my first script. Took me some time to realize properties were being saved (I assume in some sort of cache) and linked to savegames as soon as I loaded the savegame (no saves were made after a load), it confused the hell out of me as I kept making changes to the script that wouldn't get reflected when I restarted the game and loaded again.

 

[EDIT] I understand why caching is used and it's purpose, but I'd expect the Creation Kit to clear it when making changes, know what I mean? QoL stuff for the modders. [/EDIT]

 

 

Well... let's say you decide to stop playing for the day, in the middle of the civil war. Would you want to start the entire war over the following day? Presumably not. So the progress of the war needs to be saved, right? And that's just a very simple example. The same holds for a very large number of situations, many of which may be ongoing.

 

Properties are actually linked to the mod the script belongs to. You can see that if you open the mod with TES5Edit. Quest -> [name of quest] -> VMAD - Virtual Machine Adaptor, for example. Naturally, property values must persist somewhere, or they would be wiped. So again, the save file.

 

Link to comment

 

...

 

I can only say you're seriously missunderstanding me. xD

 

I am neither saying important data shouldn't get saved (what?) and I clearly said I did NOT save after changing properties in a mod. Yet changes made to properties in the esp weren't there when restarting the game and loading again (hence I suspect cache).

 

If you insist on replying me with unrelated examples next time I can only shrug at it. D:

Link to comment

 

...

 

 

Scripts don't get saved in the game saves.  Aspects of scripts get saved in the game saves.  Properties, var names, values, script names...  But the actual code is not sitting there in your game save.

 

You can add code, properties, vars, whatever, through many script versions without causing an issue by upgrading the script within a single play-through.  You start to run into trouble when you don't understand the little quirks of papyrus and the way the game connects to it through CK settings.

 

For example, once you connect a property through the script properties window, that property is eternally part of your mod, even if you delete the property from the script.  The property becomes both part of the script and part of the quest/magic effect/spell/whatever.  And, deleting the property will result in the most common log error there is, "property no longer exists."  You can avoid the error a few different ways, but the most frequently used methods are TESVedit surgery and just leaving properties you no longer need inside the script, which is probably the smartest way to do it, because leaving the unused property intact doesn't create an inconsistency between the game save and the mod.

 

The log error I describe above is annoying, but it is harmless.  The "= None" variety means something actually didn't work.  They can result from a lot of different things.  The most common is people who use GetFormFromFile() to find out if another mod is present instead of SKSE's GetModByName().  You'll see a ton of this spam from the startup maintenance code of Convenient Horses and some of Arthmoor's mods, such as LAL and USLEEP.  It's just spam, but it really blows up the size of a log file.  These are good modders, so I suspect it was a conscious decision that the spam was worth having rather than making mods reliant on SKSE.  I altered their scripts so they don't produce the spam anymore, but neither gave me permission to release a patch.  The adjustments reduced my log files from 46KB to 6KB, making it much easier to find genuine errors.

 

Another common "None" results from what people call "cloaking spells."  These are magic effects applied to actors that persist continuously during gameplay in order to flag an actor or otherwise allow the actor to be controlled and identified in a special way.  A lot of mods use them, including OSA.  They can be an issue when an actor's 3D isn't loaded.  You can't dispel or otherwise operate on a magic effect on an actor in a different cell, or on an actor whose 3D is not yet loaded because the game hasn't finished loading the first cell after launch.  The most stressful cloaking spell I've seen comes with HDT heels.  It runs an OnUpdate (polling) every tenth of a second for every pair of HDT heels being worn in the game – extremely stressful on the script engine.  By comparison, NiO heels are unscripted.  HDT heels really shouldn't be used anymore and they are very easy to convert to NiO.

 

Aliases are generally a safer method than cloaking spells, but they are more work and they can also produce the "None" errors with careless scripting.  They have a really big advantage in that you can clear an alias when the actor's 3D isn't loaded, unlike trying to dispel a cloaking spell.  If you look at Bethesda's own scripting, aliases are used very extensively while cloaking spells are almost never used and when they are, it isn't really a cloaking spell, because it is temporary.

 

A lot of other things can also cause the "None,"  which typically sets off a chain reaction of log spam resulting from the fact that the object that is the subject of a chunk of script code doesn't exist.  It generally means, "not found."  Sometimes it is harmless (the GetFormFromFile() variety is harmless), sometimes it isn't (the cloaking spell variety usually means something isn't working as it should).

 

@Jerok, I haven't had a chance to look into the log errors yet because I've been working on alignment issues resulting from collisions and I've also been working on my own mods, but I'll get around to it.  There are many, many loops and arrays in OSA.  It can take a while to become familiar with what you're actually looking at and CEO didn't necessarily label all the vars and functions in a way that is self explanatory.

Link to comment

Anyway, wanting to explore how to write mods that make use of this, I looked at the papyrus interface. Nice and simple. :) But, given that I'd like to trigger specific types of scenes (based on the story line), is there any way to determine, run-time, what scenes are installed, and what type they are? I'd rather not hard-code a list, as that would exclude any new scenes that might be created in the future. The only sample code I've seen is in Amorous Adventures, and that seems to always use "Auto" for the scene, which presumably means "run a scene at random".

 

I wish I could help you more, but the API documentation was never really finished with full examples and CEO was in the middle of adding features to it when he vanished again.

 

I can show you how to discern if a module such as OSex is present.  I do it with BBLS.  I can't show you how to determine if a module extension is present (some here refer to these as plugins, but I think that's confusing, because esm and esp files are plugins).  Module extensions would be things like the unreleased Bad Boys, Bad Girls and Wizard Sex extensions to OSex.

 

CEO had at one time planned to give us the ability to discern when a scene had ended, which animation (by ID) or animation type was currently being played, what speed a looped animation was playing, and a few other useful things for scripted mods.  As far as I know, he never implemented those plans.  He did implement the ability to designate an animation series by ID from start to finish, although I'm not sure there is official documentation for it.  I don't use it because at the time I added OSex integration into BBLS, people already had Amorous Adventures and some were just looking for a way to initiate OSex via dialogues as opposed to a hotkey.

Link to comment
Guest ffabris

I wish I could help you more, but the API documentation was never really finished with full examples and CEO was in the middle of adding features to it when he vanished again.

 

I can show you how to discern if a module such as OSex is present.  I do it with BBLS.  I can't show you how to determine if a module extension is present (some here refer to these as plugins, but I think that's confusing, because esm and esp files are plugins).  Module extensions would be things like the unreleased Bad Boys, Bad Girls and Wizard Sex extensions to OSex.

 

CEO had at one time planned to give us the ability to discern when a scene had ended, which animation (by ID) or animation type was currently being played, what speed a looped animation was playing, and a few other useful things for scripted mods.  As far as I know, he never implemented those plans.  He did implement the ability to designate an animation series by ID from start to finish, although I'm not sure there is official documentation for it.  I don't use it because at the time I added OSex integration into BBLS, people already had Amorous Adventures and some were just looking for a way to initiate OSex via dialogues as opposed to a hotkey.

Thanks for the reply. :)

 

I know how to check for a mod being loaded, so I didn't need that.  What I did need wasn't the module extensions but the scenes (intimacy acts) and types they all make available. Basically, an equivalent to SexLab's tags. For what I can tell, there is no way to obtain such a list run-time, but I figured it couldn't hurt to ask.

 

OK, I now have a better picture of what I can and can't do - at this point in time, anyway - with OSA/OSex: not much. And that isn't a critique.

 

P.S. I know that scripts aren't put in the save; I was simplifying. Also, re: removing properties, delete from script, then open and close the Properties window. That gets rid of the error you would otherwise get.

Link to comment

 

...

 

Thanks for the very informative post Migal. I'm sorry if this is really offtopic but would it be possible to remove HDT Heels without causing issues when having armor that uses it still installed? I've been wanting to remove it for a while but I feared to break anything and I lost track of which armors use it. Would it just remove the offset?

 

More on topic:

I've been hesitant to believe statements saying scripts get baked into savegames and I can take your word for it not being so, but what about scripts from ongoing threads? These were the type of spams I was getting into the logs before I somehow stopped it:

 

 

 

[10/09/2016 - 01:40:14AM] ERROR: Cannot call HasKeywordString() on a None object, aborting function call

stack:
<unknown self>.osa.IsAllowed() - "OSA.psc" Line ?
<unknown self>._oglobal.checkActra() - "_oGlobal.psc" Line ?
<unknown self>.osa.setActors() - "<savegame>" Line ?
[0SA (18000D62)]._oOmni.OnStartModuleUI() - "<savegame>" Line ?
[10/09/2016 - 01:40:14AM] Warning: Assigning None to a non-object variable named "::temp27"

 

 

 

Notice the <savegame> tags? When I altered OSA.psc the changes I made inside "IsAllowed" (OSA.psc) were shown (such as adding debug message boxes) but altering "setActors" didn't do anything at all. Which is why in the end I assumed at least scripts related to currently running threads were saved into the save file. Which is at least WAY more understandable than saving everything, but could be really troublesome when fixing broken savegames, is what I though.

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