Eddio0141 / UniTAS

Tool that lets you TAS unity games
Other
19 stars 2 forks source link

[Bug]: mouse clicks not working when hovering over mod GUI (edited title) #292

Open Luna5829 opened 7 months ago

Luna5829 commented 7 months ago

What happened?

in the level select menu screen of the game Strata, mouse keys just aren't deterministic for some reason

https://github.com/Eddio0141/UniTAS/assets/102811601/4cb68068-7837-4f0e-a528-8ba20934ac63

What should have happened?

it should be fully deterministic if the same inputs are played twice but it ain't

UniTAS version

Latest main

BepInEx version

v5.4.x

Game name

Strata

Game build

Windows x64 - Mono

How to reproduce

MOVIE_CONFIG = {
    fps = 60
}

frame_advance = movie.frame_advance
press = key.hold
release = key.release

function Jump(Time)
    press("Space")
    frame_advance(Time)
    release("Space")
end

Jump()
frame_advance(41)
mouse.move(960, 840)
mouse.left()
frame_advance()
mouse.left(false)
frame_advance(17)

-- it'll sometimes load up the second level and sometimes it just won't

Log output

No response

Additional context

No response

Luna5829 commented 7 months ago

i didn't notice this earlier as i was able to tas level 1 because it's automatically selected, so pressing space in the level select screen automatically loads up level 1, but there's no way to load up level 2 other than mouse click

Luna5829 commented 5 months ago

it seems I've figured it out it works when my mouse is hovering over the game, and it doesn't work when my mouse is hovering over the "Movie Play" window so it's not an issue of determinism just with mouse clicks

funnily enough I accidentally did that in the video which is pretty obvious looking back on it lol

Eddio0141 commented 5 months ago

Ohh right yeah I didn't really think it was the menu UniTAS overrides a few functions to do inputs but nothing related with GUI class (the debug menu thing I use for my menu) The footage proves the game isn't using GUI and UniTAS can control it unless with the mouse over my menu I think there's a similar issue in another game I tested where the game UI wasn't working again