Carlos Carvalho
Registered
Hey,
First of all i never developed a plugin for either rF1 or rF2 so i don´t really know how hard will it be but i´ll give it a try anyway.
Since this is my first contact with rF plugins i will appreciate all the help possible from experienced developers.
My idea is very simple but will bring another touch of realism to our rF2 races.
As you all know, rFactor lets drivers press ESCAPE during sessions and return to the track in a blink of an eye. This is something very unreal and allows everyone to "hotlap" with no fear of "killing" the vehicle.
My intention is to create a plugin that prevents drivers from returning to the track, in a given session (besides Testing), after they press ESCAPE outside the pitlane.
As i can see in the InternalsPlugin.hpp there is a way to know if the car is in the pitlane:
bool mInPits;// between pit entrance and pit exit (not always accurate for remote vehicles)
or
unsigned char mPitState; // 0=none, 1=request, 2=entering, 3=stopped, 4=exiting
There is also a way to know the type of the current session:
long mSession; // current session (0=testday 1-4=practice 5-8=qual 9=warmup 10-13=race)
So my questions are:
- Is there a way to block(grey) the Race button? (maybe: bool mServerScored;// whether vehicle is allowed to participate in current session)
- How can i detect the ESC button was pressed to exit to pits.
Thanks in advance,
Carlos Carvalho
First of all i never developed a plugin for either rF1 or rF2 so i don´t really know how hard will it be but i´ll give it a try anyway.
Since this is my first contact with rF plugins i will appreciate all the help possible from experienced developers.
My idea is very simple but will bring another touch of realism to our rF2 races.
As you all know, rFactor lets drivers press ESCAPE during sessions and return to the track in a blink of an eye. This is something very unreal and allows everyone to "hotlap" with no fear of "killing" the vehicle.
My intention is to create a plugin that prevents drivers from returning to the track, in a given session (besides Testing), after they press ESCAPE outside the pitlane.
As i can see in the InternalsPlugin.hpp there is a way to know if the car is in the pitlane:
bool mInPits;// between pit entrance and pit exit (not always accurate for remote vehicles)
or
unsigned char mPitState; // 0=none, 1=request, 2=entering, 3=stopped, 4=exiting
There is also a way to know the type of the current session:
long mSession; // current session (0=testday 1-4=practice 5-8=qual 9=warmup 10-13=race)
So my questions are:
- Is there a way to block(grey) the Race button? (maybe: bool mServerScored;// whether vehicle is allowed to participate in current session)
- How can i detect the ESC button was pressed to exit to pits.
Thanks in advance,
Carlos Carvalho