21
21
public class ActorDefinition extends CachedNode implements EntityDefinition {
22
22
23
23
public static int count ;
24
- public static NodeCache actorDefinitionNodeCache = new NodeCache (64 );
25
- public static NodeCache actorChildModelCache = new NodeCache (50 );
26
- public static CacheArchive aCacheArchive_1375 ;
27
- public static CacheArchive aCacheArchive_1577 ;
24
+ private static NodeCache actorDefinitionCache = new NodeCache (64 );
25
+ private static NodeCache actorModelCache = new NodeCache (50 );
26
+ private static CacheArchive actorDefinitionArchive ;
27
+ private static CacheArchive actorModelArchive ;
28
28
29
29
public boolean isClickable = true ;
30
30
public int boundaryDimension = 1 ;
@@ -116,28 +116,28 @@ public static ImageRGB method578() {
116
116
}
117
117
118
118
public static ActorDefinition getDefinition (int id ) {
119
- ActorDefinition definition = (ActorDefinition ) actorDefinitionNodeCache .get (id );
119
+ ActorDefinition definition = (ActorDefinition ) actorDefinitionCache .get (id );
120
120
if (definition != null )
121
121
return definition ;
122
- byte [] data = aCacheArchive_1375 .getFile (9 , id );
122
+ byte [] data = actorDefinitionArchive .getFile (9 , id );
123
123
definition = new ActorDefinition ();
124
124
definition .id = id ;
125
125
if (data != null )
126
126
definition .readValues (new Buffer (data ));
127
- actorDefinitionNodeCache .put (id , definition );
127
+ actorDefinitionCache .put (id , definition );
128
128
return definition ;
129
129
}
130
130
131
131
public static void clearActorCache () {
132
- actorDefinitionNodeCache .clear ();
133
- actorChildModelCache .clear ();
132
+ actorDefinitionCache .clear ();
133
+ actorModelCache .clear ();
134
134
}
135
135
136
- public static void initializeActorCache (CacheArchive arg0 , CacheArchive arg2 ) {
137
- aCacheArchive_1375 = arg2 ;
138
- count = aCacheArchive_1375 .fileLength (9 );
136
+ public static void initializeActorCache (CacheArchive models , CacheArchive definitions ) {
137
+ actorDefinitionArchive = definitions ;
138
+ count = actorDefinitionArchive .fileLength (9 );
139
139
140
- aCacheArchive_1577 = arg0 ;
140
+ actorModelArchive = models ;
141
141
}
142
142
143
143
public Model getChildModel (AnimationSequence animation1 , AnimationSequence animation2 , int arg3 , int arg4 ) {
@@ -148,11 +148,11 @@ public Model getChildModel(AnimationSequence animation1, AnimationSequence anima
148
148
}
149
149
return actorDefinition .getChildModel (animation1 , animation2 , arg3 , arg4 );
150
150
}
151
- Model model1 = (Model ) actorChildModelCache .get (id );
151
+ Model model1 = (Model ) actorModelCache .get (id );
152
152
if (model1 == null ) {
153
153
boolean bool = false ;
154
154
for (int model : models ) {
155
- if (!aCacheArchive_1577 .loaded (model , 0 )) {
155
+ if (!actorModelArchive .loaded (model , 0 )) {
156
156
bool = true ;
157
157
}
158
158
}
@@ -161,7 +161,7 @@ public Model getChildModel(AnimationSequence animation1, AnimationSequence anima
161
161
}
162
162
Model [] class40_sub5_sub17_sub5s = new Model [models .length ];
163
163
for (int i = 0 ; models .length > i ; i ++) {
164
- class40_sub5_sub17_sub5s [i ] = Model .getModel (aCacheArchive_1577 , models [i ]);
164
+ class40_sub5_sub17_sub5s [i ] = Model .getModel (actorModelArchive , models [i ]);
165
165
}
166
166
if (class40_sub5_sub17_sub5s .length == 1 ) {
167
167
model1 = class40_sub5_sub17_sub5s [0 ];
@@ -177,7 +177,7 @@ public Model getChildModel(AnimationSequence animation1, AnimationSequence anima
177
177
assert model1 != null ;
178
178
model1 .createBones ();
179
179
model1 .applyLighting (ambient + 64 , 850 + contrast , -30 , -50 , -30 , true );
180
- actorChildModelCache .put (id , model1 );
180
+ actorModelCache .put (id , model1 );
181
181
}
182
182
Model class40_sub5_sub17_sub5_0_ ;
183
183
if (animation1 != null && animation2 != null ) {
@@ -315,7 +315,7 @@ public Model getHeadModel() {
315
315
}
316
316
boolean cached = false ;
317
317
for (int headModelIndex : headModelIndexes ) {
318
- if (!aCacheArchive_1577 .loaded (headModelIndex , 0 )) {
318
+ if (!actorModelArchive .loaded (headModelIndex , 0 )) {
319
319
cached = true ;
320
320
}
321
321
}
@@ -324,7 +324,7 @@ public Model getHeadModel() {
324
324
}
325
325
Model [] models = new Model [headModelIndexes .length ];
326
326
for (int i = 0 ; i < headModelIndexes .length ; i ++) {
327
- models [i ] = Model .getModel (aCacheArchive_1577 , headModelIndexes [i ]);
327
+ models [i ] = Model .getModel (actorModelArchive , headModelIndexes [i ]);
328
328
}
329
329
Model headModel ;
330
330
if (models .length == 1 ) {
0 commit comments