ColorRamp node and Cycles

I am trying to replicate the ColorRamp trick done in the realistic earth tutorial to get the night lights to only show on the dark side of the planet. I see that in Cycles things are different. I am having a hard time figuring out this one. I am new to using nodes.

Here is my noob attempt

Any help is appreciated.

put Color Ramp before Diffuse Shader

The reason why it doesn’t work in Cycles is because the shading socket type (the green ones), are a new type of information specific to Cycles. The shading type is completely different from the others in that it stores actual information on how the rays being traced should behave and thus cannot be converted to or from the color, greyscale, and vector types (ie. it does have any basis in RGB data).

Currently, there’s no real way of mapping a shader to the intensity of the light hitting a part of an object, however, you can use a geometry node and a normal node to create a mask for the nighttime side of the Earth and use that to map the night texture.

@Ace Dragon: Would using a geometry and normal node work for an animation? I plan on doing a rotation animation with this. And what about procedural textures? Do they play a role in Cycles and if so how?