Jump to content

Ghaunadaur

Supporter
  • Posts

    796
  • Joined

  • Last visited

Everything posted by Ghaunadaur

  1. I don't think you can do this dynamically, it needs to be done individually for each script that you want to access. For example, if you would want to read a property value from a script on another mod that is attached to a quest, you can do the following: Quest OtherModsQuest Event OnInit() OtherModsQuest = Game.GetFormFromFile(0x00002dca, "OtherMod.esp") as Quest if OtherModsQuest debug.messagebox("Property value is: "+(OtherModsQuest as SomeScript).SomeProperty) endif EndEvent A property is not even needed, it can also be a local object variable.
  2. I just tested it, and I can confirm that both methods are working. Adding the script to the weapon itself will not work, if it's already in the inventory. In that case the solution I posted would be preferrable as it will work in all scenarios. Maybe dumb question, but did you fill the property?
  3. Instead of IsPluginInstalled, you can use GetModByName (requires SKSE) or GetFormFromFile, to check if a plugin is present. There are no functions like CallFunction or GetPropertyValue in Skyrim, but you can make a property for the object the script is attached to and use (ObjectName as ScriptName) to call functions or retrieve property values.
  4. I'm glad it worked. :smile: About resources, that depends on how the resource is made. In some cases you will need to make duplictes of the forms and add the meshes, textures or scripts to your mod, in some cases it's not needed. What resource do mean specifically?
  5. I never had this problem, so I can't come up with a solution, sorry. What happens if you first press the button, then select an object in the render window? Maybe as a workaround, you could add a collision box and replace it (CTRL+F) with a trigger box. Good luck.
  6. I think the problem is with the bow being in a container/inventory, so the script will not receive events, unless the bow was made persistent in some way. But you can do this by using an enchantment, and a spell ability that will be added by the enchantment. 1. Create the spell: type ability / casting constant effect / delivery self. 2. Add a magic effect to the spell: effect archetype script / casting type constant effect / delivery self. 3. Create a new enchantment and add it to the bow: type enchantment / casting fire and forget / delivery contact. 4. Make another magic effect and add it to the enchantment: casting type fire and forget / delivery contact. In the 'Equip Ability' dropdown, choose the ability you just created. 5. Add this script to the ability effect: Scriptname DoveCustomArrowScript extends ActiveMagicEffect Ammo Property DoveCustomArrow auto Event OnEffectStart(Actor akTarget, Actor akCaster) if akTarget == Game.GetPlayer() akTarget.AddItem(DoveCustomArrow,100,TRUE) akTarget.EquipItem(DoveCustomArrow,TRUE,TRUE) endIf endEvent Event OnEffectFinish(Actor akTarget, Actor akCaster) if akTarget == Game.GetPlayer() akTarget.RemoveItem(DoveCustomArrow,akTarget.GetItemCount(DoveCustomArrow),TRUE) endIf endEvent Obviously the script works only for the player. If you want it to work with all NPC, remove the conditions.
  7. It would be better to make your own quest, to avoid potential conflicts with other mods. Anyway, if you added new dialogue to the stables quest, then a seq file is needed as well.
  8. Have you already tried with a SEQ-File? If the quest set to start game enabled, it requires a SEQ-File for the dialogue to show up. https://forums.nexusmods.com/index.php?/topic/810472-workaround-skyrim-dialogue-bug-fix/
  9. Your too late, already verified the function works perfectly , does NOT effect any other pawns. Nice try though good luck shooting down sound advice. The vanilla script 'WICleanupScript' is used by many object in the game. If you change that, it will no longer work properly for all instances. That's just a fact. Not sure what you mean by 'function' or 'pawn'. Gibberish.
  10. You can't change the script without changing all instances of it. It's still a bad idea, and I strongly recommend the OP not to do so.
  11. This is a bad idea, since it will affect all instances of the script in the game.
  12. If it should be opened by default, change the OnLoad event to this: EVENT OnLoad() Wait(3) Drawbridge = GetLinkedRef() Drawbridge.PlayGamebryoAnimation("Backward", true) GoToState("ReadyForClose") endEVENt
  13. According to the wiki this option is non-functional.
  14. I think this mod can also be used for SSE. It's only a .esp file. If in doubt, load it in CK64 and save.
  15. Hello, add the following condition to the package: GetInFaction [PlayerFollowerFaction] == 1.0 run on reference [NPC x] or GetPlayerTeammate == 1.0 run on reference [NPC x] you may need to add another condition to the sandbox package, that checks for the opposite (== 0).
  16. No need to start over. Load your mod in TES5Edit, only your mod. Required masters will be loaded automatically with it. On the left, expand the CELL section of your mod until you find the Jorvaskr cell. Right click on that entry and remove it.
  17. No idea then. I've used that function before, in a magic effect script as well, and it worked properly. Could you post the script?
  18. GetRace() should work on both, the actor base and the reference. If it's a leveled actor try: akTarget.GetLeveledActorBase().GetRace()
  19. Please calm down. What's the problem with packaging your mod into a zip archive? It's a common thing, and saves space on hard drives. 7zip is a free and widely used archive tool.
  20. Nordic barnacles are Flora objects. Yes, they can be added with console command. Editor ID: NordicBarnacleCluster01 Form ID: 0007EDF6
  21. Not for Skyrim. I'd use DisablePlayerControls with abActivate set to true.
  22. That's really strange. For me it replaces all objects in the whole game. The CK if even asks if I really want to do that. Make sure that 'Current Cell Only' and 'Current World only' is unchecked.
  23. Select a potion in the render window and press CTRL+F. This will give you the option to replace all potions of that type with another object.
  24. At first, read the notes from this article. It's an important step when adding fragment scripts and properties. It applies to topic info fragments too. Once you've added the script, open the properties window and add a new property. Give it the name Gold001, and for the type choose MiscObject. After that, click the 'Auto-fill' button. The property should now be filled with the actual gold object. Remove all previous code and paste the following line of code to the code box, either 'On Begin' or 'On End', that's up to you. Compile the script again. Game.GetPlayer().RemoveItem(Gold001, 5, false, akSpeaker) If you haven't done already, you should also add a condition to the topic info, so it will only show up if the player has 5 or more gold.
×
×
  • Create New...