Changeset 1313 for cpp/frams/genetics/f4/f4_conv.cpp
- Timestamp:
- 07/11/24 17:15:51 (4 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
cpp/frams/genetics/f4/f4_conv.cpp
r1274 r1313 1 1 // This file is a part of Framsticks SDK. http://www.framsticks.com/ 2 // Copyright (C) 1999-202 3Maciej Komosinski and Szymon Ulatowski.2 // Copyright (C) 1999-2024 Maciej Komosinski and Szymon Ulatowski. 3 3 // See LICENSE.txt for details. 4 4 … … 189 189 } 190 190 191 char tmpLine[ 100];191 char tmpLine[256]; 192 192 MultiRange range = C->genoRange; 193 193 … … 200 200 // new part object for firstend 201 201 // coordinates are left to be computed by Model 202 sprintf(tmpLine, "fr=%g,ing=%g,as=%g ",203 /*1.0/C->P.mass,*/ C->P.friction, C->P.ingestion, C->P.assimilation 202 sprintf(tmpLine, "fr=%g,ing=%g,as=%g,vr=%g,vg=%g,vb=%g", 203 /*1.0/C->P.mass,*/ C->P.friction, C->P.ingestion, C->P.assimilation, C->P.cred, C->P.cgreen, C->P.cblue 204 204 //C->firstend.x, C->firstend.y, C->firstend.z 205 205 ); … … 216 216 } 217 217 // new part object for lastend 218 sprintf(tmpLine, "fr=%g,ing=%g,as=%g ",218 sprintf(tmpLine, "fr=%g,ing=%g,as=%g,vr=%g,vg=%g,vb=%g", 219 219 //C->lastend.x, C->lastend.y, C->lastend.z 220 /*"vol=" 1.0/C->P.mass,*/ C->P.friction, C->P.ingestion, C->P.assimilation 220 /*"vol=" 1.0/C->P.mass,*/ C->P.friction, C->P.ingestion, C->P.assimilation, C->P.cred, C->P.cgreen, C->P.cblue 221 221 ); 222 222 C->p2_refno = addFromString(PartType, tmpLine, &range); … … 241 241 C->joint_refno = addFromString(JointType, tmpLine, &range); 242 242 if (C->joint_refno < 0) return -13; 243 getJoint(C->joint_refno)->vcolor = (getPart(jj_p1_refno)->vcolor + getPart(jj_p2_refno)->vcolor) / 2; //joint gets the average color of both connected parts 243 244 this->checkpoint(); 244 245 }
Note: See TracChangeset
for help on using the changeset viewer.