Jump to content

Recommended Posts

Posted

I used this in le2.

 

model:SetElasticity(2.5)

 

Don;t have le3 yet.

amd quad core 4 ghz / geforce 660 ti 2gb / win 10

Blender,gimp,silo2,ac3d,,audacity,Hexagon / using c++

Posted

I know it is not physically correct, but you could do something like this.

function Script:Start()
self.currentBounciness = 0
self.bounciness = 500
end
function Script:Collision(entity, position, normal, speed)
if speed > 3 then
 if ( self.currentBounciness ) == 0 then
  self.currentBounciness = self.bounciness
 else
  self.entity:AddForce(0, self.currentBounciness, 0)
  self.currentBounciness = self.currentBounciness / 2
 end
end
end

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...