So I want the ball to be limited to a jump height?


#1

So I made this script `var Limith = pc.createScript(‘Limith’);

Limith.attributes.add(‘Limith’, {type:‘entity’});
Limith.attributes.add(‘Ball’, {type:‘entity’});

Limith.prototype.intalize = function() {
//hopefully will limit balls height//
this.entity.findByName(‘Ball’,this.entity = true);
this.entity = entity.max;
};

Limith.prototype.max = function() {
if(this.app.keyboard.isPressed(pc.KEY_H)) {
this.max();
}
};

Limith.prototype.max = function() {
this.ball.rigidbody.teleport(this.Limith.getPosition());
this.ball.rigidbody.linearVelocity = pc.Vec3.DOWN;
this.ball.rigidbody.angularVelocity = pc.Vec3.DOWN;

};`

But it doesnt do anything it has no errors or anything but nothing is doing anything


#2

I’ll try getting a friend, WerdieGames, to help you.


#3

ummmmmmmm ok


#4

that’s a lot of m’s


#5

M&M lol