WAZAAAAA0 / TekkenBot

AI and tools for playing and understanding Tekken 7
MIT License
210 stars 45 forks source link

Suggestion : Text to speech on opponent moves used in real-time #22

Open phantomsom opened 4 years ago

phantomsom commented 4 years ago

Hi there, I really love the effort you poured in into this project!

This suggestion is created on the objective on learning matchups faster as they happen in a real match

I feel like having a text to speech feature announcing the string's type [ low ,mid or high ] and your frame advantage or disadvantage on block in matches can really be beneficial in learning matchups as fast as possible.

Having an automated voice announcing your frame advantage and disadvantage as it happens in real time can help people identify what they need to do exactly against certain moves used against them.

For example : Your opponent Noctis uses 2,2,2,2,2 on you in a player match

This new feature would then output an automated voice "Mid, Mid, High, High, Mid" in real time as the move happens, and also announces the final frame advantage when you block that attack.

This allows players to identify their methods of punishing strings as fast as possible within the same match without

1) Waiting for the match to be over 2) Spending time to navigate through the menu to practice mode [while waiting for the in-game UI to change scenes] 3) Then. finally labbing the moves and then hoping that they face noctis in the near future. [Which might not happen in a long time making you forget what to do when the move comes]

Is this feature possible?

I have experience in coding in python before so do let me know if you want me to try and tackle this feature together!

ComputerMachine commented 4 years ago

Yes it's possible and probably pretty easy

ComputerMachine commented 4 years ago

What I don't understand is that if my oppenent inputs 2,1,2 the input will register something like:

2 1 2,1,2 2

phantomsom commented 4 years ago

Hello there,

Yes that is a bit confusing but it shouldn't be a problem for this feature

image image

For example, akuma's DF2,4,3 [Don't ask me why it's outputting 1,4,3 instead]

What you stated shouldn't be a problem because the type column [second column] filters out only "MID" so voicing out only the type of attack shouldn't be a problem,

if voicing out the actual strings is required however, that will be a bit problematic because of inaccurate commands in the commands column like you said

ComputerMachine commented 4 years ago

do you also find that sometimes in matches Bot and Opp methods are switched? like im monitoring opponent moves and it shows mine instead

ComputerMachine commented 4 years ago

a quick remedy is switching the values on lines 228, 229 in TekkenGameState.py,

p1_bot.player_data_dict['PlayerDataAddress.'+data_type] = p1_value p2_bot.player_data_dict['PlayerDataAddress.'+data_type] = p2_value

not quite sure why these two would switch though, wrong address? depends on if the opponent chose left or right screen?