Your making a basic mistake, Ek=.5m*v^2=J is not just part of the photoe;ectric effect. rathe rit is the formula for any measurement of kinetic energy.
When measuring the total (muzzel) energy of a projectile the formula is .5M*v^2=J
 Kinetic energy of rigid bodies
In classical mechanics, the kinetic energy of a "point object" (a body so small that its size can be ignored), or a rigid non rotating body, is given by the equation where m is the mass and v is the speed of the body.
For example - one would calculate the kinetic energy of an 80 kg mass traveling at 18 meters per second (40 mph) as .
Note that the kinetic energy increases with the square of the speed. This means, for example, that if you are traveling twice as fast, you will have four times as much kinetic energy. As a result of this, a car traveling twice as fast requires four times as much distance to stop (See mechanical work).
Thus, the kinetic energy can be calculated using the formula:
For the translational kinetic energy of a body with constant mass m, whose center of mass is moving in a straight line with speed v, as seen above is equal to
m is mass of the body
v is speed of the center of mass of the body.