-
Notifications
You must be signed in to change notification settings - Fork 14
Home
last updated: May 26 (formatting)
Do NOT use Nox. Switch to Memu.
I hope you are using Memu instead of Nox. Nox has memory issues that have something to do with HiroMacro and Nox Android 5 compatibility.
Table of Contents:
for some reason, order matters in the :lvlSkill
section, so you need to put the clauses of #justUnlockSkills == 1
first before #justUnlockSkills == 0
as stated in https://github.com/Tune389/Tap-Titans-2-Progress-Bot/issues/80
REPLACE your section of :lvlSkill
with this (just copy paste it)
:lvlSkill
if #minutes >= #maxSkillsAtXMinutes and #maxSkillsAtXMinutes > 0 and #unlocked < 8 and #skillCheckStepper <= 5
touchPress 0 459 755
sleep 300
#time = #time + 300
#unlocked = #unlocked + 1
endif
#time = #time + 100
getRGB #colorRed #colorGreen #colorBlue 459 755
if #colorBlue <= -45
sleep 10
#time = #time + 10
goto :endLvlSkill
elseif #justUnlockSkills == 1
if #skillCheckStepper < 6
if #unlocked < 4
#unlocked = #unlocked + 1
touchPress 0 459 755
sleep #btnDelay
#time = #time + #btnDelay
goto :endLvlSkill
elseif #unlocked >= 4
if #minutes < #maxSkillsAtXMinutes
goto :endLvlSkill
else
if #unlocked < 8
touchPress 0 459 755
sleep #btnDelay
#time = #time + #btnDelay
endif
goto :maxSkill
endif
endif
endif
elseif #justUnlockSkills == 0
goto :maxSkill
endif
goto :endLvlSkill
touchPress
, touchDown
, and touchUp
usually have an accompanying sleep T
Z is for hold; set Z to 1 if you want it to be held. Set to 0 if just a normal tap
X is for X coordinate
Y is for Y coordinate
T is for any number usually 50 at most
Code format/syntax:
touchPress format:
touchPress Z X Y
sleep T
touchDown touchUp combo format:
touchDown Z X Y
sleep T
touchUp Z X Y
sleep T
What you can do:
-
change
sleep
value to a higher number Usually,#btnDelay
should work, but the tradeoff is that it takes a horrible amount of time just to click a button. I do NOT recommend you use#btnDelay
for the hero level up section as this will take forever. The currentsleep
time of 40 +/- 5 seems to work the fastest with the least errors -
switch
touchPress
with thetouchDown
andtouchUp
combo or combinetouchDown
andtouchUp
into justtouchPress
-
use erratic values for the
sleep
timers in between touch commands an example is found in the code below. notice how thesleep
durations are different. In my runs, this only results to 3 successful taps. It could mean it's related to the number ofsleep
present
touchPress 0 415 750
sleep 34
touchPress 0 415 750
touchPress 0 415 750
touchPress 0 415 750
sleep 45
touchPress 0 415 750
sleep 38
- use both
touchPress
es withtouchDown
andtouchUp
comboes repetitive, but last resort
This is intended. I don't want to waste mana and the workaround for this is to set #runActionsEveryXSeconds
at a duration when all skills are done running. As mentioned already in-code
// recommended equal to total SC+ED+DShift duration minus ~6 or 7 seconds (or whatever skill lasts the longest for you
// ^esp if you cant level SC in the first run
// ^so that when runActions runs, SC is done and script can level up SC
// also note that displayed run time is not very accurate with real time
With the latest change having Astral Awakening in the taps section, the displayed time is quite off so find that sweet spot number when your skills just finish (it would also help to have similar activation times for your skills)
if you really do not want this function, look for
:lvlSkill
if #minutes >= #maxSkillsAtXMinutes and #unlocked < 8 and #skillCheckStepper <= 5
touchPress 0 459 755
sleep 300
#time = #time + 300
#unlocked = #unlocked + 1
endif
#time = #time + 100
getRGB #colorRed #colorGreen #colorBlue 459 755
if #colorBlue <= -45
sleep 10
#time = #time + 10
goto :endLvlSkill
elseif #justUnlockSkills == 0
goto :maxSkill
change getRGB #colorRed #colorGreen #colorBlue 459 755
to #colorBlue = 0
Make a new issue here on github. Describe to me the following:
- Are you using Memu instead of Nox?
- Apparently, Nox and Memu don't play scripts the same way, but since Memu has better memory handling, use Memu first if the script works there.
- What was supposed to happen in the script? What problem are you encountering?
- What were the last things the code was trying to do before this problem? Was it upgrading heroes or sword master? Was it trying to scroll down/up?
- Mention the script version by stating the latest date found at the top of the code
- Mention other things you think I should know about or something that happened that normally doesn't
- examples: "I think it kept clicking this area", "I encounter this problem only after CQ", etc.
- You can also speculate/suggest how I can edit the code to fix your problem
most notable recently with
#intervalHS 0
and/or#skipHS 1
Delete the section of the code you know you don't want to happen. If you're not familiar with coding, do not delete the section header name itself (e.g. :section
) and the goto :section
s within it (and I guess the accompanying conditionals related to it) just to make sure the code isn't lost. For the more advanced coders, of course, you're free to delete the whole section, with header and exit points, just make sure to redirect other sections to the appropriate after-sections.
Report and post an issue according the guidelines just above this. If you can think of workarounds for me as well, that would be lovely.
to quote djo_5296 from https://www.elitepvpers.com/forum/mobile-games/4224861-tap-titans-2-advanced-clickbot-hiromacro-55.html#post36559927
To everyone: Something weird with hiro (or at least mine) because a lot of my code used to work, then at a random point, parts of it just stopped (especially the color detecting for skills) so I had to work around those and as such, maybe like tommy, parts of the code may not work as I intended them to as they do work for me now