blacksupernova Posted August 11, 2013 Share Posted August 11, 2013 It's nice that I can look at it with CK, there are many interesting things I learn. It would be great if the randomly teleporting, or intangibleness of the npcs could be solved, I've looked but I can't find where the part of it that controls it. Also, up close when freezing a talking character, they would carry on their dialogue, and upon unfreezing they would move their lips even though their dialogue has already played. It's not that bad from afar, I think it's something how the game is made, because pressing Esc key while some npc are talking, they would still continue to talk.I'm afraid it is caused by the function EnableAI() that I use (of course, I would be so glad that I am wrong). A simple scripted spell using that function only with nothing fancy still result in the same problem. Sadly it's the only thing I know could produce the output you want. Now there is still problem with recasting freeze target would not unfreeze target, I will try to figure out a way. Link to comment Share on other sites More sharing options...
SeraphimKensai Posted August 11, 2013 Share Posted August 11, 2013 (edited) I tried adding the spells to my follower, but only the aimed version worked.. ...Can you make a version only for the freeze all hostiles, since it would be pointless for a follower to freeze my own character or my other followers. There is no unfreeze, and those that have the MagicEffectKeyword won't be affected as well.That would be amusing at first and then would drive me crazy if a follower accidentally froze me in place forever. If they did manage to freeze you, you'd have to counteract it via console commands. Edited August 11, 2013 by SeraphimKensai Link to comment Share on other sites More sharing options...
blacksupernova Posted August 12, 2013 Share Posted August 12, 2013 Hi blacksupernova, can I make one last request? I tried adding the spells to my follower, but only the aimed version worked. The AoE versions make my game crash. I think followers will only use spells that are aimed, not on self. I don't know, maybe the aimed spell that spreads out, kinda like the pacify spell might work. Can you make a version only for the freeze all hostiles, since it would be pointless for a follower to freeze my own character or my other followers. There is no unfreeze, and those that have the MagicEffectKeyword won't be affected as well. Can you pls make it a seperate file as I will using it for the follower only, not my character. It is no problem. Just one thing, I don't understand why the AOE version would crash your game. I tried adding it to a bandit and they use it fine. Making it a separate file would stir a few problems, the keyword I made for the spell to check in the previous mod would not be available for the new file to check so there is no telling what would happen if you cast freeze spell and then your follower cast another version at the same target. I think it's better to just add it to the previous mod. I tried adding the spells to my follower, but only the aimed version worked.. ...Can you make a version only for the freeze all hostiles, since it would be pointless for a follower to freeze my own character or my other followers. There is no unfreeze, and those that have the MagicEffectKeyword won't be affected as well.That would be amusing at first and then would drive me crazy if a follower accidentally froze me in place forever. If they did manage to freeze you, you'd have to counteract it via console commands. No no, the spell works by temporarily disable AI of the target. Since the player has no AI, the player would not be affected by it. Link to comment Share on other sites More sharing options...
firepower02 Posted August 12, 2013 Author Share Posted August 12, 2013 Ok, maybe I did it wrong. How did you add the AoE freeze hostile to a bandit? Usually, if they are cast on self spells, my followers won't use it, maybe I did something wrong. Also, where can I find to adjust the cooldown time? I only found the magicka cost, and the time it takes to cast, but not the cooldown. I want my follower to use it only every 15-20 secs, the freeze target which I got to work, he keeps using it, the only work around I was able to do was give it a high magicka cost so he would stop, but it's unconvetional, and he doesn't always hit. Link to comment Share on other sites More sharing options...
firepower02 Posted August 12, 2013 Author Share Posted August 12, 2013 (edited) Pls disregard my last request. I was able to make it work as a projectile area spell by changing the area to 100. So my follower does not have to exactly aim the enemy to freeze them. What I couldn't still find is the orignal base time, the time minus/hit, and the time minus every target's lvl > caster, and the time plus every target's lvl < caster. The spell cooldown as well, does the game have a setting for a spell cooldown? Edited August 12, 2013 by firepower02 Link to comment Share on other sites More sharing options...
blacksupernova Posted August 13, 2013 Share Posted August 13, 2013 Alright, I shall explain the script to you This part control the time that target will be frozen: Bool bKeepUpdating = False {flag to check if the timer should continue to count} Bool SpellWork = False {flag that set when the spell will work} Bool SpellInitiate = False Bool property AnimalCheck = False auto Int Bonus {an integer value, Bonus is the extra seconds the caster get when he is at certain level and is also the base duration of spell at any level} Int StopTime {total freeze time duration} Int Timer {a timer to check when to stop the effect, the freeze effect is terminate when Timer = StopTime (the total freeze time)} Int StopTimeMod {modification of freeze time based on caster and target's level} Event OnEffectStart(Actor Target, Actor Caster)Victim = TargetTimer = 0 {Timer initial value is 0, i.e: starting at second 0}If Caster.GetLevel() == 1 {check the level of the caster. if caster's level is 1, the spell is at its base duration that is 10 seconds}Bonus = 10 {caster's level = 1, Bonus = 10}Else {if caster's level is not 1, Bonus is calculated this way}Bonus = 5*(Caster.GetLevel() + 1) {caster gain 5 seconds for base duration for every level above 1}EndifIf Target.GetLevel() > Caster.GetLevel() {check if the target's level is higher than caster's level}StopTimeMod = (Target.Getlevel() - Caster.Getlevel())*2 {modification of freeze time equals 2 multiply difference of target and caster's level if target's level is higher}ElseStopTimeMod = 0 {if caster's level is higher than target's level, there is no modification of freeze time duration}EndifStopTime = Bonus - StopTimeMod {the total freeze time duration equals bonus from level subtract modification of freeze time}If StopTime > 0 {if total freeze time duration is greater than 0, that means the spell will work. it will be <= 0 if caster's level greatly lower target's level}bKeepUpdating = TrueSpellWork = TrueVictim.EnableAI(false)Victim.BlockActivation(True)RegisterForSingleUpdate(1.0)ElseFailMessage.Show()EndifEndEventThis part controls the reduce time when target is hit Event OnHit(ObjectReference akAggressor, Form akSource, Projectile akProjectile, bool abPowerAttack, bool abSneakAttack, bool abBashAttack, bool abHitBlocked)StopTime = StopTime - 3 {everytime the target is hit, the value of total freeze time duration is subtracted by 3, i.e: reduced by 3 seconds}EndEventTo make "cool down" effect, you can create a blank effect using Script as Archtype, set Score in Script Effect AI data to 1000000000 (this help prioritize the effect) and check Recover flag. Add the effect to the spell and set the duration to 60/120. NPC won't attempt to use the spell on the same target if this effect persist. Link to comment Share on other sites More sharing options...
firepower02 Posted August 16, 2013 Author Share Posted August 16, 2013 Ok if I understand it correctly, if the caster is level 1, his power to freeze is 10 secs, if he is level 2, he gains 5 secs more, so 15 secs, and if he is level 3 it will be 20 secs, and so on. The place where I change the base time is at:Bonus = 10The place where I change how much secs is added if caster is above level 1 is:Bonus = 5*(Caster.GetLevel() + 1)The place where I subtract the secs if the target is higher in level than caster is:StopTimeMod = 0 (I change that to 1, if i.e. caster is level 1, and target is level 5, then 10 secs minus (5-1 = 4) secs, so target will be frozen for 6 secs)And the part where I change the secs subtracted everytime the target gets hit is:StopTime = StopTime - 3 Please correct me if I'm wrong. When casting it again on frozen targets, they actually get to move a little bit. Did you intentionally do that, can it be turned off so when recasting, they won't be able to move even for just a bit. For the cooldown effect, do you mean, I duplicate the magic effect, rename it as cooldown, remove the scripts, set AI data to 1000000000000 and check recover flag. Then add it to the effects of the spell, and set it's duration to 60 secs? Is that correct? Npcs won't use it for another 60 secs, or is it npcs won't use it if target is currently frozen, but will use it on other targets if there are that aren't frozen? This cooldown effect trick, does it work or the player as well? By using this method, can this be applied to other spells to give them a cooldown? Link to comment Share on other sites More sharing options...
blacksupernova Posted August 16, 2013 Share Posted August 16, 2013 The place where I change the base time is at:Bonus = 10The place where I change how much secs is added if caster is above level 1 is:Bonus = 5*(Caster.GetLevel() + 1) Correct, but note that this equation only works for 5 seconds per level, if you want, say 7 sec per level, you will need a whole new equation, not just changing the number 5. The place where I subtract the secs if the target is higher in level than caster is:StopTimeMod = 0 (I change that to 1, if i.e. caster is level 1, and target is level 5, then 10 secs minus (5-1 = 4) secs, so target will be frozen for 6 secs) No, not correct. The whole condition is: If Target.GetLevel() > Caster.GetLevel() {check if the target's level is higher than caster's level}StopTimeMod = (Target.Getlevel() - Caster.Getlevel())*2ElseStopTimeMod = 0EndifIt means that if target's level is higher than caster, StopTimeMod = (Target's level - Caster's level)*2 (2 seconds for every level difference of target and caster), if target's level is not higher than caster's level (hence Else), StopTimeMod = 0. If you want to change the amount of secs subtracted for higher level, change the number 2 in StopTimeMod = (Target.Getlevel() - Caster.Getlevel())*2 to what you want. For the cooldown effect, do you mean, I duplicate the magic effect, rename it as cooldown, remove the scripts, set AI data to 1000000000000 and check recover flag. Then add it to the effects of the spell, and set it's duration to 60 secs? Is that correct? Npcs won't use it for another 60 secs, or is it npcs won't use it if target is currently frozen, but will use it on other targets if there are that aren't frozen? This cooldown effect trick, does it work or the player as well? By using this method, can this be applied to other spells to give them a cooldown? NPC will not use the spell on the target that is currently affected by that spell's effect, NPC will still use it on new target. This method is meant to trick the AI of NPCs. It works for other spells as well. When casting it again on frozen targets, they actually get to move a little bit. Did you intentionally do that, can it be turned off so when recasting, they won't be able to move even for just a bit. No, it is not meant to happen, I tried to avoid the message "Target resisted spell" when recasting due to the freeze effect is blocked but I just can not come to a good enough solution. So here, this version will not make them move anymore. Link to comment Share on other sites More sharing options...
Recommended Posts