## materials.xml.bin Reference Guide (beta)

15 replies [Last post]
Joined: 07/05/2011

### Attributes

id : Required : String : Examples grass, ice
The id of the material.

bounce : Required : Float : Examples 0, 0.2, 0.5
Things won't rebound when the value is less than or equal to 0. If the value is greater than 0, the rebound velocity = -impact velocity * bounce. Game treats the negative values as 0.

bounceminvel : Required : Float : Examples 0.05, 60, 102
Minimum Bounce Velocity. If the impact velocity is less than this value, things won't rebound. In the original file it is minbouncevel but it is not implemented in the game. So if you want to use this feature, use bounceminvel instead.

friction : Required : Float : Examples 0.5, 4, 100
Things will stop sliding by the resistance on the interface when the friction is greater than 0. The larger friction becomes, the faster things stop. Game treats the negative values as 0.

stickiness : Required : Float : Examples 0, 40, 70
Goo balls which are attached to other will be stuck on this interface when the stickiness is greater than or equals to 7.5.

Maybe there is something wrong with it. Moderator please check it before making a book page of it.

### EDIT & IMPORTANT: If the material of goo balls is set, the material of geometries will be ignored.

Sorry for editing the old post.

Joined: 08/06/2010

Nice, I was wondering how bounce worked. But what exactly do friction and stickiness mean? As in, of course friction=9 will stop sooner than friction=2.5, but how is it calculated?

Another Planet finally has an official release! Download chapters 1 through 3 here! Thank you for waiting so long while I kept starting over.

Joined: 07/05/2011

How bounce work is guessed by me because I noticed when bounce=1 goo balls keep bouncing at the same height. (by the way I made a material called bouncy in my new chapter which's bounce=20 and can push strands to the pipe)
About friction... I have no idea... I haven't test a lot yet. (maybe it is the decrease of the speed? I have no idea what speed unit the game is using)
About stickiness... I tested it for a long time... It doesn't seem to affect that the value is big or small... (when stickiness=7.5, it's really hard to pull the strand out of the wall; but when stickiness=7.49, the strands can't be stuck to the wall!)

EDIT: I have an idea to figure out what velocity unit the game is using. There is a velocity property in the World of Goo Corporation in the profile. I should test it with my modifier...

Joined: 08/06/2010

Good idea! I never would have thought of that.

Also, is there a max on friction? A value above which it just doesn't work?

Another Planet finally has an official release! Download chapters 1 through 3 here! Thank you for waiting so long while I kept starting over.

Joined: 07/05/2011

Good point. I will test them...
By the way, which idea do you mean? I have had bouncy idea since August last year when I was researching materials...

EDIT: In world of goo corporation, the goo ball got (0, -14.98) velocity when free falling.
(force=0, -10, dampeningfactor=0.5, Drained.mass=30)

Joined: 08/06/2010

The velocity idea.

It seems that the "force" (actually acceleration) is in meters per second squared, which makes sense for gravity being about -10. So assuming the Goo Ball weighs 30 kilograms, the force would be 300 (m*kg)/(s^2). Multiply that by the dampening factor of 0.5 and we get 150 (m*kg)/(s^2), or 150 Newtons, which seems to correspond nicely to the ~15 meters per second velocity. I'm blanking right now on the physics I need, but there should be some way to get rid of 10 kilograms per second there.

Another Planet finally has an official release! Download chapters 1 through 3 here! Thank you for waiting so long while I kept starting over.

Joined: 07/05/2011

It seems you are right. If I remove dampening factor, it will be accelerating. And I find most gravities in original levels has a dampeningfactor=0.5. That's why goo balls can move as uniform linear motion. So resistance from dampeningfactor is related to the speed.

Test result after removing dampeningfactor:
Velocity before test: (0, 0 )
Velocity after test: (0, -15.25)

If the level use gooTransition_in and gooTransition_out, the duration will be about 1.4s. (0.6+0.8 which is displayed in Goovie) -10*1.4=-14≈-15.25...

P.S. dampeningfactor=0.5, then if the resistance is air resistance, it might be possible to calculate out the density of the air on the planet.

EDIT: Found an interesting thing. If the dampeningfactor is too large like 100, goo balls can't get into it just like it's a rectangle. (but its bounce is much larger)
Another thing I found is that goo balls can still roll instead of sliding in a very small velocity when friction=100 and rectangle.rotation=-50.

EDIT again: ATTENTION! Any value of dampening factor larger than or equals to 39 will cause funny effects because the resistance will be too large to make things stop.

EDIT once again: A linearforcefield with force=0,0 dampeningfactor=61 is like a rectangle with bounce=1. When dampeningfactor=71, it is like a rectangle with bounce=about 1.5. When dampeningfactor=81, it is like a rectangle with bounce=about 2... That's funny...

EDIT twice again: The funnier thing is that dampeningfactor can be a negative value! Goo balls will increase the speed in it!

EDIT third time again: If rotationaldampeningfactor=1, the goo balls won't spin in it at all! If rotationaldampeningfactor<0, goo balls will increase the rotation speed in it. If rotationaldampeningfactor>1, goo balls will increase the rotation speed and keep changing their rotate direction! If the rotation speed is too fast, the goo ball will disappear when it collides something... That's fun.

Joined: 08/06/2010

WHOA! AWESOME!

I've got to try that negative dampening idea! This will work really well in my Tractorbeams level!

Another Planet finally has an official release! Download chapters 1 through 3 here! Thank you for waiting so long while I kept starting over.

Joined: 07/05/2011

Emm... I think the Reference Guide about force fields should be updated to help more people to discover it.

EDIT: A linearforcefield with dampeningfactor=-1 can only be discharged by a linearforcefield with dampeningfactor=1. Weirdly, a linearforcefield with rotationaldampeningfactor=-1 can only be discharged by a linearforcefield with rotationaldampeningfactor=0.5. (their sum doesn't equals to zero) But luckily, geomonly works for forcefields with negative dampeningfactor. So we could make a goo-only forcefield by creating two opposite forcefield and one of them is geomonly.

Joined: 08/06/2010

Well, of course. Don't they use that in AB3?

The rotational dampening factor must be calculated differently, but I don't know how it's scaled.

Another Planet finally has an official release! Download chapters 1 through 3 here! Thank you for waiting so long while I kept starting over.

Joined: 07/05/2011

Albino Pokey wrote:
Don't they use that in AB3?
Use what? Goo-only force fields is only used in the last level. (OOS)

Joined: 08/06/2010

*facepalm* Sorry, I'm feeling really stupid now. I thought only Goo Balls were pulled through the "pipes", not blocks, before remembering that the blocks are Goo Balls.

Another Planet finally has an official release! Download chapters 1 through 3 here! Thank you for waiting so long while I kept starting over.

Joined: 04/29/2009

Good findings, especially about the materials.
I knew about the forcefield things already, but it's good you posted them.
Don't know why I never did.
One thing I'd like to add. The maximum number of forcefields used in one level is 31, anything above will crash the game.

Joined: 03/13/2012

Hi! How About i make some samples, showing how these things work? Like a wall with several segments of custom materials with different stickiness? Or a little level with different slides?

Because writing signatures is too mainstream

Joined: 07/05/2011

nothinggoo wrote:
Hi! How About i make some samples, showing how these things work? Like a wall with several segments of custom materials with different stickiness? Or a little level with different slides?
That would be good. It will be better if you add some funny stuff in it.

Joined: 03/13/2012

If you wish . I well create three levels demonstrating how things work with attempts of funny stuff

Because writing signatures is too mainstream