@glennj Is your issue specifically with the Go version or the exercise in general? (Just to be clear). From glancing, I’m guessing its the fact that the stub refers to things (e.g. Action) that aren’t defined anywhere you can see (in fact, not defined anywhere at all as far as I can tell)?
I have a gut feeling that this is an exercise that can really benefit from some concept exercises that don’t exist yet (but I’m sure are probably on a roadmap): goroutines, channels, etc.
The appended instruction talk about the exercise as a “physics engine”, so perhaps it’s more comprehensible for people comfortable in the guts of game development.
It seems there are some unspoken assumptions that I’m not seeing. For example, the StartRobot function does not have a Robot entity as either an input or an output. There’s something about contemplating a “thread” as the robot that is eluding me.
This is an exercise I admit I haven’t solved myself yet, and I don’t remember this exercise being revisited in the time I’m a maintainer for Go (a little over a year now). So it’s possible some things are outdated and not in line with everything else on the track.
I just resolved this exercise and have some feedback:
You should know about build constraints to understand the test commands. Here even the old obsolete form is written in the Code, which confuses my GoLand installation. The go.mod states Go 1.18 already.
While the exercise has three steps, the main code file introduces code for later steps. So could be commented with so notes to make starting with step 1 easier.
Step 2 talks about goroutines and channels which is a core feature of Go. I hope I can provide my first suggestions for concept exercises, soon.
Talking about a “physic engine” sounds a bit big. At the end the “physic” sounds like it’s only about position projection within the room. With kind of “collision detection”. This “physic” decides if a step is possible or not.
With step 3 the concurrent approach makes sense.
In summary you’re quite open with your implementation and you need to understand the tests. While it’s written in the text, especially for step 3, I have to read the tests carefully.