fg109 Posted April 16, 2012 Author Share Posted April 16, 2012 @leedavis I don't know about statics (though I think it's possible) but chairs are furniture property. I've used PlaceAtMe with furniture before and it worked fine. It's probably how camping mods create bedrolls and such as well. @Omeletter I haven't taken a look at the perk so I don't know if what you are doing will actually work. But the reason that the quest stage fragment is not compiling is because it doesn't actually use your perk quest script. When you create a quest stage fragment, then a quest fragments script is created (if it did not already exist). In your case, the script it is trying to create is "QF_zHOPerksQuest_01009F48". Unfortunately, I don't know of any way to force a quest to use a particular script as its quest fragments script. So what you need to do is to have only a semicolon ";" in the quest stage fragment. Compile it and now your quest should have the script "QF_zHOPerksQuest_01009F48" attached. Now edit that script and put in everything that you had in your perk quest script. Link to comment Share on other sites More sharing options...
leedavis Posted April 16, 2012 Share Posted April 16, 2012 Okay, I played around with the function you gave me "PlaceAtMe", this works so much better than "MoveTo" I'll be re-writing all me scripts to include this new function. Thanks much for you Time FG Link to comment Share on other sites More sharing options...
screamingabdab Posted April 16, 2012 Share Posted April 16, 2012 You sir could be just the man I'm looking for. I've been trying to modify the Shrine Blessing script to apply more than just the single buff. I've made the spells ready and tried several times myself, but it just applies the first spell 3 times instead of 3 seperate spells. So to confirm what I'm after is a Shrine Blessing that will do the normal Cure Disease and then apply 3 spells to the player. Many thanks if you can help me out :D Link to comment Share on other sites More sharing options...
Omeletter Posted April 16, 2012 Share Posted April 16, 2012 Wow, this actually works now, fg109! Thanks a lot! Everything you said is what I needed to do to make it compilable, and then I added more global values and well, it works for everything I needed! Thanks again. Link to comment Share on other sites More sharing options...
elseagoat Posted April 16, 2012 Share Posted April 16, 2012 How about tiered message script that uses formlists of messages and includes Back buttons to go to the previous message? I am having trouble with this. Well, trouble with the back button and with not using 74 properties of forms and a giant script with untold numbers of if statements. Link to comment Share on other sites More sharing options...
fg109 Posted April 16, 2012 Author Share Posted April 16, 2012 @screamingabdab If you modify the TempleBlessingScript to this, it should work: Scriptname TempleBlessingScript extends ObjectReference Conditional Spell Property TempleBlessing Auto Spell Property TempleBlessing02 Auto Spell Property TempleBlessing03 Auto Event OnActivate(ObjectReference akActionRef) TempleBlessing.Cast(akActionRef, akActionRef) TempleBlessing02.Cast(akActionRef, akActionRef) TempleBlessing03.Cast(akActionRef, akActionRef) if akActionRef == Game.GetPlayer() AltarRemoveMsg.Show() BlessingMessage.Show() endif EndEvent Message Property BlessingMessage Auto Message Property AltarRemoveMsg Auto However, I don't think it's a good idea to modify vanilla scripts/objects if you plan on ever releasing the mod. I haven't actually modified any vanilla object so I don't know how this will work through loading/unloading mods, but you can try editing the reference for the shrines in the render window and removing their TempleBlessingScript with a new script based on the one I just posted. @elseagoat Creating a script for menus is sort of impossible if I don't know how the menu layout is supposed to work. How am I supposed to know how many choices each menu is supposed to be? Link to comment Share on other sites More sharing options...
screamingabdab Posted April 16, 2012 Share Posted April 16, 2012 Cheers FG, ahh can I not just write a new blessing script for my shrine then? thought i'd be able to do that. Link to comment Share on other sites More sharing options...
elseagoat Posted April 16, 2012 Share Posted April 16, 2012 (edited) Scriptname ESG_RefundMessageScript extends ActiveMagicEffect GlobalVariable Property ESG_RefundPoints Auto Message Property ESG_MainMenuRefund Auto Message Property ESG_MagicalRefund Auto Message Property ESG_PhysicalRefund Auto FormList Property ESG_SkillMessageLists Auto FormList Property ESG_GroupMessageLists Auto Formlist Property ESG_PerkMessageLists Auto Spell Property ESG_RefundSpell Auto Actor Player Bool Show = true Int StyleChoice = -1 Int SkillChoice = -1 Int GroupChoice = -1 Int PerkChoice = -1 Int GroupIndex Int PerkIndex Int Points Function Messages(Int ListIndex) GroupChoice = ((ESG_SkillMessageLists.GetAt(ListIndex) as FormList).GetAt(SkillChoice) as Message).Show(Points) If (GroupChoice == 0 || GroupChoice == 1 || GroupChoice == 2 || GroupChoice == 3) GroupIndex = (GroupChoice + (SkillChoice * 4)) PerkChoice = ((ESG_GroupMessageLists.GetAt(ListIndex) as FormList).GetAt(GroupIndex) as Message).Show(Points) If (PerkChoice == 0 || PerkChoice == 1 || PerkChoice == 2 || PerkChoice == 3 || PerkChoice == 4 || PerkChoice == 5) PerkIndex = ((ListIndex * 5) + SkillChoice) Player.AddPerk((ESG_PerkMessageLists.GetAt(PerkIndex) as FormList).GetAt(PerkChoice) as Perk) ESG_RefundPoints.SetValueInt(Points - 1) Show = false Dispel() ElseIf (PerkChoice == 6) PerkChoice = -1 GroupChoice = -1 EndIf ElseIf (GroupChoice == 4) GroupChoice = -1 SkillChoice = -1 EndIf EndFunction Event OnEffectStart(Actor Target, Actor Caster) Player = Game.GetPlayer() Points = ESG_RefundPoints.GetValueInt() While Show ESG_MainMenuRefund.Show(Points) If (StyleChoice == 0) SkillChoice = ESG_MagicalRefund.Show(Points) If (SkillChoice == 0 || SkillChoice == 1 || SkillChoice == 2 || SkillChoice == 3 || SkillChoice == 4) Messages(0) ElseIf (SkillChoice == 5) SkillChoice = -1 StyleChoice = -1 EndIf ElseIf (StyleChoice == 1) SkillChoice = ESG_PhysicalRefund.Show(Points) If (SkillChoice == 0 || SkillChoice == 1 || SkillChoice == 2 || SkillChoice == 3 || SkillChoice == 4 || SkillChoice == 5) Messages(1) ElseIf (SkillChoice == 6) SkillChoice = -1 StyleChoice = -1 EndIf ElseIf (StyleChoice == 2) Show = false Dispel() EndIf EndWhile If (ESG_RefundPoints.GetValueInt() == 0) Player.RemoveSpell(ESG_RefundSpell) EndIf Dispel() EndEvent This script is supposed to show a series of messages. There are over 100 messages, and 4 "teirs" of messages. The first message, ESG_MainMenuRefund, has 3 buttons. A, B, and Exit. Exit is supposed to exit the while loop and do nothing, closing the message box. It doesn't, the box is stuck. A and B bring up two other menus. A is a menu with 6 options, 5 of them lead to even more menus while the 6th is supposed to go back to the main menu. B is similar, but has 7 options, again one goes back to the main menu. Each of the 5 menu options in A and 6 menu options in B to individual menus that are separate, but similar, as they all have 5 total options. The fifth option on all of these is supposed to take the player back to A or B, whichever they were on previously. The 4 other options in these menus go to even more menus, each with 7 options, 6 of which add a perk to the player, decrement the global variable by 1, and close the menu system. Again, the 7th goes back a menu. You will notice I tried to avoid linking all 100+ messages as properties and having massive if statements by using "two dimensional" formlists. Formlists inside of Formlists basically. Don't even know if that is working because I can't get that far. Problem is, I can't get past the first menu. None of the buttons respond when I click them, the first menu is stuck there and wont go away, preventing me from even leaving the game. Edited April 16, 2012 by elseagoat Link to comment Share on other sites More sharing options...
fg109 Posted April 16, 2012 Author Share Posted April 16, 2012 @screamingabdab Yes you can, I just thought that you wanted to change all the vanilla shrines instead of making a whole new shrine. @elseagoat Well the reason it's getting stuck right now is because of line 47. It should be: StyleChoice = ESG_MainMenuRefund.Show(Points) I'll look over it some more and see if I can think of how to improve the script. Link to comment Share on other sites More sharing options...
elseagoat Posted April 16, 2012 Share Posted April 16, 2012 (edited) @screamingabdab Yes you can, I just thought that you wanted to change all the vanilla shrines instead of making a whole new shrine. @elseagoat Well the reason it's getting stuck right now is because of line 47. It should be: StyleChoice = ESG_MainMenuRefund.Show(Points) I'll look over it some more and see if I can think of how to improve the script. Nice catch! Testing now. Will update. Edit: Works almost perfectly. Looks like I got my equations right, its pulling up the menus and perks from the proper indices and everything so they are all lining up with their choices. The only problem is that the "Previous Menu" buttons are taking me to the first menu, not to the previous menu. So say I pick Magical Skills -> Illusion ->Illusion Perk Group B and decide I don't want one of the illusion perks here, and I hit Previous Menu, it takes be back to the first menu asking if I want to add perks in Magical Skills or Physical Skills instead of taking me back to the menu asking me which illusion perk group I want. Its not a big deal, but I would rather not go through 100's of forms and change "Previous Menu" to "Main Menu" for clarity. Now I got to wondering why this is happening the way it is happening. Does Show() pause your script until the user selects an option to give it something to return, meaning the while loop is not running while a menu is active? Or does the while loop keep running? Edited April 17, 2012 by elseagoat Link to comment Share on other sites More sharing options...
Recommended Posts