Widget Workshop (1996) was my favorite: with a large selection of widgets (such as logic gates, switches, displays, number generators, sound and graphics modules) you build 'functional cause and effect pipelines' in a a cute drag and drop canvas. There is a puzzle mode too. Very Rube Goldberg. Great fun, and educational!
You might enjoy this writeup of the related "The Incredible Machine"
https://www.filfre.net/2018/06/the-incredible-machine/