From what you say, I think the easiest thing to do is place any shared code into a function, then call that function from both the teleop and hybrid loops. If you need to, you could pass hybrid or teleop as a param to the function.
If you have other plans, you can use these functions/variables to get state info.
In EasyC
Code:
IsEnabled(); //In menu as Controller state
IsAutonomous(); //In menu as Competition state
In MPLab
Code:
autonomous_mode; //Defined in ifi_defaults.h
//For disabled there are previous discussions.