Changeset 348 for cpp/frams/model
- Timestamp:
- 04/09/15 23:51:28 (10 years ago)
- Location:
- cpp/frams/model
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
cpp/frams/model/autoname.cpp
r343 r348 38 38 unsigned int s1 = 0, s2 = 0, s3 = 0; 39 39 SString g = model.getGeno().getGene(); 40 const char *x = g ;40 const char *x = g.c_str(); 41 41 for (; *x; x++) { s1 += *x; s2 = s2**x + *x; s3 = (s3^*x) + *x; } 42 42 char* t = buf; -
cpp/frams/model/model.cpp
r319 r348 331 331 FMprintf("Model","build",FMLV_ERROR, 332 332 geno.getName().len()?"illegal f0 code at line %d (%s)":"illegal f0 code at line %d", 333 lnum, (const char*)geno.getName());333 lnum,geno.getName().c_str()); 334 334 f0errorposition=lastpos; 335 335 if (convmap) delete convmap; … … 473 473 } 474 474 } 475 g=Geno(gen ,'0');475 g=Geno(gen.c_str(),'0'); 476 476 } 477 477 … … 559 559 int Model::singleStepBuild(const SString &line,const MultiRange* srcrange) 560 560 { 561 int pos=0; const char*t= (const char*)line;561 int pos=0; const char*t=line.c_str(); 562 562 for (;*t;t++,pos++) 563 563 if (!strchr(" \r\t",*t)) break; … … 943 943 FMprintf("Model","internalCheck",FMLV_ERROR, 944 944 "delta joint cycle detected at joint#%d (%s)", 945 i, (const char*)geno.getName());945 i,geno.getName().c_str()); 946 946 } 947 947 j->resetDeltaMarkers(); … … 979 979 ret=0; 980 980 FMprintf("Model","internalCheck",FMLV_ERROR,"delta too big in joint #%d (%s)", 981 i, (const char*)geno.getName());981 i,geno.getName().c_str()); 982 982 } 983 983 else if (j->d()<getMinJoint().d.x) … … 985 985 ret=0; 986 986 FMprintf("Model","internalCheck",FMLV_ERROR,"delta too small in joint #%d (%s)", 987 i, (const char*)geno.getName());987 i,geno.getName().c_str()); 988 988 } 989 989 } … … 993 993 { 994 994 FMprintf("Model","internalCheck",FMLV_ERROR,"illegal part references in joint #%d (%s)", 995 i, (const char*)geno.getName());995 i,geno.getName().c_str()); 996 996 ret=0; 997 997 } … … 1072 1072 { 1073 1073 FMprintf("Model","internalCheck",FMLV_ERROR,"not all parts connected (eg.#0-#%d) (%s)", 1074 i, (const char*)geno.getName());1074 i,geno.getName().c_str()); 1075 1075 ret=0; 1076 1076 break; … … 1085 1085 { 1086 1086 FMprintf("Model","internalCheck",FMLV_ERROR,"illegal self connection, joint #%d (%s)", 1087 i, (const char*)geno.getName());1087 i,geno.getName().c_str()); 1088 1088 ret=0; 1089 1089 break; … … 1096 1096 { 1097 1097 FMprintf("Model","internalCheck",FMLV_ERROR,"illegal duplicate joints #%d and #%d (%s)", 1098 i,k, (const char*)geno.getName());1098 i,k,geno.getName().c_str()); 1099 1099 ret=0; 1100 1100 break;
Note: See TracChangeset
for help on using the changeset viewer.