![]() |
Oolite 1.91.0.7665-250419-c535bfe
|
#include <OOTrumble.h>
Instance Methods | |
(id) | - initForPlayer: |
(id) | - initForPlayer:digram: |
(void) | - setupForPlayer:digram: |
(void) | - spawnFrom: |
(void) | - calcGrowthRate |
(unichar *) | - digram |
(NSPoint) | - position |
(NSPoint) | - movement |
(GLfloat) | - rotation |
(GLfloat) | - size |
(GLfloat) | - hunger |
(GLfloat) | - discomfort |
(void) | - actionIdle |
(void) | - actionBlink |
(void) | - actionSnarl |
(void) | - actionProot |
(void) | - actionShudder |
(void) | - actionStoned |
(void) | - actionPop |
(void) | - actionSleep |
(void) | - actionSpawn |
(void) | - randomizeMotionX |
(void) | - randomizeMotionY |
(void) | - drawTrumble: |
(void) | - updateTrumble: |
(void) | - updateIdle: |
(void) | - updateBlink: |
(void) | - updateSnarl: |
(void) | - updateProot: |
(void) | - updateShudder: |
(void) | - updateStoned: |
(void) | - updatePop: |
(void) | - updateSleep: |
(void) | - updateSpawn: |
(NSDictionary *) | - dictionary |
(void) | - setFromDictionary: |
(id) | - init [implementation] |
(void) | - dealloc [implementation] |
Private Attributes | |
PlayerEntity * | player |
unichar | digram [2] |
GLfloat | colorBase [4] |
GLfloat | colorPoint1 [4] |
GLfloat | colorPoint2 [4] |
GLfloat | colorEyes [4] |
GLfloat * | pointColor [6] |
GLfloat | hunger |
GLfloat | discomfort |
GLfloat | size |
GLfloat | max_size |
GLfloat | growth_rate |
GLfloat | rotation |
GLfloat | rotational_velocity |
NSPoint | position |
NSPoint | movement |
NSPoint | eye_position |
NSPoint | mouth_position |
double | animationTime |
double | animationDuration |
enum trumble_animation | animation |
enum trumble_animation | nextAnimation |
int | animationStage |
enum trumble_mouth | mouthFrame |
enum trumble_eyes | eyeFrame |
OOTexture * | texture |
GLfloat | saved_float1 |
GLfloat | saved_float2 |
BOOL | readyToSpawn |
Definition at line 70 of file OOTrumble.h.
- (void) actionBlink |
Definition at line 308 of file OOTrumble.m.
References actionBlink, animationDuration, nextAnimation, randf(), and TRUMBLE_ANIM_BLINK.
Referenced by actionBlink, discomfort, updateBlink:, updateIdle:, updateProot:, updateShudder:, and updateSnarl:.
- (void) actionIdle |
Definition at line 302 of file OOTrumble.m.
References actionIdle, animationDuration, nextAnimation, randf(), and TRUMBLE_ANIM_IDLE.
Referenced by actionIdle, discomfort, updateBlink:, updateIdle:, updateProot:, updateShudder:, updateSleep:, and updateSnarl:.
- (void) actionPop |
Definition at line 338 of file OOTrumble.m.
References actionPop, animationDuration, nextAnimation, randf(), and TRUMBLE_ANIM_DIE.
Referenced by actionPop, discomfort, and updateIdle:.
- (void) actionProot |
Definition at line 320 of file OOTrumble.m.
References actionProot, animationDuration, nextAnimation, randf(), and TRUMBLE_ANIM_PROOT.
Referenced by actionProot, discomfort, updateBlink:, updateIdle:, updateSleep:, and updateSpawn:.
- (void) actionShudder |
Definition at line 326 of file OOTrumble.m.
References actionShudder, animationDuration, nextAnimation, randf(), and TRUMBLE_ANIM_SHUDDER.
Referenced by actionShudder, discomfort, and updateIdle:.
- (void) actionSleep |
Definition at line 344 of file OOTrumble.m.
References actionSleep, animationDuration, nextAnimation, randf(), and TRUMBLE_ANIM_SLEEP.
Referenced by actionSleep, discomfort, spawnFrom:, and updateIdle:.
- (void) actionSnarl |
Definition at line 314 of file OOTrumble.m.
References actionSnarl, animationDuration, nextAnimation, randf(), and TRUMBLE_ANIM_SNARL.
Referenced by actionSnarl, discomfort, and updateIdle:.
- (void) actionSpawn |
Definition at line 350 of file OOTrumble.m.
References actionSpawn, animationDuration, nextAnimation, randf(), and TRUMBLE_ANIM_SPAWN.
Referenced by actionSpawn, discomfort, and updateIdle:.
- (void) actionStoned |
Definition at line 332 of file OOTrumble.m.
References actionStoned, animationDuration, nextAnimation, randf(), and TRUMBLE_ANIM_STONED.
Referenced by actionStoned, and discomfort.
- (void) calcGrowthRate |
Definition at line 257 of file OOTrumble.m.
References calcGrowthRate, growth_rate, max_size, size, and TRUMBLE_GROWTH_RATE.
Referenced by calcGrowthRate, setupForPlayer:digram:, spawnFrom:, and updateTrumble:.
|
implementation |
Definition at line 212 of file OOTrumble.m.
References dealloc, and OOTexture::release.
Referenced by dealloc.
- (NSDictionary *) dictionary |
Definition at line 942 of file OOTrumble.m.
References dictionary.
Referenced by dictionary, discomfort, and PlayerEntity::trumbleValue.
- (unichar *) digram |
References digram.
- (GLfloat) discomfort |
References actionBlink, actionIdle, actionPop, actionProot, actionShudder, actionSleep, actionSnarl, actionSpawn, actionStoned, dictionary, discomfort, randomizeMotionX, and randomizeMotionY.
- (void) drawTrumble: | (double) | z |
Definition at line 371 of file OOTrumble.m.
References OOTexture::apply, colorBase, colorEyes, eye_position, eyeFrame, mouth_position, mouthFrame, OOGL, OOGLBEGIN, OOGLEND, OOGLMultModelView(), OOGLPopModelView(), OOGLPushModelView(), OOGLTranslateModelView(), pointColor, position, rotation, size, TRUMBLE_EYES_NONE, TRUMBLE_EYES_OPEN, TRUMBLE_EYES_SHUT, TRUMBLE_EYES_WIDE, TRUMBLE_MOUTH_GROWL, TRUMBLE_MOUTH_NONE, TRUMBLE_MOUTH_NORMAL, TRUMBLE_MOUTH_POUT, and TRUMBLE_MOUTH_SNARL.
Referenced by HeadUpDisplay(Private)::drawTrumbles:.
- (GLfloat) hunger |
References hunger.
|
implementation |
Definition at line 43 of file OOTrumble.m.
References colorPoint1, colorPoint2, and init.
Referenced by init.
- (id) initForPlayer: | (PlayerEntity *) | p1 |
Definition at line 57 of file OOTrumble.m.
References setupForPlayer:digram:.
- (id) initForPlayer: | (PlayerEntity *) | p1 | |
digram: | (NSString*) | digramString |
Definition at line 66 of file OOTrumble.m.
References setupForPlayer:digram:.
- (NSPoint) movement |
References movement.
- (NSPoint) position |
References position.
- (void) randomizeMotionX |
Definition at line 357 of file OOTrumble.m.
References movement, randf(), randomizeMotionX, rotational_velocity, and TRUMBLE_MAX_ROTATIONAL_VELOCITY.
Referenced by discomfort, randomizeMotionX, setupForPlayer:digram:, spawnFrom:, updateIdle:, updateSpawn:, and updateTrumble:.
- (void) randomizeMotionY |
Definition at line 364 of file OOTrumble.m.
References movement, randf(), randomizeMotionY, rotational_velocity, and TRUMBLE_MAX_ROTATIONAL_VELOCITY.
Referenced by discomfort, randomizeMotionY, setupForPlayer:digram:, spawnFrom:, updateIdle:, and updateTrumble:.
- (GLfloat) rotation |
References rotation.
- (void) setFromDictionary: | (NSDictionary *) | dict |
Definition at line 957 of file OOTrumble.m.
References discomfort, growth_rate, hunger, movement, PointFromString(), position, rotation, rotational_velocity, setupForPlayer:digram:, and size.
- (void) setupForPlayer: | (PlayerEntity *) | p1 | |
digram: | (NSString*) | digramString |
Definition at line 75 of file OOTrumble.m.
References animation, animationDuration, animationTime, calcGrowthRate, colorBase, colorEyes, colorPoint1, colorPoint2, digram, discomfort, eye_position, eyeFrame, hunger, InitTrumbleSounds(), int(), max_size, mouth_position, mouthFrame, nextAnimation, player, pointColor, position, randf(), randomizeMotionX, randomizeMotionY, ranrot_rand, ranrot_srand(), readyToSpawn, OOTexture::retain, rotation, rotational_velocity, size, texture, OOTexture::textureWithName:inFolder:options:anisotropy:lodBias:, TRUMBLE_ANIM_IDLE, TRUMBLE_EYES_OPEN, TRUMBLE_MAX_ROTATION, TRUMBLE_MAX_ROTATIONAL_VELOCITY, and TRUMBLE_MOUTH_NORMAL.
Referenced by initForPlayer:, initForPlayer:digram:, setFromDictionary:, and spawnFrom:.
- (void) spawnFrom: | (OOTrumble *) | parentTrumble |
Definition at line 219 of file OOTrumble.m.
References actionSleep, calcGrowthRate, digram, discomfort, hunger, movement, position, randf(), randomizeMotionX, randomizeMotionY, ranrot_rand, rotation, rotational_velocity, setupForPlayer:digram:, size, TRUMBLE_MAX_ROTATION, and TRUMBLE_MAX_ROTATIONAL_VELOCITY.
Referenced by PlayerEntity::addTrumble:.
- (void) updateBlink: | (double) | delta_t |
Definition at line 703 of file OOTrumble.m.
References actionBlink, actionIdle, actionProot, animation, animationDuration, animationTime, eyeFrame, nextAnimation, randf(), TRUMBLE_EYES_OPEN, and TRUMBLE_EYES_SHUT.
Referenced by updateTrumble:.
- (void) updateIdle: | (double) | delta_t |
Definition at line 662 of file OOTrumble.m.
References actionBlink, actionIdle, actionPop, actionProot, actionShudder, actionSleep, actionSnarl, actionSpawn, animation, animationDuration, animationTime, discomfort, nextAnimation, randf(), randomizeMotionX, randomizeMotionY, and readyToSpawn.
Referenced by updateTrumble:.
- (void) updatePop: | (double) | delta_t |
Definition at line 840 of file OOTrumble.m.
References animationDuration, animationTime, colorBase, colorPoint1, colorPoint2, eyeFrame, mouthFrame, movement, PlayTrumbleSqueal(), randf(), ranrot_rand, PlayerEntity::removeTrumble:, rotational_velocity, size, TRUMBLE_EYES_SHUT, and TRUMBLE_MOUTH_GROWL.
Referenced by updateTrumble:.
- (void) updateProot: | (double) | delta_t |
Definition at line 761 of file OOTrumble.m.
References actionBlink, actionIdle, animation, animationDuration, animationStage, animationTime, eyeFrame, mouthFrame, nextAnimation, PlayTrumbleIdle(), position, randf(), size, TRUMBLE_EYES_OPEN, TRUMBLE_EYES_SHUT, TRUMBLE_MOUTH_GROWL, TRUMBLE_MOUTH_NORMAL, and TRUMBLE_MOUTH_POUT.
Referenced by updateTrumble:.
- (void) updateShudder: | (double) | delta_t |
Definition at line 799 of file OOTrumble.m.
References actionBlink, actionIdle, animation, animationDuration, animationTime, discomfort, eyeFrame, mouthFrame, nextAnimation, PlayTrumbleSqueal(), position, randf(), size, TRUMBLE_EYES_OPEN, TRUMBLE_EYES_WIDE, TRUMBLE_MOUTH_GROWL, and TRUMBLE_MOUTH_NORMAL.
Referenced by updateTrumble:.
- (void) updateSleep: | (double) | delta_t |
Definition at line 880 of file OOTrumble.m.
References actionIdle, actionProot, animation, animationDuration, animationTime, eye_position, eyeFrame, mouth_position, nextAnimation, randf(), saved_float1, saved_float2, size, TRUMBLE_EYES_OPEN, and TRUMBLE_EYES_SHUT.
Referenced by updateTrumble:.
- (void) updateSnarl: | (double) | delta_t |
Definition at line 721 of file OOTrumble.m.
References actionBlink, actionIdle, animation, animationDuration, animationTime, digram, eyeFrame, mouthFrame, nextAnimation, position, randf(), size, TRUMBLE_EYES_OPEN, TRUMBLE_EYES_SHUT, TRUMBLE_EYES_WIDE, TRUMBLE_MOUTH_GROWL, TRUMBLE_MOUTH_NORMAL, and TRUMBLE_MOUTH_SNARL.
Referenced by updateTrumble:.
- (void) updateSpawn: | (double) | delta_t |
Definition at line 915 of file OOTrumble.m.
References actionProot, PlayerEntity::addTrumble:, animation, animationDuration, animationTime, eye_position, eyeFrame, mouth_position, mouthFrame, movement, nextAnimation, position, randomizeMotionX, rotation, rotational_velocity, saved_float1, saved_float2, size, TRUMBLE_EYES_OPEN, TRUMBLE_EYES_WIDE, TRUMBLE_MOUTH_NORMAL, and TRUMBLE_MOUTH_POUT.
Referenced by updateTrumble:.
- (void) updateStoned: | (double) | delta_t |
Definition at line 836 of file OOTrumble.m.
Referenced by updateTrumble:.
- (void) updateTrumble: | (double) | delta_t |
Definition at line 494 of file OOTrumble.m.
References animation, calcGrowthRate, ShipEntity::cargo, ShipEntity::commodityType, discomfort, growth_rate, ShipEntity::hullHeatLevel, hunger, max_size, movement, nil, player, position, randf(), randomizeMotionX, randomizeMotionY, readyToSpawn, rotation, rotational_velocity, PlayerEntity::setTrumbleAppetiteAccumulator:, size, TRUMBLE_ANIM_BLINK, TRUMBLE_ANIM_DIE, TRUMBLE_ANIM_IDLE, TRUMBLE_ANIM_PROOT, TRUMBLE_ANIM_SHUDDER, TRUMBLE_ANIM_SLEEP, TRUMBLE_ANIM_SNARL, TRUMBLE_ANIM_SPAWN, TRUMBLE_ANIM_STONED, TRUMBLE_GROWTH_RATE, TRUMBLE_MAX_ROTATION, TRUMBLE_MAX_ROTATIONAL_VELOCITY, PlayerEntity::trumbleAppetiteAccumulator, UNIVERSE, updateBlink:, updateIdle:, updatePop:, updateProot:, updateShudder:, updateSleep:, updateSnarl:, updateSpawn:, and updateStoned:.
Referenced by PlayerEntity(OOPrivate)::updateTrumbles:.
|
private |
Definition at line 102 of file OOTrumble.h.
Referenced by setupForPlayer:digram:, updateBlink:, updateIdle:, updateProot:, updateShudder:, updateSleep:, updateSnarl:, updateSpawn:, and updateTrumble:.
|
private |
Definition at line 100 of file OOTrumble.h.
Referenced by actionBlink, actionIdle, actionPop, actionProot, actionShudder, actionSleep, actionSnarl, actionSpawn, actionStoned, setupForPlayer:digram:, updateBlink:, updateIdle:, updatePop:, updateProot:, updateShudder:, updateSleep:, updateSnarl:, and updateSpawn:.
|
private |
Definition at line 105 of file OOTrumble.h.
Referenced by updateProot:.
|
private |
Definition at line 99 of file OOTrumble.h.
Referenced by setupForPlayer:digram:, updateBlink:, updateIdle:, updatePop:, updateProot:, updateShudder:, updateSleep:, updateSnarl:, and updateSpawn:.
|
private |
Definition at line 77 of file OOTrumble.h.
Referenced by drawTrumble:, setupForPlayer:digram:, and updatePop:.
|
private |
Definition at line 80 of file OOTrumble.h.
Referenced by drawTrumble:, and setupForPlayer:digram:.
|
private |
Definition at line 78 of file OOTrumble.h.
Referenced by init, setupForPlayer:digram:, and updatePop:.
|
private |
Definition at line 79 of file OOTrumble.h.
Referenced by init, setupForPlayer:digram:, and updatePop:.
|
private |
Definition at line 264 of file OOTrumble.m.
Referenced by digram, setupForPlayer:digram:, spawnFrom:, and updateSnarl:.
|
private |
Definition at line 294 of file OOTrumble.m.
Referenced by discomfort, setFromDictionary:, setupForPlayer:digram:, spawnFrom:, updateIdle:, updateShudder:, and updateTrumble:.
|
private |
Definition at line 96 of file OOTrumble.h.
Referenced by drawTrumble:, setupForPlayer:digram:, updateSleep:, and updateSpawn:.
|
private |
Definition at line 108 of file OOTrumble.h.
Referenced by drawTrumble:, setupForPlayer:digram:, updateBlink:, updatePop:, updateProot:, updateShudder:, updateSleep:, updateSnarl:, and updateSpawn:.
|
private |
Definition at line 88 of file OOTrumble.h.
Referenced by calcGrowthRate, setFromDictionary:, and updateTrumble:.
|
private |
Definition at line 289 of file OOTrumble.m.
Referenced by hunger, setFromDictionary:, setupForPlayer:digram:, spawnFrom:, and updateTrumble:.
|
private |
Definition at line 87 of file OOTrumble.h.
Referenced by calcGrowthRate, setupForPlayer:digram:, and updateTrumble:.
|
private |
Definition at line 97 of file OOTrumble.h.
Referenced by drawTrumble:, setupForPlayer:digram:, updateSleep:, and updateSpawn:.
|
private |
Definition at line 107 of file OOTrumble.h.
Referenced by drawTrumble:, setupForPlayer:digram:, updatePop:, updateProot:, updateShudder:, updateSnarl:, and updateSpawn:.
|
private |
Definition at line 274 of file OOTrumble.m.
Referenced by movement, randomizeMotionX, randomizeMotionY, setFromDictionary:, spawnFrom:, updatePop:, updateSpawn:, and updateTrumble:.
|
private |
Definition at line 103 of file OOTrumble.h.
Referenced by actionBlink, actionIdle, actionPop, actionProot, actionShudder, actionSleep, actionSnarl, actionSpawn, actionStoned, setupForPlayer:digram:, updateBlink:, updateIdle:, updateProot:, updateShudder:, updateSleep:, updateSnarl:, and updateSpawn:.
|
private |
Definition at line 73 of file OOTrumble.h.
Referenced by setupForPlayer:digram:, and updateTrumble:.
|
private |
Definition at line 81 of file OOTrumble.h.
Referenced by drawTrumble:, and setupForPlayer:digram:.
|
private |
Definition at line 269 of file OOTrumble.m.
Referenced by drawTrumble:, position, setFromDictionary:, setupForPlayer:digram:, spawnFrom:, updateProot:, updateShudder:, updateSnarl:, updateSpawn:, and updateTrumble:.
|
private |
Definition at line 114 of file OOTrumble.h.
Referenced by setupForPlayer:digram:, updateIdle:, and updateTrumble:.
|
private |
Definition at line 279 of file OOTrumble.m.
Referenced by drawTrumble:, rotation, setFromDictionary:, setupForPlayer:digram:, spawnFrom:, updateSpawn:, and updateTrumble:.
|
private |
Definition at line 91 of file OOTrumble.h.
Referenced by randomizeMotionX, randomizeMotionY, setFromDictionary:, setupForPlayer:digram:, spawnFrom:, updatePop:, updateSpawn:, and updateTrumble:.
|
private |
Definition at line 112 of file OOTrumble.h.
Referenced by updateSleep:, and updateSpawn:.
|
private |
Definition at line 112 of file OOTrumble.h.
Referenced by updateSleep:, and updateSpawn:.
|
private |
Definition at line 284 of file OOTrumble.m.
Referenced by calcGrowthRate, drawTrumble:, setFromDictionary:, setupForPlayer:digram:, size, spawnFrom:, updatePop:, updateProot:, updateShudder:, updateSleep:, updateSnarl:, updateSpawn:, and updateTrumble:.
|
private |
Definition at line 110 of file OOTrumble.h.
Referenced by setupForPlayer:digram:.