Changeset 772
- Timestamp:
- 04/05/18 20:03:20 (7 years ago)
- Location:
- cpp/frams/genetics
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
cpp/frams/genetics/f4/oper_f4.cpp
r771 r772 17 17 18 18 19 //see also modifiers in f1 20 #define F4_MODIFIERS_VISUAL "DdGgBbHh" 21 #define F4_MODIFIERS_RARE "EeWwAaSs" //expdef would need to handle these properly/specifically to ensure reasonable behavior, and hardly any expdef does. Modifying initial energy of a creature as a result of its genes (Ee) is in general not a good idea. Weight (Ww) works only in water, and in water sinking/going up should usually be caused by real "intentional" activity of a creature, not by its inherited weight. For assimilation (Aa), there is a dedicated parameter in CreaturesGroup. Stamina (Ss) is no longer needed as destructive collisions are not supported, and even if they were, some expdef would need to impose reasonable restrictions on the value of this parameter (e.g. similar to normalizeBiol4()) so there is some cost associated with it, and the specific consequences of destructions should be defined as needed. 22 #define F4_MODIFIERS ",LlRrCcQqFfMmIi" F4_MODIFIERS_RARE F4_MODIFIERS_VISUAL 23 const char *Geno_f4::all_modifiers = F4_MODIFIERS; 19 const char *Geno_f4::all_modifiers = F14_MODIFIERS ","; //comma in f4 is handled the same way (simple node, F4_ADD_SIMP) as modifiers 24 20 25 21 // codes that can be changed (apart from being added/deleted) … … 40 36 { "f4_mut_del", 0, 0, "Delete node", "f 0 100 20", FIELD(prob[F4_DEL]), "mutation: probability of deleting a node", }, 41 37 { "f4_mut_mod", 0, 0, "Modify node", "f 0 100 30", FIELD(prob[F4_MOD]), "mutation: probability of changing a node", }, 42 { "f4_mut_exmod", 1, 0, "Excluded modifiers", "s 0 30", FIELD(excluded_modifiers), "Modifiers that will not be added nor deleted during mutation\n(all: " F 4_MODIFIERS ")", },38 { "f4_mut_exmod", 1, 0, "Excluded modifiers", "s 0 30", FIELD(excluded_modifiers), "Modifiers that will not be added nor deleted during mutation\n(all: " F14_MODIFIERS ")", }, 43 39 { 0, }, 44 40 }; … … 68 64 void Geno_f4::setDefaults() 69 65 { 70 excluded_modifiers = F 4_MODIFIERS_RARE F4_MODIFIERS_VISUAL;66 excluded_modifiers = F14_MODIFIERS_RARE F14_MODIFIERS_VISUAL; 71 67 } 72 68 … … 722 718 char ch = g[pos]; 723 719 // style categories 724 #define STYL4CAT_MODIFIC F 4_MODIFIERS ","720 #define STYL4CAT_MODIFIC F14_MODIFIERS "," 725 721 #define STYL4CAT_NEUMOD "[]|@*GTS:+-/!=" 726 722 #define STYL4CAT_DIGIT "0123456789." -
cpp/frams/genetics/geneprops.h
r759 r772 8 8 #include <common/nonstd_math.h> 9 9 #include <frams/model/model.h> 10 11 12 13 14 15 #define F14_MODIFIERS_VISUAL "DdGgBbHh" 16 #define F14_MODIFIERS_RARE "EeWwAaSs" //expdef would need to handle these properly/specifically to ensure reasonable behavior, and hardly any expdef does. Modifying initial energy of a creature as a result of its genes (Ee) is in general not a good idea. Weight (Ww) works only in water, and in water sinking/going up should usually be caused by real "intentional" activity of a creature, not by its inherited weight. For assimilation (Aa), there is a dedicated parameter in CreaturesGroup. Stamina (Ss) is no longer needed as destructive collisions are not supported, and even if they were, some expdef would need to impose reasonable restrictions on the value of this parameter (e.g. similar to normalizeBiol4()) so there is some cost associated with it, and the specific consequences of destructions should be defined as needed. 17 #define F14_MODIFIERS "LlRrCcQqFfMmIi" F14_MODIFIERS_RARE F14_MODIFIERS_VISUAL 18 19 20 21 10 22 11 23 /**
Note: See TracChangeset
for help on using the changeset viewer.