This is not directly electrical, but I am working on making a real life version of a coin block from Mario. Basically I use an LDR and to detect if someone punches the block and then use a transistor to turn on a DC motor.
The problem is that I want to be able to 'shoot' a coin up from the box using the motor, but I am not sure how I could achieve this. I have tried attaching some objects to the motor, which then hits a stationary coin, but that isn't very effective.
In summary, I want to be able to use a motor to shoot a coin up against gravity,
To shoot a coin, you need a fair amount of speed. A DC motor will probably accelerate too slowly to achieve the required speed in such a short distance. My advice would be to use something with less travel but more speed.
A solenoid can be used punch something pretty hard. They typically travel less than an inch, but with a good current pulse, will kick pretty hard. If you don't have enough current available, then you can charge up a large capacitor, and discharge it suddenly into the solenoid.
Alternatively, you can mount the coin on a spring which is held back by a little solenoid. When you energise the solenoid, it pulls back a catch which releases the spring which fires the coin. The down side is that you would have to re-set the mechanism each time. (or you could use a motor to pull the catch).
Lastly, as David Kessner suggested, you could have a pair of counter-rotating flywheels. Whacking the box pushes the coin into the wheels, which grip it and throw it skyward. The downside to this is that you need to keep the power on to keep the wheels spinning, which is a bit of a waste.