Rank: Newbie
Groups: Registered
Joined: 9/21/2021(UTC) Posts: 9 Location: Elektrėnai Was thanked: 1 time(s) in 1 post(s)
|
Originally Posted by: doggy Originally Posted by: titasas Originally Posted by: doggy Originally Posted by: titasas Originally Posted by: doggy Originally Posted by: titasas maybe something worked out Code:do while True
if Input.Find("home-powerplay.gtzip").Text("pp.Text") >= "0:01" then
API.Function("MultiViewOverlayOn", Input:="scoreboard.gtzip", Value:="1")
else
API.Function("MultiViewOverlayoff", Input:="scoreboard.gtzip", Value:="1")
end if
sleep(500)
Loop
take note theat the new name for the "MultiViewOverlay" is now simply "Layer" keep in mind that a script and the functions do need more than 0.01 secs to process . your sleep is half a second ! Thanks :) Now I'm thinking how to upgrade this code and also add them to change position. If input1 is more than 0:01, enable it. If at that time input2 is more than 0:01, turn it on as well. If input1 becomes empty, and input2 is still timed out, switch input1 off, move input2 to input1 position. At the end of the time, return to the previous position. If neither input gets time, both layers are disabled. Just translate your thought/logic into code (language), you know: if then else/elseif's and's and or's etc or are you trying to trick someone into doing that for you ;-) I tried to create that, but for me is too much "if" and "or", but you remember me that is "elseif". Just cant find function to move X layer position :? Can always use the setzoom, setpanx, setpanY to the input used in the layers instead Thanks, but elseif not work for me :| Code:[i]do while True
if Input.Find("home-powerplay2.gtzip").Text("pp.Text") >= "0:01" then
API.Function("MultiViewOverlayOn", Input:="scoreboard.gtzip", Value:="5")
elseif
Input.Find("home-powerplay.gtzip").Text("pp.Text") >= "0:01" and Input.Find("home-powerplay2.gtzip").Text("pp.Text") >= "0:01" then
API.Function("MultiViewOverlayOn", Input:="scoreboard.gtzip", Value:="1")
API.Function("MultiViewOverlayOn", Input:="scoreboard.gtzip", Value:="5")
elseif
Input.Find("home-powerplay.gtzip").Text("pp.Text") < "0:01" and Input.Find("home-powerplay2.gtzip").Text("pp.Text") >= "0:01" then
API.Function("MultiViewOverlayOff", Input:="scoreboard.gtzip", Value:="1")
API.Function("MultiViewOverlayOn", Input:="scoreboard.gtzip", Value:="5") and something with setpanX
else
API.Function("MultiViewOverlayOff", Input:="scoreboard.gtzip", Value:="1")
API.Function("MultiViewOverlayOff", Input:="scoreboard.gtzip", Value:="5")
end if
sleep(500)
Loop[/i]
And get Error Line 4 BC30201: Expression expected error
|