Project

General

Profile

« Previous | Next » 

Revision 45e0065d

Added by Leszek Koltunski over 2 years ago

Correct the next bug with settign the object size.
Multiply the time limits in BlockController by 2 - this way we can see if the ratio of (UI+Touch)/Thread Firebase non-fatals will observably drop below the current value of 4.

View differences:

src/main/java/org/distorted/objectlib/main/TwistyObject.java
1124 1124

  
1125 1125
///////////////////////////////////////////////////////////////////////////////////////////////////
1126 1126

  
1127
  void setObjectRatioNow(float sc, int nodeMinSize)
1127
  void setObjectRatioNow(float sc, int nodeSize)
1128 1128
    {
1129 1129
    mObjectScreenRatio = sc;
1130
    float scale = mObjectScreenRatio*mInitScreenRatio*nodeMinSize/mSize;
1130
    float scale = mObjectScreenRatio*mInitScreenRatio*nodeSize/mSize;
1131 1131
    mObjectScale.set(scale,scale,scale);
1132 1132
    }
1133 1133

  
1134 1134
///////////////////////////////////////////////////////////////////////////////////////////////////
1135 1135

  
1136
  void setObjectRatio(float sizeChange, int nodeMinSize)
1136
  void setObjectRatio(float sizeChange, int nodeSize)
1137 1137
    {
1138 1138
    mObjectScreenRatio *= (1.0f+sizeChange)/2;
1139 1139

  
1140 1140
    if( mObjectScreenRatio>MAX_SIZE_CHANGE) mObjectScreenRatio = MAX_SIZE_CHANGE;
1141 1141
    if( mObjectScreenRatio<MIN_SIZE_CHANGE) mObjectScreenRatio = MIN_SIZE_CHANGE;
1142 1142

  
1143
    setObjectRatioNow(mObjectScreenRatio, nodeMinSize);
1143
    setObjectRatioNow(mObjectScreenRatio, nodeSize);
1144
    }
1145

  
1146
///////////////////////////////////////////////////////////////////////////////////////////////////
1147

  
1148
  void setNodeSize(int nodeSize)
1149
    {
1150
    setObjectRatioNow(mObjectScreenRatio, nodeSize);
1144 1151
    }
1145 1152

  
1146 1153
///////////////////////////////////////////////////////////////////////////////////////////////////

Also available in: Unified diff