Jump to content

Object Weight & Scale


Recommended Posts

Well, i've got 2 issues so far.

Code:

--Client 
local newPosRelative = Vector3(0,2,1) 
local Pos = localPlayer.matrix 
local newPos = Pos:transformPosition(newPosRelative) 
  
object = createObject(3065,newPos) 
object.frozen = false 
object.collisions = true 
object.scale = 1 
object.mass = 20 
setTimer(function() 
local velVector = Vector3(0,0,0) 
object.velocity = velVector 
end,100,1) 
  
setTimer(function()  
setElementVelocity(object, 0,0,0.2) 
outputChatBox(object.mass) 
end, 3000,1) 

1st. Issue, the object weight.

Modifying the object mass doesnt make any difference when i make it "jump", it will still reach the same height, and fall as quickly, i'm not sure if modifying its mass should make any difference, or i should edit something else?

2nd. Issue, the object scale.

As i already know, changing its scale wont change its collision box, but how could i modify its collision box according to scale?

Thanks

Link to comment

Changing the mass will sure change the moving behavior of an object, especially for dynamic objects. For the scale part, you cannot change the collision box. It will stay the same as it originally is. Maybe you could try something with:

engineLoadCOL 
engineReplaceCOL 

Link to comment
Changing the mass will sure change the moving behavior of an object, especially for dynamic objects. For the scale part, you cannot change the collision box. It will stay the same as it originally is. Maybe you could try something with:
engineLoadCOL 
engineReplaceCOL 

Tested it, i tried giving it a velocity, it will fall at the same point and time whatever the mass is. However if it would hit a car for example, a mass 5000 will splat the car, while its original 10 mass will only bounce off from it.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...