-
Posts
1192 -
Joined
-
Last visited
Everything posted by fg109
-
I don't know how you're enchanting arrows in the first place... So this is just what I would do if I wanted to create poisoned arrows: 1. Create custom explosion. 2. Custom explosion should have the poison enchantment. 3. Create custom projectile. 4. Custom projectile should explode on contact, with the custom explosion. 5. Create some custom ammo. 6. Custom ammo should use the custom projectile. 7. Give player the custom ammo.
-
A Papyrus Script to Toggle a Designated Effect
fg109 replied to Altrunchen's topic in Skyrim's Skyrim LE
You really need to read some scripting tutorials... Scriptname FXToggleSwitch extends ObjectReference {This is to allow effects to be toggled in game with activators.} ObjectReference Property Effect Auto Int Property Duration Auto Event OnActivate(ObjectReference akActionRef) Effect.Enable() Utility.Wait(Duration) Effect.Disable() Endevent -
Script Help: forceav on event or alternative?
fg109 replied to eschaeon's topic in Skyrim's Skyrim LE
I was wrong about speedmult having 1.0 default value, it really is 100.0. I tried making a spell myself but it doesn't seem to work. It seems to be bugged similar to 'Marked For Death'. Try using a script like this instead: Scriptname Example extends ActiveMagicEffect float OldSpeedMult Event OnEffectStart(Actor akTarget, Actor akCaster) OldSpeedMult = akTarget.GetAV("SpeedMult") akTarget.SetAV("SpeedMult", 1) EndEvent Event OnEffectFinish(Actor akTarget, Actor akCaster) akTarget.SetAV("SpeedMult", OldSpeedMult) EndEvent -
Script Help: forceav on event or alternative?
fg109 replied to eschaeon's topic in Skyrim's Skyrim LE
What do you mean by the papyrus speedmult? I only know about the actor value. -
Script Help: forceav on event or alternative?
fg109 replied to eschaeon's topic in Skyrim's Skyrim LE
Uh... speed mult of 1 is the default. It's a multiplier. You should try values between 0 and 1 if you want to slow them down. -
No idea about #1 since I'm just a scripter. For #2, using that script won't work because the script used for the Labyrinthian is attached to the rune. There are some activators that are water, so I guess you might attach a script to them if you don't mind altering the vanilla records. But lots of bodies of water in the game are not objects (eg the ocean and rivers) so you can't put a script on them. Sorry, but I can't think of a way to script it.
-
There is no GetSecondsPassed function in Papyrus because papyrus scripts don't run every frame. The closest you could come to it would be to find the difference in time between updates by checking how long the game has been launched. Float UpdateTime Event OnInit() UpdateTime = Utility.GetCurrentRealTime() RegisterForSingleUpdate(0.01) ;i doubt that you can actually have this short of an interval EndEvent Event OnUpdate() UpdateTime = Utility.GetCurrentRealTime() - UpdateTime if (UpdateTime < 0) ;game was relaunched else Debug.Notification("Seconds passed since last update: " + UpdateTime) endif RegisterForSingleUpdate(0.01) EndEvent Instead of constantly using SetPosition, I would use one of the TranslateTo functions.
-
You can change the grain mills into crafting furniture by editing it so that 'Bench Type' is 'Create Object' then creating some recipes under 'Constructible Objects' that requires the workbench to have the keyword 'IsGrainMill'.
-
If dragging bodies around aren't important, then you can just create a new enchantment with this scripted magic effect: Scriptname fg109TestMEScript extends ActiveMagicEffect Actor MySelf Event OnEffectStart(Actor akTarget, Actor akCaster) MySelf = akTarget MySelf.SetUnconscious() MySelf.PushActorAway(MySelf, -5) RegisterForSingleUpdate(2) EndEvent Event OnUpdate() MySelf.EnableAI(False) EndEvent Event OnEffectFinish(Actor akTarget, Actor akCaster) MySelf.EnableAI() MySelf.SetUnconscious(False) EndEvent Event OnActivate(ObjectReference akActionRef) MySelf.OpenInventory(True) EndEvent
-
The second script wouldn't compile because I forgot to take out the check for the variable when I was copy/pasting. Anyway, I took a closer look and figured out some more things. When you cast the spell, you don't immediately change into a werewolf. I was setting the states/variable back to default too soon. The combat state change from changing race occurs after I stop looking out for them in the script. I tried a couple of different ways and this is what I came up with: There are probably some unnecessary code in there since I needed a couple of tries to get it right. The script would be much simpler if you didn't use a spell to change to a werewolf:
-
GamePlay -> Animations -> Actors\Characters\Behaviors\0_Master.hkx -> Anim Event drop down on right
-
I haven't done any testing, but I think the reason it was doing that is because when the actor's race is changed, they go out of combat temporarily. You can solve this either by using a boolean or by using states. I think using states are supposed to be better, but they both work: Scriptname Example extends Actor SPELL Property WerewolfChange Auto Race ActorRace Bool Busy = False Event OnCombatStateChanged(Actor actorRef, int combatState) if (Busy == False) Busy = True if (combatState == 1) ;started combat ActorRace = GetRace() WerewolfChange.Cast(Self) elseif (combatState == 0) ;left combat DispelSpell(WerewolfChange) SetRace(ActorRace) endif Busy = False endif EndEvent Scriptname Example extends Actor SPELL Property WerewolfChange Auto Race ActorRace Auto State Waiting Event OnCombatStateChanged(Actor actorRef, int combatState) GoToState("Busy") if (Busy == False) if (combatState == 1) ;started combat ActorRace = GetRace() WerewolfChange.Cast(Self) elseif (combatState == 0) ;left combat SetRace(ActorRace) DispelSpell(WerewolfChange) endif endif GoToState("Waiting") EndEvent EndState State Busy EndState
-
I do not know where you got that script, but there are lots of things wrong with it. Why do you have states in your script when you're not using them for anything? You have a command telling your script to go to one state, but no command telling it to go back to the previous state. What is 'sskythiraamanan' and 'Kythiraamanan'? Why are you trying to have the actor activate itself instead of casting the transform spell like you wanted? Anyway, I would use a script like this: Scriptname Example extends Actor SPELL Property WerewolfChange Auto Event OnCombatStateChanged(Actor actorRef, int combatState) if (combatState == 1) ;started combat WerewolfChange.Cast(Self) elseif (combatState == 0) ;left combat DispelSpell(WerewolfChange) endif EndEvent
-
Well, considering that a cell is 4096x4096 units, I suspect that it's impossible to obtain references from a cell that hasn't been loaded, or has been unloaded.
-
There's no way that I know of to reference an NPC's crime gold. I'm not sure that they even have bounties.
-
The only way I know of to dynamically change the name of something is through quest aliases. But doing that is probably more complicated than just creating a bunch of different activators.
-
Scriptname GetCrimeGoldScript extends ObjectReference Float PCCrimeGold FormList property CrimeFaction auto Faction CurRef int CurIndex int ArrayLength Event OnEquipped(Actor akActor) If (akActor == Game.GetPlayer()) ArrayLength = CrimeFaction.GetSize() CurIndex = 0 While CurIndex < ArrayLength CurRef = CrimeFaction.getat(CurIndex) as Faction PCCrimeGold = CurRef.GetCrimeGold() CurIndex += 1 EndWhile EndIf EndEvent
-
It's possible to do all of that except drag bodies around. Somebody on the bethsoft forums was trying to do the same thing, and in the end he had to settle for killing the actor and then resurrecting them later.
-
I found a bug a couple weeks ago. It might have something to do with the problem you're seeing. Also, just because something is in the AoE doesn't mean that they'll be affected by the spell. It's like the AoE effect is actually a huge amount of aimed spells fired off in every direction. If an NPC is behind a chair or a lamp or something, then depending on their angle from the caster, they won't get hit. Also, brief blurb about units: For magic effects, area is measured in feet, not units. Script functions use units, which are much smaller than feet. For example, the default activation distance is 150 units. This is the maximum distance from which you can activate an object (eg how far away you can stand from a door until you are no longer able to see the activation prompt).
-
Made a Merchant - Now Vanilla Merchants Fubarred
fg109 replied to tock333's topic in Skyrim's Skyrim LE
I've looked over it and I'm stumped as to what's causing it. It's the mod for sure, because if I load my game without any mods, everything is fine, but when I load with only this mod, the merchants are broken. From what I can tell, there is something preventing them from accessing their merchant containers, and they all buy and sell everything. I've used GetInFaction in the console to make sure that they are in the correct vendor factions to access the containers. I removed them from the faction and added them back in with no results. I also tried creating a new vendor faction with a new merchant container, but that didn't work either. And I've checked the formlists, but there is nothing wrong with them. -
Has anyone been working on in-game spell creation?
fg109 replied to Lugh1000's topic in Skyrim's Skyrim LE
I remember creating a conjuration spell-making altar in Oblivion. Basically I created 10 dummy spells, then put a script on the altar that lets you choose which monster you want it to summon, how many, and the duration. Then I used OBSE functions to modify the dummy spells. Nothing like that for Skyrim though. And the first version of SKSE (with scripting functions) doesn't seem to have anything dealing with spells or magic effects. -
Made a Merchant - Now Vanilla Merchants Fubarred
fg109 replied to tock333's topic in Skyrim's Skyrim LE
Are you sure that it's your mod doing this? Try loading the game without your mod and then seeing what happens. If it really is your mod doing this, did you do anything such as mess around with factions or formlists? -
Custom Follower Unequips all weapons upon entering combat.
fg109 replied to SiniVII's topic in Skyrim's Skyrim LE
Could it have anything to do with her combat style? -
How to get Custom Perks without spending points
fg109 replied to vespidae's topic in Skyrim's Skyrim LE
Are you sure that you are unable to assign it through the console? If you know the name of your perk, you should be able to do it like this: help "name of perk" 0 Then it should list everything with "name of perk" in its name, and display the editor ID (a hexadecimal string) next to it. If for example, the string was "03000D66", you would use this in the console to add it: Player.AddPerk 03000D66 -
Did you remember to set up your properties? Also, it's quite strange that the notification appears twice.... Did you make the container the activate parent of the activator too?