meaning of cbox1&2 [Solved]

Ask for help about creating mods and scripts for Grimrock 2 or share your tips, scripts, tools and assets with other modders here. Warning: forum contains spoilers!
Post Reply
User avatar
Jouki
Posts: 127
Joined: Fri Oct 24, 2014 12:57 pm

meaning of cbox1&2 [Solved]

Post by Jouki »

Hello guys, can someone explain to me what is cbox, please? sometimes I can see that as a component but when I disable these ones nothing visible seems to happened. :shock:
Last edited by Jouki on Mon Oct 27, 2014 12:20 pm, edited 1 time in total.
User avatar
Jouki
Posts: 127
Joined: Fri Oct 24, 2014 12:57 pm

Re: meaning of cbox1&2

Post by Jouki »

so noone knows :(
User avatar
antti
Posts: 688
Joined: Thu Feb 23, 2012 1:43 pm
Location: Espoo, Finland
Contact:

Re: meaning of cbox1&2

Post by antti »

It's a collision box to prevent dropped or thrown items from ending up inside the model. Basic pillars and walls have hardcoded collisions so this is only needed for special cases like statue and pedestal bases. You can use debugDraw = true to visualize the box.
Steven Seagal of gaming industry
User avatar
Jouki
Posts: 127
Joined: Fri Oct 24, 2014 12:57 pm

Re: meaning of cbox1&2

Post by Jouki »

antti wrote:It's a collision box to prevent dropped or thrown items from ending up inside the model. Basic pillars and walls have hardcoded collisions so this is only needed for special cases like statue and pedestal bases. You can use debugDraw = true to visualize the box.
Thanks :) Now I'm feeling dumb cause it's pretty logic. anyway tahnks for clarification
User avatar
AdrTru
Posts: 223
Joined: Sat Jan 19, 2013 10:10 pm
Location: Trutnov, Czech Republic

Re: meaning of cbox1&2

Post by AdrTru »

antti wrote:It's a collision box to prevent dropped or thrown items from ending up inside the model. Basic pillars and walls have hardcoded collisions so this is only needed for special cases like statue and pedestal bases. You can use debugDraw = true to visualize the box.
Iam sorry, but I dont known how use this debugDraw. I try use it from console, cfg, ingame script - but visualization isnt changed.
Can you describe me how i must use this command correctly?
My LOG2 projects: virtual money, Forge recipes, liquid potions and
MultiAlcoveManager, Toolbox, Graphic text,
User avatar
cromcrom
Posts: 549
Joined: Tue Sep 11, 2012 7:16 am
Location: Chateauroux in a socialist s#!$*&% formerly known as "France"

Re: meaning of cbox1&2 [Solved]

Post by cromcrom »

Iam sorry, but I dont known how use this debugDraw. I try use it from console, cfg, ingame script - but visualization isnt changed.
Can you describe me how i must use this command correctly?
I have the same issue please.
A trip of a thousand leagues starts with a step.
User avatar
THOM
Posts: 1281
Joined: Wed Nov 20, 2013 11:35 pm
Location: Germany - Cologne
Contact:

Re: meaning of cbox1&2 [Solved]

Post by THOM »

use it in the Object definition

i.e.

Code: Select all

          {
             	class = "Surface",
             	offset = vec(0, 0.64, -0.27), 
             	size = vec(1.7, 0.3, 0, 0),
             	debugDraw = true
          	},
          	{
             	class = "Clickable",
             	offset = vec(0, 0.62, 0.17),
             	size = vec(1.75, 0.5, 0.6),
             	debugDraw = true
          	}
THOM formaly known as tschrage
_______________________________________________
My MOD (LoG1): Castle Ringfort Thread
My MOD (LoG2): Journey To Justice Thread | Download
User avatar
cromcrom
Posts: 549
Joined: Tue Sep 11, 2012 7:16 am
Location: Chateauroux in a socialist s#!$*&% formerly known as "France"

Re: meaning of cbox1&2 [Solved]

Post by cromcrom »

Well, thanks, but it doesn't wok. Do I have to add the surface component ?
Any pic of what it looks like ? Maybe I have to properly set the editor ? Could last patch have broken this ?
A trip of a thousand leagues starts with a step.
User avatar
THOM
Posts: 1281
Joined: Wed Nov 20, 2013 11:35 pm
Location: Germany - Cologne
Contact:

Re: meaning of cbox1&2 [Solved]

Post by THOM »

Sorry - this was just meant to be an egsample.

You can add "debugDraw = true," in the objectdefinition at every component with a vecBox (surfaces, sockets, clickables...)
So add or enable this command in the definition of the specific object and you will see the Box in the game or in the peview.

In your case I guess it will like this

Code: Select all

{
			class = "ProjectileCollider",
			size = vec(1.1, 3, 0.8),
			debugDraw = true,
		},
THOM formaly known as tschrage
_______________________________________________
My MOD (LoG1): Castle Ringfort Thread
My MOD (LoG2): Journey To Justice Thread | Download
Post Reply