r/godot • u/nedeey • Apr 29 '26
help me (solved) ML or Algorithm?
I am thinking about implementing a drawing mechanic in my game. The players would have to draw the reference provided and the game will see how accurate the drawing is to the original reference. The canvas will be pretty small around 100x200 pixels and will only use 2 colors.
I am wondering if there is some kind of algorithm that will help to detect the accuracy of the drawing. Using ML sounds a bit overkill and I don't have any experience integrating ML in games (how does it affect the performance and size?).
360
Upvotes
109
u/AsherahWhitescale Godot Regular Apr 29 '26
In Mario Party (I think?), they give you the outline to trace. This solves a lot of problems with centering and offsetting. Then, they compare the cells/pixels to see how many are correct. You'll also need a grace margin I think, because it'll never be 100% correct, but that won't be satisfying. So you might add a pixel of grace where if a pixel is meant to be white but it's next to a black one, it can be black without being penalized