You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
AM2R-TimeTrials/objects/oEditorInfo.object.gmx

216 lines
6.2 KiB

<!--This Document is generated by GameMaker, if you edit it by hand then you do so at your own risk!-->
<object>
<spriteName>&lt;undefined&gt;</spriteName>
<solid>0</solid>
<visible>-1</visible>
<depth>-98</depth>
<persistent>0</persistent>
<parentName>&lt;undefined&gt;</parentName>
<maskName>&lt;undefined&gt;</maskName>
<events>
<event eventtype="0" enumb="0">
<action>
<libid>1</libid>
<id>603</id>
<kind>7</kind>
<userelative>0</userelative>
<isquestion>0</isquestion>
<useapplyto>-1</useapplyto>
<exetype>2</exetype>
<functionname></functionname>
<codestring></codestring>
<whoName>self</whoName>
<relative>0</relative>
<isnot>0</isnot>
<arguments>
<argument>
<kind>1</kind>
<string>mode = 0;
keyboard_string = "";
bu[0] = c_white;
bu[1] = c_white;
create_button_alt(214,80,200,10,0,oTrialEditor.stage_name,0,bu[0]);
create_button_alt(214,100,200,10,1,oTrialEditor.stage_auth,1,bu[1]);
create_button_alt(240,130,80,10,3,"Toggle",2,c_aqua);
create_button_alt(160,160,70,10,2,"Confirm",2,c_lime);
relay_button = -1;
type_mode = -1;
</string>
</argument>
</arguments>
</action>
</event>
<event eventtype="1" enumb="0">
<action>
<libid>1</libid>
<id>603</id>
<kind>7</kind>
<userelative>0</userelative>
<isquestion>0</isquestion>
<useapplyto>-1</useapplyto>
<exetype>2</exetype>
<functionname></functionname>
<codestring></codestring>
<whoName>self</whoName>
<relative>0</relative>
<isnot>0</isnot>
<arguments>
<argument>
<kind>1</kind>
<string>with (oInfoButton){ // you're coming with me!
instance_destroy();
}
// also set a mb lockout on the main obj so that you don't click randomly
oTrialEditor.lockout = 1;
</string>
</argument>
</arguments>
</action>
</event>
<event eventtype="3" enumb="0">
<action>
<libid>1</libid>
<id>603</id>
<kind>7</kind>
<userelative>0</userelative>
<isquestion>0</isquestion>
<useapplyto>-1</useapplyto>
<exetype>2</exetype>
<functionname></functionname>
<codestring></codestring>
<whoName>self</whoName>
<relative>0</relative>
<isnot>0</isnot>
<arguments>
<argument>
<kind>1</kind>
<string>//keyboard_string = string_lettersdigits(keyboard_string);
// i'll figure this out later
if (type_mode != -1){
// limit keyboard_string
keyboard_string = string_replace_all(keyboard_string,"#","");
if (string_length(keyboard_string) &gt; 40) keyboard_string = string_delete(keyboard_string,41,1);
if (type_mode == 0){ // name
oTrialEditor.stage_name = keyboard_string;
}else{ // author
oTrialEditor.stage_auth = keyboard_string;
}
if (keyboard_check_pressed(vk_enter)){
if string_lettersdigits(keyboard_string) = ""{
sfx_play(sndMenuCancel);
}else{
bu[0] = c_white;
bu[1] = c_white;
type_mode = -1;
sfx_play(sndMenuSel);
}
}
}
// info relays
if (relay_button &gt; -1){
switch (relay_button){
case 0: // start typing out name
type_mode = 0;
bu[0] = c_yellow;
keyboard_string = oTrialEditor.stage_name;
break;
case 1: // start typing out author
type_mode = 1;
bu[1] = c_yellow;
keyboard_string = oTrialEditor.stage_auth;
break;
case 2: // perish
instance_destroy();
break;
case 3: // set hidden block
if (oTrialEditor.objs_hidden){
oTrialEditor.objs_hidden = 0;
}else{
oTrialEditor.objs_hidden = 1;
}
break;
}
relay_button = -1;
}
// this is a really strange way of making button go
with (oInfoButton){
if (button_flag == 0){
button_string = oTrialEditor.stage_name;
button_border = other.bu[0];
if (other.type_mode == 0) then button_string = oTrialEditor.stage_name+"|";
}
if (button_flag == 1){
button_string = oTrialEditor.stage_auth;
button_border = other.bu[1];
if (other.type_mode == 1) then button_string = oTrialEditor.stage_auth+"|";
}
}
</string>
</argument>
</arguments>
</action>
</event>
<event eventtype="8" enumb="73">
<action>
<libid>1</libid>
<id>603</id>
<kind>7</kind>
<userelative>0</userelative>
<isquestion>0</isquestion>
<useapplyto>-1</useapplyto>
<exetype>2</exetype>
<functionname></functionname>
<codestring></codestring>
<whoName>self</whoName>
<relative>0</relative>
<isnot>0</isnot>
<arguments>
<argument>
<kind>1</kind>
<string>var cx = view_xview[0];
var cy = view_yview[0];
x = cx;
y = cy;
draw_set_color(c_black);
draw_set_alpha(0.5);
draw_rectangle((-60)+x,(-10)+y,426+x,250+y,false);
draw_set_alpha(1);
draw_set_font(fontGUI2Default);
draw_set_color(c_white);
draw_set_halign(fa_right);
draw_set_valign(fa_center);
draw_text(80+x,80+y,"Level Name");
draw_text(80+x,100+y,"Level Author");
draw_set_halign(fa_center);
var s = "Enabled";
if (oTrialEditor.objs_hidden = false) then s = "Disabled";
draw_text(80+x,130+y,"Hidden Blocks: "+s);
</string>
</argument>
</arguments>
</action>
</event>
</events>
<PhysicsObject>0</PhysicsObject>
<PhysicsObjectSensor>0</PhysicsObjectSensor>
<PhysicsObjectShape>0</PhysicsObjectShape>
<PhysicsObjectDensity>0.5</PhysicsObjectDensity>
<PhysicsObjectRestitution>0.100000001490116</PhysicsObjectRestitution>
<PhysicsObjectGroup>0</PhysicsObjectGroup>
<PhysicsObjectLinearDamping>0.100000001490116</PhysicsObjectLinearDamping>
<PhysicsObjectAngularDamping>0.100000001490116</PhysicsObjectAngularDamping>
<PhysicsObjectFriction>0.200000002980232</PhysicsObjectFriction>
<PhysicsObjectAwake>-1</PhysicsObjectAwake>
<PhysicsObjectKinematic>0</PhysicsObjectKinematic>
<PhysicsShapePoints/>
</object>