Yue Posted April 3, 2019 Share Posted April 3, 2019 The biggest problem is, to put aside my perception of things and understand that it's just a game, as Johs mentioned, physics doesn't have to be real, it's just a game, but sometimes I have the craze that everything has to be as real as possible and this slows down the project, its goal of making a video game. So here I am again, asking for your help to be able to pass this challenge successfully. And my player already carries a box, in the head, of course an animation will be made to make it look better. Box.mp4 Now the thing is, I want to use a single key for the player to interact with the scenario, the boxes and other elements, but initially I have the key that kicks the boxes, the E key, and I would like to know if there is any way for this key to react to kick the box and at the same time take the box, and then leave it. I appreciate the suggestions. local cajaT = false function Script:Collision(entity, position, normal, speed) if cajaT == false then if entity:GetKeyValue("name") == "Caja" then entity:SetMass(0) entity:SetShape(nil) entity:SetKeyValue("name","TCaja") entity:SetRotation(self.entity:GetRotation(true)) entity:SetParent(self.entity) entity:SetPosition(0,12,0) cajaT = true end end end Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.