forked from speed-dreams/speed-dreams-code
- added mpa11 & mpa12 to simplix driver
git-svn-id: https://svn.code.sf.net/p/speed-dreams/code/trunk@6058 30fe4595-0a0c-4342-8851-515496e4dcbd Former-commit-id: c04a5ba9434522eb6488de7b25c4d259ef4d973a Former-commit-id: ca7951fed3c62bd7f18eaf7f308ce7d95cff519b
This commit is contained in:
parent
eeb3725822
commit
9a3210565f
3 changed files with 60 additions and 2 deletions
|
@ -74,7 +74,7 @@ SET(ROBOT_SOURCES
|
|||
|
||||
# Official-only simplix instances.
|
||||
SET(ROBOT_CLONES simplix_36GP simplix_sc simplix_srw simplix_trb1 simplix_ls1 simplix_ls2 simplix_mp5
|
||||
simplix_mpa1 simplix_lp1 simplix_ref)
|
||||
simplix_mpa1 simplix_mpa11 simplix_mpa12 simplix_lp1 simplix_ref)
|
||||
|
||||
# The ubiquitous robot module and its clones.
|
||||
ROBOT_MODULE(NAME ${ROBOT_NAME} VERSION 3.3.0 SOVERSION 1.0.0
|
||||
|
|
|
@ -109,6 +109,8 @@ extern GfLogger* PLogSimplix;
|
|||
#define RTYPE_SIMPLIX_LP1 8 // Robot type simplix_lp1
|
||||
#define RTYPE_SIMPLIX_REF 9 // Robot type simplix_ref
|
||||
#define RTYPE_SIMPLIX_SRW 10 // Robot type simplix_srw
|
||||
#define RTYPE_SIMPLIX_MPA11 11 // Robot type simplix_mpa11
|
||||
#define RTYPE_SIMPLIX_MPA12 12 // Robot type simplix_mpa12
|
||||
//==========================================================================*
|
||||
|
||||
//==========================================================================*
|
||||
|
|
|
@ -305,7 +305,7 @@ void SetUpSimplix()
|
|||
void SetUpSimplix_mpa1()
|
||||
{
|
||||
cRobotType = RTYPE_SIMPLIX_MPA1;
|
||||
SetParameters(NBBOTS, "indycar01");
|
||||
SetParameters(NBBOTS, "mpa1-murasama");
|
||||
TDriver::AdvancedParameters = true;
|
||||
TDriver::UseBrakeLimit = false;
|
||||
TDriver::UseMPA1Skilling = true;
|
||||
|
@ -314,6 +314,36 @@ void SetUpSimplix_mpa1()
|
|||
};
|
||||
//==========================================================================*
|
||||
|
||||
//==========================================================================*
|
||||
// Schismatic entry point for simplix_mpa11
|
||||
//--------------------------------------------------------------------------*
|
||||
void SetUpSimplix_mpa11()
|
||||
{
|
||||
cRobotType = RTYPE_SIMPLIX_MPA11;
|
||||
SetParameters(NBBOTS, "mpa11-murasama");
|
||||
TDriver::AdvancedParameters = true;
|
||||
TDriver::UseBrakeLimit = false;
|
||||
TDriver::UseMPA1Skilling = true;
|
||||
TDriver::SkillingFactor = 0.1f; // Skilling factor for career-mode
|
||||
TDriver::UseRacinglineParameters = true;
|
||||
};
|
||||
//==========================================================================*
|
||||
|
||||
//==========================================================================*
|
||||
// Schismatic entry point for simplix_mpa12
|
||||
//--------------------------------------------------------------------------*
|
||||
void SetUpSimplix_mpa12()
|
||||
{
|
||||
cRobotType = RTYPE_SIMPLIX_MPA12;
|
||||
SetParameters(NBBOTS, "mpa12-murasama");
|
||||
TDriver::AdvancedParameters = true;
|
||||
TDriver::UseBrakeLimit = false;
|
||||
TDriver::UseMPA1Skilling = true;
|
||||
TDriver::SkillingFactor = 0.1f; // Skilling factor for career-mode
|
||||
TDriver::UseRacinglineParameters = true;
|
||||
};
|
||||
//==========================================================================*
|
||||
|
||||
//==========================================================================*
|
||||
// Schismatic entry point for simplix_trb1
|
||||
//--------------------------------------------------------------------------*
|
||||
|
@ -549,6 +579,10 @@ int moduleWelcomeV1_00
|
|||
SetUpSimplix_36GP();
|
||||
else if (strncmp(RobName,"simplix_mpa1",strlen("simplix_mpa1")) == 0)
|
||||
SetUpSimplix_mpa1();
|
||||
else if (strncmp(RobName,"simplix_mpa11",strlen("simplix_mpa11")) == 0)
|
||||
SetUpSimplix_mpa11();
|
||||
else if (strncmp(RobName,"simplix_mpa12",strlen("simplix_mpa12")) == 0)
|
||||
SetUpSimplix_mpa12();
|
||||
else if (strncmp(RobName,"simplix_ls1",strlen("simplix_ls1")) == 0)
|
||||
SetUpSimplix_ls1();
|
||||
else if (strncmp(RobName,"simplix_ls2",strlen("simplix_ls2")) == 0)
|
||||
|
@ -837,6 +871,28 @@ static int InitFuncPt(int Index, void *Pt)
|
|||
cInstances[Index-IndexOffset].cRobot->SideBorderOuter(0.00f);
|
||||
cInstances[Index-IndexOffset].cRobot->UseFilterAccel();
|
||||
}
|
||||
else if (cRobotType == RTYPE_SIMPLIX_MPA11)
|
||||
{
|
||||
LogSimplix.debug("#cRobotType == RTYPE_SIMPLIX_MPA11\n");
|
||||
cInstances[Index-IndexOffset].cRobot->CalcSkillingFoo = &TDriver::CalcSkilling_simplix_MPA1;
|
||||
cInstances[Index-IndexOffset].cRobot->CalcFrictionFoo = &TDriver::CalcFriction_simplix_Identity;
|
||||
cInstances[Index-IndexOffset].cRobot->CalcCrvFoo = &TDriver::CalcCrv_simplix_Identity;
|
||||
cInstances[Index-IndexOffset].cRobot->CalcHairpinFoo = &TDriver::CalcHairpin_simplix;
|
||||
cInstances[Index-IndexOffset].cRobot->ScaleSide(0.95f,0.95f);
|
||||
cInstances[Index-IndexOffset].cRobot->SideBorderOuter(0.00f);
|
||||
cInstances[Index-IndexOffset].cRobot->UseFilterAccel();
|
||||
}
|
||||
else if (cRobotType == RTYPE_SIMPLIX_MPA12)
|
||||
{
|
||||
LogSimplix.debug("#cRobotType == RTYPE_SIMPLIX_MPA12\n");
|
||||
cInstances[Index-IndexOffset].cRobot->CalcSkillingFoo = &TDriver::CalcSkilling_simplix_MPA1;
|
||||
cInstances[Index-IndexOffset].cRobot->CalcFrictionFoo = &TDriver::CalcFriction_simplix_Identity;
|
||||
cInstances[Index-IndexOffset].cRobot->CalcCrvFoo = &TDriver::CalcCrv_simplix_Identity;
|
||||
cInstances[Index-IndexOffset].cRobot->CalcHairpinFoo = &TDriver::CalcHairpin_simplix;
|
||||
cInstances[Index-IndexOffset].cRobot->ScaleSide(0.95f,0.95f);
|
||||
cInstances[Index-IndexOffset].cRobot->SideBorderOuter(0.00f);
|
||||
cInstances[Index-IndexOffset].cRobot->UseFilterAccel();
|
||||
}
|
||||
else if (cRobotType == RTYPE_SIMPLIX_LS1)
|
||||
{
|
||||
LogSimplix.debug("#cRobotType == RTYPE_SIMPLIX_LS1\n");
|
||||
|
|
Loading…
Reference in a new issue