Thank You Souvarine.

I am very stupid ; solid is used in the example, for the character...

So, I have tested with a part of my world and it is OK.

Now they are two levels, the first is visible but not solid, and the 
second is not visible but solid, with no details and many cubes.

I load them so :

# level what you see, but no collisions :
level = soya.World.get("level_college")
level.solid = 0
scene.add(level)

# for collisions, but invisible :
level_c = soya.World.get("level_c_college")
level_c.visible = 0
scene.add(level_c)

You can see here :
http://clgdrouyn.fr/College-3D-version-2008.html

but in French (I speak a little better French).

O-
Pascal

Souvarine a écrit :
> Very bad english indeed...
> 
> You can use raypick categories to do this. Worlds and bodies have an 
> attribute named "solid" that is a 32 bit wide bitfield identifying the 
> categories the object belongs to.
> 
> Example :
> 
> CATEGORY1 = 1
> CATEGORY2 = 1 << 1
> 
> object1.solid = CATEGORY1 # this object belong to category 1
> object2.solid = CATEGORY2 # this object belong to category 2
> object3.solid = CATEGORY1 |  CATEGORY2 # this object belong to both 
> category 1 and 2
> 
> Now when you use the raypick functions you can use the optional category 
> parameter to select the categories you want to test. By default all 
> object have solid = 1.
> 
> Note that soya raypicking process is recursive. If you raypick a world 
> and that world's solid attribute don't the match the category you passed 
> to raypick() then the whole world is ignored and it's children wont be 
> tested ! (this makes the category system quite difficult to use, maybe I 
> should change that...)
> 
> Hope this help. And by the way, there is a similar category system in 
> ODE geoms.
> 
> Souvarine.
> 
>  
> Pascal Peter wrote:
>> sorry for my very bad English.
>>
>> My question is :
>> is it a way to ave a part of the level of my game that is ignored by 
>> collisions ?
>>
>> I ave a level like in game_skel from tutorials and a character.
>> I want tu put details in a separate level, so the collisions are ignored 
>> for them.
>>
>> I experiment with a second level, attach the character to the first 
>> level, but collisions are do.
>> With a second World, the second level is not visible (I mean it is normal).
>>
>> So, what can I do ?
>>
>> O-
>> Pascal
>>
>>
>> _______________________________________________
>> Soya-user mailing list
>> Soya-user@gna.org
>> https://mail.gna.org/listinfo/soya-user
>>
>>   
> 
> _______________________________________________
> Soya-user mailing list
> Soya-user@gna.org
> https://mail.gna.org/listinfo/soya-user
> 
> 


_______________________________________________
Soya-user mailing list
Soya-user@gna.org
https://mail.gna.org/listinfo/soya-user

Reply via email to