Help

Help with marble.cs file

Not completed

This is the default marble settings (for MBG. some things are limited to it though most is good for MBP too), found near the end of marble/client/marble.cs. You can modify this file (MBG), but I will also tell you the console commands *gets pickle to write codes for all values* :P

Code:

 

datablock MarbleData(DefaultMarble)
{
shapeFile = “~/data/shapes/balls/ball-superball.dts”;
emap = true;
renderFirstPerson = true;
// maxRollVelocity = 55;
// angularAcceleration = 120;
maxRollVelocity = 15;
angularAcceleration = 75;
brakingAcceleration = 30;
gravity = 20;
staticFriction = 1.1;
kineticFriction = 0.7;
bounceKineticFriction = 0.2;
maxDotSlide = 0.5;
bounceRestitution = 0.5;
jumpImpulse = 7.5;
maxForceRadius = 50; 

bounce1 = Bounce1Sfx;
bounce2 = Bounce2Sfx;
bounce3 = Bounce3Sfx;
bounce4 = Bounce4Sfx;

rollHardSound = RollingHardSfx;
slipSound = SlippingSfx;
jumpSound = JumpSfx;

// Emitters
minTrailSpeed = 10; // Trail threshold
trailEmitter = MarbleTrailEmitter;

minBounceSpeed = 3; // Bounce threshold
bounceEmitter = MarbleBounceEmitter;

powerUpEmitter[1] = MarbleSuperJumpEmitter;         // Super Jump
powerUpEmitter[2] = MarbleSuperSpeedEmitter;     // Super Speed
// powerUpEmitter[3] = MarbleSuperBounceEmitter;     // Super Bounce
// powerUpEmitter[4] = MarbleShockAbsorberEmitter;     // Shock Absorber
// powerUpEmitter[5] = MarbleHelicopterEmitter;     // Helicopter

// Power up timouts. Timeout on the speed and jump only affect
// the particle trail
powerUpTime[1] = 1000;    // Super Jump
powerUpTime[2] = 1000;     // Super Speed
powerUpTime[3] = 5000;     // Super Bounce
powerUpTime[4] = 5000;     // Shock Absorber
powerUpTime[5] = 5000;     // Helicopter

// Allowable Inventory Items
maxInv[SuperJumpItem] = 20;
maxInv[SuperSpeedItem] = 20;
maxInv[SuperBounceItem] = 20;
maxInv[IndestructibleItem] = 20;
maxInv[TimeTravelItem] = 20;
// maxInv[GoodiesItem] = 10;
};

I’ll do this line-by-line.

Code:

 

shapeFile = “~/data/shapes/balls/ball-superball.dts”;


(^^) This determines what shape file to use as the marble. For example, if you do

Code:

 

defaultmarble.shapefile = “~/data/shapes/hazards/oilslick.dts”;

into the console, it makes your marble oil-slick shaped. Unfortunately, it doesn’t roll :( (for MBP, do instead of defaultmarble the marble number. For example, Moshe marble is marblesixteen and the Staff’s Original is marbleone. This applies to all codes here.)

Code:

 

emap = true;


(^^) shows whether your marble is shiny or not when you have a opacity value on your marble skin.

Code:

 

defaultmarble.emap = false;

does the obvious.

Code:

 

renderFirstPerson = true;


(^^) Shows whether the camera stays with the marble.

Code:

 

defaultmarble.renderFirstPerson = false;

is something like this (link).

Code:

 

// maxRollVelocity = 55;
// angularAcceleration = 120;
maxRollVelocity = 15;
angularAcceleration = 75;
brakingAcceleration = 30;


(^^) I’m not sure what these do. If you’re nice enough to give me an explanation, I’ll add it :) (With credit of course!)

Code:

 

gravity = 20;


(^^) Pretty obvious :P

Code:

 

staticFriction = 1.1;


(^^) Marble’s static friction.

Code:

 

kineticFriction = 0.7;


(^^) Marble’s kinetic friction.

Code:

 

bounceKineticFriction = 0.2;


(^^) How much friction you get on a bounce.

Code:

 

maxDotSlide = 0.5;


(^^) Again, no idea :(. Please contribute.

Code:

 

bounceRestitution = 0.5;


(^^) How much you bounce from a fall. If I fall from 10 units, I will bounce back 5 units high. If I have a superbounce, I have a restitution of .8, and will bounce 8 units back up.

Code:

 

jumpImpulse = 7.5;


(^^) How high you jump. I think about 20 is a super jump [needs claification].

Code:

 

maxForceRadius = 50;


(^^) I know what this is, but what does it apply to? Please help.

Code:

 

bounce1 = Bounce1Sfx;
bounce2 = Bounce2Sfx;
bounce3 = Bounce3Sfx;
bounce4 = Bounce4Sfx; 

rollHardSound = RollingHardSfx;
slipSound = SlippingSfx;
jumpSound = JumpSfx;


(^^) Sound for bounces, rolls, etc.

Code:

 

minTrailSpeed = 10; // Trail threshold


(^^) How fast you need to be going before a trail is shown.

Code:

 

trailEmitter = MarbleTrailEmitter;


(^^) Not much here, just shows what emitter to use as a trail.

Code:

 

minBounceSpeed = 3; // Bounce threshold


(^^) How fast you need to hit a surface before you see sparks :P

Code:

 

bounceEmitter = MarbleBounceEmitter;


(^^) Kinda duuh…

Code:

 

powerUpEmitter[1] = MarbleSuperJumpEmitter;         // Super Jump
powerUpEmitter[2] = MarbleSuperSpeedEmitter;     // Super Speed


(^^) Standard powerup emitters.

Code:

 

// powerUpEmitter[3] = MarbleSuperBounceEmitter;     // Super Bounce
// powerUpEmitter[4] = MarbleShockAbsorberEmitter;     // Shock Absorber
// powerUpEmitter[5] = MarbleHelicopterEmitter;     // Helicopter


(^^) Does nothing, but something like

Code:

 

defaultmarble.powerUpEmitter[5] = MarbleSuperSpeedEmitter;

makes you have a yellow tail while flying, like a superspeed.

Code:

 

powerUpTime[1] = 1000;    // Super Jump
powerUpTime[2] = 1000;     // Super Speed


(^^) How long the trail is in place for (in milliseconds, of course)

Code:

 

powerUpTime[3] = 5000;     // Super Bounce
powerUpTime[4] = 5000;     // Shock Absorber
powerUpTime[5] = 5000;     // Helicopter


(^^) How long these PU’s last for. (MS)

Code:

 

maxInv[SuperJumpItem] = 20;
maxInv[SuperSpeedItem] = 20;
maxInv[SuperBounceItem] = 20;
maxInv[IndestructibleItem] = 20;
maxInv[TimeTravelItem] = 20;
// maxInv[GoodiesItem] = 10;


(^^) As far as I know, these do nothing. :P

I hope you enjoyed! Please help fill in where I don’t know :)

EDIT: Marble diameter is about 0.39744186046511627906976744186047 constructor/wold editor units.

EDIT: More commands can be gotton by typing

Code:

 

defaultmarble.dump();

(Siezure22)
I’m working on a guide for this to add to this one.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: