Jump to content

ThoraldGM

Premium Member
  • Posts

    334
  • Joined

  • Last visited

Everything posted by ThoraldGM

  1. Creation Kit, Notepad++, and https://www.creationkit.com/fallout4/index.php?title=Category:Papyrus
  2. Does your detection script already have targetID as Actor? If so: targetID.SetProtected(false) https://www.creationkit.com/fallout4/index.php?title=SetProtected_-_Actor
  3. I see you've already found Seddon4494 on YouTube (lol small world). ForceGreet seems to be for NPCs initiating conversation with player. To do the opposite on a moving target, I'm guessing you could RegisterForDistanceLessThanEvent. When OnDistanceLessThan fires you could SetPlayerAIDriven and run a Say procedure in a package on player. Then set AI driven false so player is in control again. I don't like the idea of grabbing control and assuming how player would act, but my personal opinion is not relevant to a code solution. I've also never used scenes, but would be interested in learning what can be done with them. The script itself would be on the NPC.
  4. Is the Pip-Boy already open by the time OnMenuOpenCloseEvent fires? If not: OnMenuOpenCloseEvent if (asMenuName== "PipboyMenu") if (abOpening) add the PA perk else remove the PA perk Pseudocode because I'm on mobile. https://www.creationkit.com/fallout4/index.php?title=OnMenuOpenCloseEvent_-_ScriptObject https://www.creationkit.com/fallout4/index.php?title=RegisterForMenuOpenCloseEvent_-_ScriptObject
  5. If Game.GetPlayer().IsInInterior() https://www.creationkit.com/fallout4/index.php?title=IsInInterior_-_ObjectReference
  6. Idk what's up with the gender flags, but debug notifications would not tell me what Scavver picked up (Name etc). But sometimes debug trace printed the full info in Papyrus.0.log
  7. Haven't had a chance to look, but it sounds like a case of bad timing: - Pistol is equipped - Magic effect starts - OnEffectStart event fires - Your ammo is adequate - Event is done - You deplete ammo - Nothing happens because event is over and no longer listening? If you unequip does the magic effect go away? If you re-equip after ammo is down, do you get more ammo?
  8. Holiday overtime. It's going to be a week or more :-/
  9. This is one of the most interesting threads I've read in awhile. You've gone way beyond what I did with Scavver and I think your observations will be essential reading for anyone who creates NPCs. Maybe this should all go in the CK wiki too. (Discussion tabs?) Because sooner or later, anyone who tries to make NPCs with advanced behavior will run into the problem of what NPC should do when the player travels away and the cell unloads. Edit: I found an old Scavver test video. Timestamps in description: https://youtu.be/uWDzMrUTK94
  10. Outside of your event, add: Ammo Property Ammo10mm Auto (For example, see lines 17, 213, 243: https://pastebin.com/u7p114FH . Ignore the while loop, I should've simply added Max - Current.) Then do this: You have an unfilled property. To define Ammo10mm, open your activemagiceffect entry in CK. Highlight the script name. Click properties. The unfilled property should be in red text. At this point you should see buttons to assign/edit. You will need to find the form for Ammo10mm and assign it. Once done, the text will change from red to black. Ok. Save. Etc. I came from a 100% text coding background, so the hybrid of Creation Kit and Notepad was weird to me. But once you get used to it, the CK cuts script work in half.
  11. Nice. Thanks. Looks like I can at least get a list of objref IDs. Do you know if Pascal can fill an alias collection or array with the returned results? Trying to gauge how much of the process can be automated.
  12. If there was a way to Select All from Use Info and drag them into one ref collection, that would be immensely useful. But the Use Info window lists cell data. I don't think the actual ref data loads until I click an entry and the render window loads, then ref gets listed in the next window down. Or am I missing some easier step? Otherwise I don't need to manipulate several refs at once in game. I just need a faster way to create aliases in refquest so the master quest can pluck individual targets via aliasID. I also don't know the objref ID numbers until I double click each object in the window. So I've just been working faster by hand until I find a better way.
  13. I wish Nexus threads had upvoting. That's how I would do it too. Transition lenses would work in similar fashion, swapping eyeglasses with sunglasses: https://forums.nexusmods.com/index.php?/topic/6109668-thick-rim-glasses/?p=54792938
  14. For some reason, the distance options don't work from my mod menu. Only when they are directly typed into the ini file. Which is weird, because they worked at first. I'm going to leave it as-is with a note in mod description. The spin on teleport and spin on demand options work fine with the menu. https://youtu.be/2oXbgoB4SZ8
  15. I forgot all about trying that. https://forums.nexusmods.com/index.php?/topic/3880465-where-is-the-show-pip-boy-function/ There is more discussion in the nested link, too. The Pip-Boy looks like a cool piece of Army surplus, but I'd love to have the Power Armor version all the time. The answer lies wherever the game handles button presses (or keypresses)... ... open Pip-Boy: if player in PA do PA version, else do regular Pip-Boy opening The problem is how to redirect that key/button press to do PA version every time :-/
  16. Glad to see I'm not the only one. I'm picky about spacing but would also like each to be slightly rotated horizontally so they don't look like clones.
  17. In the Creation Kit, there is a count column for every resource. I can right click a form, select "Use Info", and a window pops up listing the cells where the references are located in the vanilla game. I can click on anything in the list, and that specific reference will load in the render window. So... the game (at least the Creation Kit) knows how many instances / references are tied to each form and where they are. In fact, I've seen this in FO4Edit too, as "Build Reference Info". My question is... can I replicate that result in Papyrus? I am working on a teleport mod that finds statics or furniture, moves a marker to there with offsets, moves marker to navmesh, then moves player to that marker. So far, the categories have been a little tedious to create, but not overwhelming. There are 20 Red Rockets (including filling station remnants and gas prices signs), and there are 13 power lifts on overpasses or tall buildings. Unfortunately, there are 60 bus stop shelter benches and 43 Pulowski preservation shelters. That's a lot of refs to click, load in the render window, and force to a specific ref alias in each refquest. I'm probably going to select a handful and ignore the rest. But what if a function automagically listed the 60 refs? My existing code could import them and the mod would be done within a week. I've seen requests for Find All References (not just of type or within distance) and I guess that's what I'm looking for too. Only it would be both loaded and unloaded refs. Does Papyrus have an obscure function that mimics CK's Use Info feature? If not, guess I will keep selecting refs by hand in the render window, but 80% of available options are going to be ignored due to time/work constraints. Here's a video of my WIP: https://www.youtube.com/watch?v=2oXbgoB4SZ8
  18. I haven't seen anything that solves part 2 of OP's request (text in message/menu body), ie: MyMenu.Show(MyString) Welcome to my menu, %string If Beth actually fixes that, they should let us show form names in debug notifications too. Hell, even in the old MUD days we had: this_object()->query_short()
  19. Is it possible to use the ApplyingEffect part of a cloak effect to get all containers in radius of player? In conditions there is [GetIsObjectType Container == 1], ** but I don't know if that just returns chests etc or the fact that everything Object Oriented is technically a container. [**Edit: Just saw OP mentioned this in post #3. Nothing to see here, sorry.] If it does restrict "container" to storage containers, then you could have the cloak effect place the keyword, and remove the keyword when activated/looted by player. But then you might also have a problem losing keywords with container respawn. Idk if that would work. Just thinking out loud.
  20. Was the health code you tried SetGhost? Because I used SetGhost to ignore a bottlecap mine blowing up under my feet. Screenshots: https://twitter.com/ThoraldGM/status/930783875193888768 SetGhost: https://www.creationkit.com/fallout4/index.php?title=SetGhost_-_Actor
  21. Ooooh neat idea. There's a way to script it, but I have to remind myself not everyone is looking for scripts. If someone does tackle this, it would be like Scavver's beard change, only the event would be equipping the hat, and the changed head part would be hairstyle. https://forums.nexusmods.com/index.php?/topic/4468365-npc-grows-his-own-beard-but-wont-trimshave/
  22. I was going to necro this thread with new info but you beat me to it. Now that I've been working with menus more, there is a way to do what OP asked but it is very clunky and tedious af. Let's say you want revolving companion names in a button. Create a global variable that assigns values to each name. Piper = 1. Codsworth = 2. Deacon = 3. Then you can have conditional buttons in the menu that will only display the button you specify by the value of that global. If global == 1, shows Piper button. If global == 2, shows Codsworth button. If global == 3, shows Deacon button. In the screenshot, I do this with Start/Stop Developer Messages. There is only one button and the text alternates based on the value of the global. Like I said... tedious. But maybe that will be helpful for OP or anyone who stumbles in.
  23. You could script aggro to change on an event, like when player enters a trigger volume or when raiders acquire LOS on player. For the upstairs raiders, you could spawn them when player gets to top of stairs. This reminds me of the old Skyrim tutorial (Lokir's tomb). That one used activate parent on a triggerbox instead of scripting, with similar results. https://www.creationkit.com/index.php?title=Bethesda_Tutorial_Traps_and_Prefabs
×
×
  • Create New...