To edit maps, copy the following code into a file named example.smo.
In the game click Select Arena, then Load Mod, and load the file
Pres Alt+Enter to go windowed mode, and open the .smo file in a text editor. When the file game will automatically reload it.

Make sure, you have added 4 men in the arena.

Once you are done, feel free to upload your mods to youtube, and share your mod.

 

Example Code:

addbox( vec(20,2,50),vec(0,-8,0), 0,1);

addbox( vec(3,4,8),vec(-7,-6,0), 10,1);

addbox( vec(3,4,8),vec(7,-6,0), 10,1);

addbox( vec(8,17,10),vec(0,0,0), 6,1);

 

p=vec(0,1,0);

repeat(33) {

       p=rot(p,vec(pi*2/33,0,0));

       cutplane( p, -6);

};

 

addbox( vec(6,1,30),vec(0,7,0), 0,0);

addbox( vec(2,1,1),vec(3,10,0), 0,0);

addbox( vec(2,1,1),vec(-3,10,0), 0,0);

 

chair0(pos)={

       addbox(vec(4,1,3),pos+vec(0,5,0),1,1); breakability(80);

       addbox(vec(1,3,3),pos+vec(3,9,0),1,0); breakability(80);

       addbox(vec(1,2,3),pos+vec(3,2,0),1,1); breakability(80);

       addbox(vec(1,2,3),pos+vec(-3,2,0),1,1); breakability(80);

};

 

chair0(  vec(50,-10,0) );

 

man(vec(0,8,-28),vec(0,0,1),2);

man(vec(0,8,28),vec(0,0,-1),3);

man(vec(0,8,-18),vec(0,0,1),0);

man(vec(0,8,18),vec(0,0,-1),1);

 

Explanation:

 

vec: defines a 3D vector in the following form vec(x,y,z) ;  negative y is the direction of gravity.

 

addbox(  size_vector, position_vector,   texture,   0=moving  / 1=static );

adds one box. To get other shapes, use cut();

 

man( position_vector,  looking_vector,  texture_integer  );

Adds one guy. A mod must place 4 guys in the level. Position vector specifies the point between the two feet on the floor. Looking vector is used to turn the guy.  If you prefer to use angles, use: vec(sin(angle),0,cos(angle))

The texture integer is unused during real gameplay. In this editor program it sets the textuer, and 2=player1 controls, 3=player3 controls, all other numbers will make the AI control the guy

 

repeat( number ) {  };

Repeats the stuff inside.

 breakability ( number); sets the breakability of the last added box. A value of 250 will barely allow the guys to walk on it without breaking it.

 

vec = rot( vec,  axis);  rotates vec around axis. The angle is defined by the length of axis. The new vector is returned.

 

turnto( vec ); turns the last added box, so that its facing in the given direction

 

cutplane( normal, shift);  cuts the last added box with a plane. Used in this example to create a round cylinder.

 

random(0);  

the parameter is ignored, returns a vector within the range -1, 1 in all dimensions

 

Misc:

Variables:  All varables are 3D vectors. Can define them like position = vec(0,0,0);

Functions: They work as seen in the example with chair0.

 

Other functions: atanxy(vec),  abs(scalars),  cos(angles), sin(angles) , tan(angles) , atan( vec), dot(vec, vec), normalize(vec); mod(scalars)