Core.Object | +--Engine.Actor | +--Engine.Decoration | +--RuneI.DecorationRune | +--RuneI.WaterPlants | +--RuneI.SeaWeed
void
AddVelocity(vector NewVelocity)
bool
JointDamaged(int Damage, Pawn EventInstigator, vector HitLoc, vector Momentum, name DamageType, int joint)
simulated
JointTouchedBy(Actor Other, int joint)
00001 //============================================================================= 00002 // SeaWeed. 00003 //============================================================================= 00004 class SeaWeed expands WaterPlants; 00005 00006 00007 00008 simulated event GetAccelJointParms(int joint, out float DampFactor, out float RotThreshold) 00009 { 00010 DampFactor = 0.25; 00011 RotThreshold = 8000; 00012 } 00013 00014 simulated event float GetAccelJointMagnitude(int joint) 00015 { 00016 return 100; 00017 } 00018 00019 function bool JointDamaged(int Damage, Pawn EventInstigator, vector HitLoc, vector Momentum, name DamageType, int joint) 00020 { 00021 local vector vel; 00022 00023 vel = Momentum * 0.05; 00024 if (joint!=0) 00025 ApplyJointForce(joint, vel); 00026 return true; 00027 } 00028 00029 simulated function JointTouchedBy(actor Other, int joint) 00030 { 00031 local vector vel; 00032 00033 vel = Other.Velocity * 0.05; 00034 ApplyJointForce(joint, vel); 00035 } 00036 00037 function AddVelocity(vector NewVelocity) 00038 { 00039 ApplyJointForce(3, NewVelocity); 00040 } 00041 00042 00043 auto State idle 00044 { 00045 Begin: 00046 LoopAnim('seaweed', 1.0, 0.1); 00047 } 00048 00049 defaultproperties 00050 { 00051 bStatic=False 00052 Style=STY_Masked 00053 DrawScale=2.000000 00054 CollisionRadius=15.000000 00055 CollisionHeight=100.000000 00056 bCollideActors=True 00057 bCollideWorld=True 00058 bJointsTouch=True 00059 Skeletal=SkelModel'plants.SeaWeed' 00060 }