Jump to content

monsto

Premium Member
  • Posts

    150
  • Joined

  • Last visited

Nexus Mods Profile

About monsto

monsto's Achievements

Community Regular

Community Regular (8/14)

  • First Post
  • Collaborator Rare
  • Week One Done
  • One Month Later
  • One Year In

Recent Badges

0

Reputation

  1. Compiler for papyrus https://github.com/Orvid/Caprica It appears that it was used here, so I expect that it works well... enough. https://www.nexusmods.com/starfield/mods/4540
  2. Thanks for the quick reply! To directly address the things you've said... I've "left" the cell many times, unless it's only triggered on an in-game cell change, such as using a door. Occassionally I will `COC` to another cell, use console `PCB` (purge cell buffers) which resets a number of things in cells you're not in, and then `COC` back to the origin cell. Does that not count for what you're tlaking about? The pseudo-code blocks you wrote is basically what I was asking if it would work, so I'm guessing it will. Will that only work on "leaving the cell" also, or would it work to immediately unload/delete the refs/forms? Thanks for your advice.
  3. I have a mod that adds forms/references (mannequins) that have a few scripts attached to them. When deleting these via script, they are removed from play, but remain in memory and over time will seriously bloat the save file. The main question is: How do I unload these forms/refs from memory? Here's how I'm removing currently: elseif configChoice == 5 ; Pick Up self.removeAllItems(game.getPlayer() as objectReference, true, true) BUMPed.delete() // pedestal form notify("Mannequin inventory moved to you.") self.delete() // self = mannequin form. return endif Yet looking at the savefile (using the program Savetool) it looks like the form references and I think the scripts are not removed at all because they stay in the save. The save file has 15000 forms on the cell that I'm using, while skyrim.esm shows 8000. https://i.imgur.com/ZgApc8o.png https://i.imgur.com/Yb2GpR9.png According to https://www.creationkit.com/index.php?title=Delete_-_ObjectReference So the questions: how do I go about using a more efficient way to delete things than simply using the `delete` method?If I need to set some variable to `None`, which should I set?According to the above snippet, would it be valid to set `self = None`?`BUMPed` variable refers to a property. would it be valid to set THAT to `None`? Is there a better save editor that can show which items have been `marked for delete` but are still present? I'm asking these questions here instead of just doing it because it takes effin forever to start CK and try these things.
  4. I tested it with 2 saves. Used savetool to delete all forms. Dropped a mannequin, saved First. Deleted the mannequin, saved Second. Savetool showed 33 forms on the 2nd save. I haven't work on it in a while, so the quit/load thing didn't affect all this. Also, you can load a save to get fresh script when the mod isn't part of the save. I had a small box cell that I was testing in. So quickload the save that hasn't had the mod, I get my notification that the script has loaded, and I can see the effects without having to completely cycle the game. Tremendous time saver that also wouldn't pile up the scripts/forms. I've had this happen several times over a couple years, but only after a cell has a bunch of mannequins in it, after months of toodling. If there's a method to purging scripts and forms and etc from memory when the entity it's attached to is removed from the visibility of the game (I can't really call it 'deleting' anymore) that's what I need to do.
  5. I made a mod (unpublished) that updates Portable OnDemand Disposable Unlimited Mannequins. Basically, it's a mannequin mod where you put down actual NPCs, they wear the equipment you give them, and then since they're NPC you can pose and animate them. I rewrote it from scratch, using a decompiled version of the original as reference. I added a list menu (like Add Item Menu) and a kinda plugin system where you can drop in an ESP with new mannequins and it will add them to the list. The problem is that I didn't realize that there's A TON of forms/scripts attached to each, and I have no idea where they came from. Based on my tests, it seems to be > 30 forms/scripts per mannequin. And then deleting the mannequin, it doesn't clean up the scripts. A recent save game viewed in Savetool shows that there's > 15k forms/scripts attached to the cell that I use, and there are no orphans. Skyrim.esm only has ~8800 . . . so obviously this is a problem. I believe this is at the core of the in-game problem I'm having which is that the game hangs when loading the most recent save as the first load from starting the game. I can first-load a previous save to start the game, then load the save that hangs, and the game works just fine. Anyway, I now know that disabling and removing the mannequin doesn't detach and kill/clean up the scripts. So I need to do that. The game doesn't really do a whole lot of spawn/destroy of entities with scripts attached to them. Even if it did, it wouldn't do it hundreds of times in a single cell. so I realize that this kinda cleanup may not even be a thing. I also realize that the better practice would be to not attach the scripts in the first place, but I have no idea where they came from. I purposefully only attached I think like 5 (it's been a while), so filtering out unknowns will be "hard". It seems easier to clean up properly on deletion, which would be a good thing to do regardless of reduced attachments. So I realize that any specific help would be based on seeing the source, but right now I really just need to know if this kind of clean up is possible, and how it might be done.
  6. I've a small handful of personal mods I've created . . . I have a mod that is a helper script with added console commands for moving s#*! around the cell. Another is a modernized version of Portable OnDemand Disposable Unlimited Mannequins (I call it Better Unlimited Mannequins... BUMs) And then I have a pretty good handful of armor/outfit mashups, basically a bunch of handmade ESPs built from various other armors/outfits using Nifskope, Bodyslide Outfit Studio and TES5Edit. I know I'd have my work cut out for me . . . but I'm just getting started on the mental process of conversion. But my question is, conceptually speaking, i'm trying to get a handle on how "difficult" it's going to be, per mod, to up-vert to SSE? Also, while I'm at it, is SSE the same as SE, just a different term? Thanks for any reply. ---- Also also . . . it's my favorite thing ever when people can't admit a mistake. Double, triple, quadrupling down on their own accomplishments, moving the goal posts, appeals to credibility, etc etc. When all they have to say is "Huh. I didn't know that." I had a very similar conversaion with a Cities: Skylines modder about documentation of all things, and the belief that documentation at any level is extra work. "You wouldn't last for a day" he says. Well, so, I had to link him to the docs I wrote on the Slab of Lovers (ahem I dunno if there's still drama but just in case) for HDT Physics Extension . . . posts with couple million total views and only a few hundred posts. Professionalism isn't a skill that comes easily. For those that need it most, it's usually learned the hard way.
  7. I've made some stuff in a non-worldspace cell. it's a "castle courtyard" kinda thing, where it doesn't need to be worldspace, but it needs to be outside and lit by the sun. How do I set this up so that it shows with sunlight?
  8. Actually, what you say makes a lot of sense as far as papyrus is concerned. 2ndly, I was also trying to figure out a way to make the menu one time, and then refer to that whenever I use the menu. As it stands, the menu is rebuilt from the formlist everytime it's accessed. There's ~1 sec delay per ~25 menu items. So I was thinking to put the aggregate formlist, along with the menu variables, on a quest based player refalias. That seems to be as about as persistent as you can get. The built menu array would remain as well as taking care of your suggestion. Thanks.
  9. I checked... I've 2 addons, and they're both 'start enabled' and 'run once' . . . i figure 'run once' is correct, because I only want it to run the one time that it's installed and then not again.
  10. There's a script that's part of the base mod, "packscript". The addon esps have a quest > refalias > "packscript", with the properties and all that adds a formlist from the addon to the formlist in the basemod. And now you've made me want to check if it's "enabled on start" and also not "run once" just to dbl check.
  11. It's a mannequin mod. The base mod has 5 types. In a separate esp, I have a bunch more types, and may make more types down the road. I want to be able to add new types to the process willy-nilly. The mannequin types are put in a formlist, and the choose/drop menu populates a UIExtensions Listmenu. It's clear that the formlist isn't being updated, and that the disablemod-savethegame-enablemod-reloadthegame procedure basically purges then makes a new formlist, but it's obviously unwieldy. How should I go about updating the formlist that drives the listmenu?
  12. The only problem with the above code is that the object might be disabled, its cell might be unloaded, etc (and thus the loop will keep on looping until the object's 3D is actually loaded). What would fix / mitigate this issue would be to have code like this: float futuretime = Utility.GetCurrentRealTime() + 5.0 While (Self.Is3DLoaded() == false && Utility.GetCurrentRealTime() < futuretime) ; do nothing here, just loop endWhile if (Utility.GetCurrentRealTime() > futuretime && Self.Is3DLoaded() == false) ; bad, time to abort / retry. endif Alright so basically you're saying that it's risky, which I get. Good thoughts. Thank you.
  13. This is the main thing I hate about papyrus: ineffective documentation. They tossed that wiki out there, and left it to the wild, never to be thought of again. I mean if this is in there, and people had to discover it by trial and error, what else is out there that nobody knows about? Now go back and read the rest of his post AFTER the link to the function.
  14. Excellent notes and info. It's annoying that standards that you mention (points 1, 2, 3) are only found by the handing down from one generation to the next. I've been piddling with papyrus for I dunno 3-4 years, and have never seen anything like this. It truly belongs on a ckwiki page, something like "Papyrus conventions for cleaner scripting". For point 2 on your list, what's an alternative to that? I'm also a fan of some of the 'programming habits' you've displayed. Comment lines for breaking up the menu elseifs (Elesif? Holy s***...), the comment "skse required", things like that. I left the boilerplate decompiler heading as a credit to the original author and idea In the script. I think the only thing remaining from the original is a handful of lines, like maybe 20. I see exactly what and why about overwhelming init(). I'm assuming that by using an update, it allows the task to be threaded and therefore reducing hitches and framerate drops. I may take that piece of advice when it's time to streamline, but it's working right now and I'm reluctant to mess with it. I have no idea of what is the significance of, or when or how to use, fragment scripts. Is there a primer somewhere? All in all I appreciate your very good papyrus response.
×
×
  • Create New...