Ok heres the deal. Simply put, when you move the gear handle up and down you are sending an electronic signal to a pump that will move hydraulic fluid in one direction or the other to move the gear up or down....looks like a cork screw. Like others have said the gear does not need fluid to start the gear down position, however for anyone that has seen a 172RG will notice that the gear sits in a forward stance, towards the nose when all is down and locked.
When the gear is selected to the down position. The pump turns the cork screw in the opposite direction sending hydraulic fluid in the system in the opposite direction which will let the gear start to fall. The gear unsafe light now comes on. Hydraulic fluid IS required to be bring the gear INTO the down locks. There are 3 connections that need to be made for the GREEN down indicator light to come on. If any of the 3 are not down and locked = no light.
When the gear is selected up, the pump pushes fluid, thats it, once it reaches 1500 psi, the pump turns off, and so does the gear unsafe light....As long as you have fluid holding that psi, the gear stays up, and the lights stay off.
So to answer your question..... If you are on the ground and the master switch is on, yet you have no fluid, you WILL still have a light.
NOW.....If you loose your hydraulic fluid inflght you will notice this happening because the gear will begin to hear the hydraulic actuator kicking on, (the pump) as well as probably seeing a gear unsafe light (depending on your serial number, some have an in transit light and some have a gear unsafe. They pretty much do the same thing, but ones red and the other is amber)
This happens because the motor shuts off after it reaches the 1500 psi mark remember.....soooo if you go under that magic number, the motor kicks on, sooooo if you have a hole somewhere in your lines, the motor is now pumping the hydraulic fluid out of the system. soooo put the gear down and keep it down...assuming you still have enough fluid in the system to get into the down locks. (not sure the amount, but doesn't matter, you don't have a gauge in the cockpit anyway)
If you lose ALL fluid, the gear should be hanging under the airplane... flapping in the wind... You will have to manually pull the gear forward into a locked position. Using the emergency gear handle will not help, because all it does is try to pump fluid (which you dont have) At the flight school I used to work at would keep a cane, yes like the ones old people use, just incase this situation arose. I've heard of some people throwing a headset out, wrapping the cord around the leg and pulling it into place. Use your checklist and dont forget to put the handle down in the first place!
Good luck, fly safe!