dgKinematicBody* dgWorld::CreateKinematicBody (dgCollisionInstance* const collision, const dgMatrix& matrix) { dgKinematicBody* const body = new (m_allocator) dgKinematicBody(); dgAssert (dgInt32 (sizeof (dgBody) & 0xf) == 0); dgAssert ((dgUnsigned64 (body) & 0xf) == 0); InitBody (body, collision, matrix); return body; }
//simple healing char* _medOnPillConnected(ubyte_t cureId) { CURE_ID cure_id = (CURE_ID)cureId; switch (cureId) { case Analgetic: Body.PainReduction = 1; break; case Antispasmodic: //block spasms //foreach organ Muscle disfuntion + break; case Pyretic: //perception+, temperature- //bleeding+ break; case Aspirator: //can breath even if NoBreaath //chest disfunction break; case CoagulationFactor: //bleeding- //toxication+ //TT=B/4 Body.BleedingFactor = 3; break; case SyntheticBlood: Body.BloodCapacity += Body.RegenerationLevel * 10; //depends on regen break; case Leatherette: case Myorelaxant: case Antibiotic: case NanoExoFrame: //FEATURE CUT break; case VisceraNanoPack: BodyDecreaseCategory(); break; case Anesthetics: Body.PainReduction = 2; //Def break; case Absorber: //ToxCapacity- break; case PlasterNanoPack: //smth- smth+ break; case MagicCure: InitBody(); break; default: break; } return (char*)CureDescs[cureId].Effect; }
int main () { char *filename = "Export_50x50x50.dat"; float *body; body = (float*)malloc(DEPTH*WIDTH*HEIGHT*sizeof(float)); // Initialize the body InitBody(body); // Put cube into the body FileToArray(filename, body); free(body); return 0; }
void _medInit() { int sz = 0; bool ret = ArmletApi::OpenFile(&MedFile, "MedState.bin",false); if (ret) { sz = ArmletApi::ReadFile(&MedFile,(char*)&Body,sizeof(BODY)); } else { ArmletApi::OpenFile(&MedFile, "MedState.bin",true); } if (sz!=sizeof(BODY)) { InitBody(); } InitCureDescs(); InitWounds(); }
CMeteorite::CMeteorite() { InitBody(); }
CMeteorite::CMeteorite( const int x, const int y, const QVector2D dir ) : CActor( x, y, dir ) { InitBody(); }