Changeset 528 for cpp/frams/model
- Timestamp:
- 07/18/16 04:14:37 (8 years ago)
- Location:
- cpp/frams/model
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
cpp/frams/model/defassign-f0-SDK.h
r507 r528 9 9 void Part::defassign() 10 10 { 11 mass=1.0;12 11 shape=0; 13 12 size=1.0; -
cpp/frams/model/f0-SDK-classes.h
r507 r528 24 24 ParamEntry f0_part_paramtab[]= 25 25 { 26 {"Geometry",3,2 3,"p" },26 {"Geometry",3,22,"p" }, 27 27 {"Other properties",}, 28 28 {"Visual",}, … … 30 30 {"y",0,1024,"position.y","f",FIELD(p.y),}, 31 31 {"z",0,1024,"position.z","f",FIELD(p.z),}, 32 {"m",1,0,"mass","f 0.1 999.0 1.0",FIELD(mass),},33 32 {"sh",1,0,"shape","d 0 3 0",FIELD(shape),}, 34 33 {"s",1,0,"size","f 0.1 10.0 1.0",FIELD(size),}, … … 55 54 { 56 55 {"Extra properties",1,9,"p"}, 57 {" m",0,0,"mass","f 0.1 999.0 1.0",FIELD(mass),},56 {"h",0,0,"hollow","f 0 1 0",FIELD(hollow),}, 58 57 {"dn",0,0,"density","f 0.2 5.0 1.0",FIELD(density),}, 59 58 {"fr",0,0,"friction","f 0.0 4.0 0.4",FIELD(friction),}, -
cpp/frams/model/model.cpp
r522 r528 923 923 p->mass = 0.0; 924 924 } 925 // VALIDMINMAX(p,part,mass); 925 //VALIDMINMAX(p,part,mass);//mass is very special 926 // VALIDMINMAX are managed manually when adding part properties in f0-def! 927 // (could be made dynamic but not really worth the effort) 926 928 VALIDMINMAX(p, Part, size); 929 VALIDMINMAX(p, Part, scale.x); 930 VALIDMINMAX(p, Part, scale.y); 931 VALIDMINMAX(p, Part, scale.z); 932 VALIDMINMAX(p, Part, hollow); 927 933 VALIDMINMAX(p, Part, density); 928 934 VALIDMINMAX(p, Part, friction); 929 935 VALIDMINMAX(p, Part, ingest); 930 936 VALIDMINMAX(p, Part, assim); 937 VALIDMINMAX(p, Part, vsize); 938 VALIDMINMAX(p, Part, vcolor.x); 939 VALIDMINMAX(p, Part, vcolor.y); 940 VALIDMINMAX(p, Part, vcolor.z); 931 941 p->flags &= ~LINKFLAG; // for delta joint cycle detection 932 942 if (p->p.x - p->size < bbmin.x) bbmin.x = p->p.x - p->size; … … 951 961 { 952 962 j = (Joint*)joints(i); 963 // VALIDMINMAX are managed manually when adding joint properties in f0-def! 964 // (could be made dynamic but not really worth the effort) 953 965 VALIDMINMAX(j, Joint, stamina); 954 966 VALIDMINMAX(j, Joint, stif); 955 967 VALIDMINMAX(j, Joint, rotstif); 968 VALIDMINMAX(p, Part, vcolor.x); 969 VALIDMINMAX(p, Part, vcolor.y); 970 VALIDMINMAX(p, Part, vcolor.z); 956 971 j->refno = i; 957 972 j->owner = this; … … 1039 1054 { 1040 1055 n = (Neuro*)neurons(i); 1041 VALIDMINMAX(n, Neuro, state);1042 1056 #ifdef MODEL_V1_COMPATIBLE 1043 1057 VALIDMINMAX(n,Neuro,inertia); -
cpp/frams/model/modelparts.cpp
r292 r528 643 643 defassign(); 644 644 shape=s; 645 mass=1; 645 646 } 646 647
Note: See TracChangeset
for help on using the changeset viewer.