Hello Community,
I'm currently trying to change some Meshes in game. And that's working fine for now. The only problem is, these objects have no collision.
I added a convex collision to the StaticMeshs Objects in the Browser. Then I change the mesh to one of these, they don't have collision.
Here's the script I'm using:
Can anybody help?
Thanks,
Voleuro
I'm currently trying to change some Meshes in game. And that's working fine for now. The only problem is, these objects have no collision.
I added a convex collision to the StaticMeshs Objects in the Browser. Then I change the mesh to one of these, they don't have collision.
Here's the script I'm using:
Code:
class ObjectOverTime extends Actor placeable; var() instanced StaticMeshComponent MeshComp; var() StaticMesh Dimension1; var() StaticMesh Dimension2; var TimeField TF; function UpdateDimension() { local float dist; ForEach DynamicActors(class'TimeField',TF) { //my One dist = VSize(TF.Location - Location); if(dist <= 512) { MeshComp.SetStaticMesh(Dimension2); } else { MeshComp.SetStaticMesh(Dimension1); } } } defaultproperties { Begin Object class=StaticMeshComponent Name=Mesh1 CastShadow=true StaticMesh=StaticMesh'RoboPlaneten.Sofa' //Placeholder bAllowAmbientOcclusion=true CollideActors=True End Object MeshComp=Mesh1 Components.Add(Mesh1) }
Thanks,
Voleuro
Comment