Jump to content

Making an object only intersect with the player


Slastraf
 Share

Recommended Posts

Hello

I want to make an elevator-like capsule which has the movingplatform script attached.

the problem is that it has some physics objects attached that are colliding with the capsule

So how do you make a script or adjust things like that in the editor?

The Objects that are attached to the moving platform should only collide with the player (or just not with the platform)

Link to comment
Share on other sites

Define a new collision response between two types:

 

void Collision::SetResponse(const int collisionTypeA, const int collisionTypeB, const int response)

 

Response can be:

  • Collision.None
  • Collision.Collide
  • Collision.Trigger

 

And then call Entity:SetCollisionType()

http://www.leadwerks.com/werkspace/page/api-reference/_/entity/entitysetcollisiontype-r35

  • Upvote 1

 

 

Link to comment
Share on other sites

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.

 Share

×
×
  • Create New...