WondraBox Posted July 17, 2020 Share Posted July 17, 2020 Hello, I am looking for some help once again. I want to make an enchanted item (boots) that change the jump height ONLY of the person wearing them. I also would like the enchantment to be able to be disenchanted and learnable so the player can put it on other items. I found some scripting of someone who was doing a similar thing. They got their coding to work, but I cant figure out why it wont compile when I use it. Here is their script: Scriptname Fairy3rdPhaseJump extends activemagiceffect GlobalVariable Property JumpHeight AutoEvent onEffectStart(Actor akTarget, Actor akCaster) JumpHeight.SetValue( Game.GetGameSettingFloat("fJumpHeightMin") ) Game.SetGameSettingFloat("fJumpHeightMin", 200.0)EndEventEvent OnEffectFinish(Actor akTarget, Actor akCaster) Game.SetGameSettingFloat("fJumpHeightMin", JumpHeight )EndEventEvent OnCellLoad() ;JumpHeight.SetValue( Game.GetGameSettingFloat("fJumpHeightMin") ) Game.SetGameSettingFloat("fJumpHeightMin", 200.0)EndEventEvent OnPlayerLoadGame() JumpHeight.SetValue( Game.GetGameSettingFloat("fJumpHeightMin") ) Game.SetGameSettingFloat("fJumpHeightMin", 200.0)EndEvent I found this script on Lovers Lab (go figure)..... Here is the link to the forum. I could not figure out what I was missing and re-read the forum a few times. : https://www.loverslab.com/topic/104441-some-scripting-help/And when I copied this script into my mod I did not copy the script name, I used my own. I am basically looking for a formula that I can just plug some numbers into and change the jump height of the player while they are wearing the enchanted item. All I really need is the jump height. I know how to turn off fall damage via enchant so that part is covered. Link to comment Share on other sites More sharing options...
dylbill Posted July 17, 2020 Share Posted July 17, 2020 It looks like that script should be working. Did you attach it to the magic effect that's on your enchantment? You also don't need the OnPlayerLoadGame and OnCellLoad events. Link to comment Share on other sites More sharing options...
WondraBox Posted July 17, 2020 Author Share Posted July 17, 2020 So if I get rid of those last two paragraphs :Event OnCellLoad() ;JumpHeight.SetValue( Game.GetGameSettingFloat("fJumpHeightMin") ) Game.SetGameSettingFloat("fJumpHeightMin", 200.0)EndEventEvent OnPlayerLoadGame() JumpHeight.SetValue( Game.GetGameSettingFloat("fJumpHeightMin") ) Game.SetGameSettingFloat("fJumpHeightMin", 200.0)EndEventIt should work if get rid of these two paragraphs right? Is there any other tinkering that I need to remove? Like the quotations are good and everything? It should work as exactly written? Let me try it later today and I will let you know if it works after removing those two sections of code. Thank you for looking over it for me! Link to comment Share on other sites More sharing options...
dylbill Posted July 18, 2020 Share Posted July 18, 2020 Actually I just read your original post. This script would only change the jump height for the player I believe, as it changes the game setting. I'm not sure if it's possible to change the jump height for NPC's or not. I did see an error in the script too, it should be: Scriptname Fairy3rdPhaseJump extends activemagiceffect GlobalVariable Property JumpHeight Auto Event onEffectStart(Actor akTarget, Actor akCaster) JumpHeight.SetValue(Game.GetGameSettingFloat("fJumpHeightMin")) Game.SetGameSettingFloat("fJumpHeightMin", 200.0) EndEvent Event OnEffectFinish(Actor akTarget, Actor akCaster) Game.SetGameSettingFloat("fJumpHeightMin", JumpHeight.GetValue()) EndEvent You also would have to make the JumpHeight global variable in the CK. If you didn't want to use the global variable you could do this instead: Scriptname Fairy3rdPhaseJump extends activemagiceffect Float JumpHeight Event onEffectStart(Actor akTarget, Actor akCaster) JumpHeight = Game.GetGameSettingFloat("fJumpHeightMin") Utility.Wait(0.25) Game.SetGameSettingFloat("fJumpHeightMin", 200.0) EndEvent Event OnEffectFinish(Actor akTarget, Actor akCaster) Game.SetGameSettingFloat("fJumpHeightMin", JumpHeight) EndEventAgain this will only change the jump height of the player I believe. You could also try changing the magic effect's archetype to value modifier, and setting the Assoc. Item 1 to Jumping Bonus. I'm not sure if that works but it's worth a shot. Link to comment Share on other sites More sharing options...
WondraBox Posted July 19, 2020 Author Share Posted July 19, 2020 I basically just need it to change the players jump height. I believe there is a console command that people like to use to alter their jump height, but that changes the players and all NPC's jump height, and I dont really want that. I just want to alter the players jump height while wearing the enchant and then for it to go back to normal once the enchanted item is removed. Link to comment Share on other sites More sharing options...
WondraBox Posted July 21, 2020 Author Share Posted July 21, 2020 (edited) Sorry it took me so long to get back to you. So I tried both sets of code you left and neither one compiled. I really dont know why they didnt. I copied them in exactly as you posted (minus the script name because I used my own script name). I apologize for my lack in papyrus coding knowledge. Its very confusing to me.And yes, I did put the script on a magic effect, it just will not compile.this is the error i received for the first script you gave:Starting 1 compile threads for 1 files...Compiling "IncreaseMaxJumpHeight"...C:\Program Files (x86)\Steam\steamapps\common\Skyrim Special Edition\Data\Source\Scripts\temp\IncreaseMaxJumpHeight.psc(7,9): SetGameSettingFloat is not a function or does not existC:\Program Files (x86)\Steam\steamapps\common\Skyrim Special Edition\Data\Source\Scripts\temp\IncreaseMaxJumpHeight.psc(7,9): cannot call the member function SetGameSettingFloat alone or on a type, must call it on a variableC:\Program Files (x86)\Steam\steamapps\common\Skyrim Special Edition\Data\Source\Scripts\temp\IncreaseMaxJumpHeight.psc(11,9): SetGameSettingFloat is not a function or does not existC:\Program Files (x86)\Steam\steamapps\common\Skyrim Special Edition\Data\Source\Scripts\temp\IncreaseMaxJumpHeight.psc(11,9): cannot call the member function SetGameSettingFloat alone or on a type, must call it on a variableNo output generated for IncreaseMaxJumpHeight, compilation failed.I dont know if this helps or not.Batch compile of 1 files finished. 0 succeeded, 1 failed.Failed on IncreaseMaxJumpHeight Edited July 21, 2020 by WondraBox Link to comment Share on other sites More sharing options...
ReDragon2013 Posted July 21, 2020 Share Posted July 21, 2020 If you do not have installed SKSE, script will not compile. https://www.creationkit.com/index.php?title=SetGameSettingFloat_-_GameYou are using "Skyrim Special Edition" there is another forum here on Skyrim Nexus:https://forums.nexusmods.com/index.php?s=94c3cd51c5e70f7ba7251839a737ff4b&c=4040,4045https://forums.nexusmods.com/index.php?/forum/4070-skyrim-special-edition-creation-kit-and-modders/ Link to comment Share on other sites More sharing options...
WondraBox Posted July 21, 2020 Author Share Posted July 21, 2020 Oh snap! i thought i was on the SE forum! Sorry about that. i will go over there then, thanks!and yes I do have SKSE. Link to comment Share on other sites More sharing options...
Recommended Posts