Jump to content

Recommended Posts

Posted

I use bullets and ships with physics, they are of collision type "Prop" , player and bullets and ennemies ar all "prop"

 

I would need only some category of "prop" collision to collide with another category and not with others.

 

All ennemies Ships of type "prop" to not collide between them

Bullets of ennemies of type "prop" not collide with ennemy ships of type "prop"

 

It is possible in LE3 to have some sort of Layers collision for objects of type "prop" ?

 

LE3 have several type of collision, and the type can go to number 99

Can we give our own number ?

TypeCollision = 80 ?

And how it would collide or not with TypeCollision = 90 ? How to define it ?

Stop toying and make games

Posted

I know Rick.

But i seen no tutorial on showing how to make groups ?

 

Even if you give numbers using SetCollisionType

How you do to say to collision system :

- CollisionType(80) can collide with CollisionType(90)

- CollisionType(80) can't collide with CollisionType(85)

 

How to do that ? Does i missed some function or step ?

Stop toying and make games

Posted

I think it's only available in C++. I don't see it in the docs. I know the old C++ template used to have it, but it doesn't appear to have it now. I can't remember for the live of me what class it's tied too. Checking...

 

In 2.x it was just called Collisions() I think.

Posted

Don't waste to much time seeking it, as i needed it with Lua.Thanks.

Ok so in Lua this is not possible.

 

I'm not spamming 3D engines, but i wanted LE3 to have something similar to Unity to manage collisions.

https://docs.unity3d.com/Documentation/Components/LayerBasedCollision.html

This bring lot of things and gameplay possibilties could it be :

- bullet ennemies not colliding ennemy ships

- bullets player and ennemie bullet not colliding

- special laser gun going throught walls but not players

- player special ability to go throught walls when power up

etc ...

Stop toying and make games

Posted

The current system works like layers but it's not called layers. Just need to find that Collisions() function and expose it to Lua if it's not already. The concepts are basically the same anyway.

Posted

@Gamecreator :

I'm aware of LE3 collision basc types : with "prop", "debris","scene"

I have physic objects moving , all are type "Prop" and i need some "prop" types to collide with some others and not others.

So you need some layer system.

 

In gameplay terms :

Ennemy ships of collision type "props" not colliding between themselves, only with player bullets and ship that are also "prop" type

Actually any "prop" type collision will collide with any other "prop" type so that's not possible.

 

In programmin terms :

- CollisionType(80) can collide with CollisionType(90)

- CollisionType(80) can't collide with CollisionType(85)

Stop toying and make games

Posted

Cant you set collsion for bullets

self.entity:SetCollisionType(99)

and then use

if collisiontype~=99 then blah blah end

and have bullets as 99.

Elite Cobra Squad

Posted

Where would you put that if collisiontype statement to check? You can't put it in the Collision() function because it won't get called unless you already setup collisions in another function (that we are trying to find). You would have to manually do your own collision checks, which shouldn't be needed because there is this other way if we could find it :)

Posted

Cant you set collsion for bullets

self.entity:SetCollisionType(99)

and then use

if collisiontype~=99 then blah blah end

and have bullets as 99.

 

I don't talk about trigger or detect collision, but a way to be able to control what collision type should collide physically or not with another collision type.

 

Some example :

I don't want bullets of type 99 to collide with ennemy ships of type 97, but i want bullets type 99 to collide with player ships that have collision type = 90.

Actually we can't tell LE3 engine :

Type 99 No collision physics with Type 97

Type 99 Yes Collision physics with Type 90

 

Seems simply LE3 don't have collision groups/layers management.

Stop toying and make games

Posted

I remember using something called Sprite Candy for BB3D (was for Sprites) that had layers, worked very well.

 

Something like that would be good.

Elite Cobra Squad

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...