JcHARP Posted March 13, 2013 Share Posted March 13, 2013 Ok so, I got this perk ingame and I want it to give 350 caps per day. I get it to work the first time, but how come it will not work over and over again? SCN FWarsQ00PerksScriptShort FWOnceShort FWOnce2Short FWOnce3Short FWOnce4Short FWOnce5Begin GameMode;---------------------------------------------This is for FWarsQ01o1 Perk If GetCurrentTime >= 24 && GetCurrentTime < 0 Set FWOnce to 0 EndIf If Player.HasPerk FWarsQ01o1Perk && FWOnce == 0 && Player.GetLevel <= 10 && GetCurrentTime >= 0 && GetCurrentTime < 24 Player.AddItem Caps001 350 Set FWOnce to 1 EndIfEnd What am I doing wrong? Link to comment Share on other sites More sharing options...
Slikpik Posted March 13, 2013 Share Posted March 13, 2013 Let me try and fix that for you Link to comment Share on other sites More sharing options...
Slikpik Posted March 13, 2013 Share Posted March 13, 2013 Not tried it, but it should work. It will add 350 caps to the player once a day at 12 I hope. Try it and tell me scn ScriptName ref Caps Begin GameMode Set Caps to Caps001 If Player.HasPerk FWarsQ01o1Perk if Player.GetLevel <= 10 && GetCurrentTime == 12.01 Player.AddItem Caps 350 endif endif end Link to comment Share on other sites More sharing options...
Slikpik Posted March 13, 2013 Share Posted March 13, 2013 Wait, part of that wont work...Ok I'm going to tell you how to do this properly, I've done this wrong Link to comment Share on other sites More sharing options...
Slikpik Posted March 13, 2013 Share Posted March 13, 2013 First, create two quests and tick Start Game Enabled on both boxes.Name the quest id's something like MySetupQuest and MyMainQuest Ok second, create a new script Put this in scn MySetupScript Short Stage Begin GameMode if (Stage != 1) SetQuestDelay MyMainQuest 0.1 Set Stage to 1 endif end Make the script type Quest. Open your set up quest and put that as the quest script. Now, open a new script and put this scn MyMainScript ref Caps Begin GameMode Set Caps to Caps001 If Player.HasPerk FWarsQ01o1Perk && (MySetupQuest.Stage == 1) if Player.GetLevel <= 10 && GetCurrentTime == 12.01 Player.AddItem Caps 350 endif endif end change that script type to quest too. Open up your main quest (MyMainQuest) and use that as the script. Hopefully, this should work Link to comment Share on other sites More sharing options...
jazzisparis Posted March 13, 2013 Share Posted March 13, 2013 No need for two quests/scripts here. As Slikpik suggested, make a new, start game enabled quest. Create a new quest-type script (and don't forget to make the new quest use it): scn FWarsQ00PerksScript float fTimer begin GameMode if player.HasPerk FWarsQ01o1Perk && (player.GetLevel <= 10) if fTimer == 0 set fTimer to GameDaysPassed elseif (GameDaysPassed - fTimer) >= 1 player.AddItem Caps001 350 set fTimer to 0 endif endif end Link to comment Share on other sites More sharing options...
JcHARP Posted March 14, 2013 Author Share Posted March 14, 2013 Thanks to both of you, it works now :) Link to comment Share on other sites More sharing options...
Recommended Posts