detrs
Members-
Posts
8 -
Joined
-
Last visited
detrs's Achievements
-
That's funny because that's exactly what I had in the first iteration. My logic stated pretty much all of that and I found it to be just too much, and it was like if you dont have all these items, and you have either necklacklace 5,4,3,2, or 1, and you havent blah blah. It just got to be too much. Using the quest stages fixed that, but ran into the problem of not being able to pick up where it left off. I've been messing around with what you said, and I see how I could make it do a little of both of what I was trying to do with configs. Definitely was very helpful!
-
public static Enum_Imp_Catcher handleImpCatcherQuestState() { if (Macros.questStage == 0) { return Enum_Imp_Catcher.Dont_Have_Imp_Items; } else if (Macros.questStage == 1) { return Enum_Imp_Catcher.Imp_Bank; } else if (Macros.questStage == 2) { return Enum_Imp_Catcher.Walk_To_Imp_QuestGiver; } else if (Macros.questStage == 3) { return Enum_Imp_Catcher.Talk_To_Imp_QuestGiver; } return null; } This is my state machine for imp catcher,. It's obviously not the most complicated quest, but what i'm doing currently is doing a case, and when that case is done it ups the questStage boolean by one with questStage++. So it'll start off at 0, then walk to the grand exhange, set it to 1, bank and buy items and set to 2, walk to the questgiver and set to 3, and then talk to and finish the quest. Which works nice......if it's a one and done straight through. but if it gets to the questgiver....and the script stops for whatever reason. It will then walk allllll the way back to the GE and start over. I would need to retailor my state machine to incorporate configs, but that should be a better way to "save / check" progress? Or just use it in addition to what I have?
-
I've only been coding for a week or two now, so I'm really new to all of it in general and lacking in terminology, so sorry. I've been having a few problems with accounts saving / carrying over settings and pretty much everything in general like booleans and any variables. I tried to put some of it in an onStart and it partially fixed it. I have Imp Catcher and Witch's Potion completed and I was trying to get it to save each step I was on, which worked, but when I go to swap accounts it uses the last account. Until I close the client and sometimes just stop and start the script again will fix it. Is there a good way to handle dealing with this? This is just a little snippet of what I was trying to do with just the saving part / loading part in particular. I had it in the main class that accountName = Players.getLocal() public static final int QUEST_ID_IMP_CATCHER = 1; public static final int QUEST_ID_WITCHS_POTION = 2; public static void saveQuestStage(String accountName, int questId, int questStage) { String fileName = accountName + "_Quest" + questId + ".dat"; try (ObjectOutputStream oos = new ObjectOutputStream(Files.newOutputStream(Paths.get(fileName)))) { oos.writeInt(questStage); System.out.println("Saved quest stage: " + questStage + " for " + accountName + " - Quest " + questId); } catch (IOException e) { e.printStackTrace(); } } public static void loadQuestStage(String accountName, int questId, int questStage) { String fileName = accountName + "_Quest" + questId + ".dat"; try (ObjectInputStream ois = new ObjectInputStream(Files.newInputStream(Paths.get(fileName)))) { int loadedQuestStage = ois.readInt(); Macros.questStage = loadedQuestStage; System.out.println("Loaded quest stage: " + loadedQuestStage + " for " + accountName + " - Quest " + questId); } catch (IOException e) { e.printStackTrace(); Macros.questStage = 0; } }
-
It is an email registered account, not jagex.
-
I have a fully Zulrah ready account. I am the original owner of the account and it also has no bans or marks on it. Price is $15 USD and would prefer PayPal as payment or crypto is fine too. The account has Ava's and full void set with range and mage helm. Message me for any info or offers!
-
Damn, I was thinking it might be around there. Little out of what I was willing to pay though. Thanks for the info!
-
I was wondering how much a private scrip would cost. I want it to make Muspah accounts for me in one go. Train all the stats required for Secrets of the North along with doing the quest and all its pre quests. Any info or pricing would be apprecaited. Thanks!