{
	"name": "ev_player",
	"events": [
		{
			"eventType": "variable",
			"name": "PLAYER_SPEED_NORM",
			"type": "number",
			"initialValue": "125",
			"comment": "",
			"isStatic": false,
			"isConstant": true,
			"sid": 424448391776954
		},
		{
			"eventType": "variable",
			"name": "PLAYER_SPEED_CROUCH",
			"type": "number",
			"initialValue": "50",
			"comment": "",
			"isStatic": false,
			"isConstant": true,
			"sid": 453471464845002
		},
		{
			"eventType": "variable",
			"name": "PLAYER_JUMPSTR_NORM",
			"type": "number",
			"initialValue": "360",
			"comment": "",
			"isStatic": false,
			"isConstant": true,
			"sid": 577501879859603
		},
		{
			"eventType": "variable",
			"name": "PLAYER_JUMPSTR_CROUCH",
			"type": "number",
			"initialValue": "300",
			"comment": "",
			"isStatic": false,
			"isConstant": true,
			"sid": 240199988321711
		},
		{
			"eventType": "variable",
			"name": "GAME_STATE_FALLING",
			"type": "number",
			"initialValue": "0",
			"comment": "",
			"isStatic": false,
			"isConstant": true,
			"sid": 641242354689719
		},
		{
			"eventType": "variable",
			"name": "GAME_STATE_PILOTING",
			"type": "number",
			"initialValue": "1",
			"comment": "",
			"isStatic": false,
			"isConstant": true,
			"sid": 148176831675037
		},
		{
			"eventType": "variable",
			"name": "PLAYER_MAX_HP",
			"type": "number",
			"initialValue": "7",
			"comment": "",
			"isStatic": false,
			"isConstant": true,
			"sid": 619542988559660
		},
		{
			"eventType": "variable",
			"name": "spaceLayoutGameplayState",
			"type": "number",
			"initialValue": "0",
			"comment": "0 = falling, 1 = piloting",
			"isStatic": false,
			"isConstant": false,
			"sid": 358957929072161
		},
		{
			"eventType": "variable",
			"name": "SHIP_ACCEL",
			"type": "number",
			"initialValue": "200",
			"comment": "",
			"isStatic": false,
			"isConstant": true,
			"sid": 337938430256037
		},
		{
			"eventType": "block",
			"conditions": [
				{
					"id": "every-tick",
					"objectClass": "System",
					"sid": 241748603201764
				}
			],
			"actions": [
				{
					"id": "set-position",
					"objectClass": "player_anim",
					"sid": 465883377385760,
					"parameters": {
						"x": "player_base.X",
						"y": "player_base.Y"
					}
				},
				{
					"id": "set-instvar-value",
					"objectClass": "shipController",
					"sid": 292029539757176,
					"parameters": {
						"instance-variable": "dmgPercent",
						"value": "clamp(Self.dmgPercent, 0, 100)"
					}
				},
				{
					"id": "set-instvar-value",
					"objectClass": "player_base",
					"sid": 824663636242691,
					"parameters": {
						"instance-variable": "health",
						"value": "clamp(Self.health, 0, PLAYER_MAX_HP)"
					}
				}
			],
			"sid": 914220584197158,
			"children": [
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "is-boolean-instance-variable-set",
							"objectClass": "player_base",
							"sid": 223729048730893,
							"parameters": {
								"instance-variable": "isCrouching"
							}
						}
					],
					"actions": [
						{
							"id": "set-max-speed",
							"objectClass": "player_base",
							"sid": 247973242644602,
							"behaviorType": "Platform",
							"parameters": {
								"max-speed": "PLAYER_SPEED_CROUCH"
							}
						},
						{
							"id": "set-jump-strength",
							"objectClass": "player_base",
							"sid": 716974132772966,
							"behaviorType": "Platform",
							"parameters": {
								"jump-strength": "PLAYER_JUMPSTR_CROUCH"
							}
						}
					],
					"sid": 180950993041843
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "is-boolean-instance-variable-set",
							"objectClass": "player_base",
							"sid": 356263166695418,
							"parameters": {
								"instance-variable": "isCrouching"
							},
							"isInverted": true
						}
					],
					"actions": [
						{
							"id": "set-max-speed",
							"objectClass": "player_base",
							"sid": 840356932403275,
							"behaviorType": "Platform",
							"parameters": {
								"max-speed": "PLAYER_SPEED_NORM"
							}
						},
						{
							"id": "set-jump-strength",
							"objectClass": "player_base",
							"sid": 195169779270452,
							"behaviorType": "Platform",
							"parameters": {
								"jump-strength": "PLAYER_JUMPSTR_NORM"
							}
						}
					],
					"sid": 251978214091063
				}
			]
		},
		{
			"eventType": "block",
			"conditions": [
				{
					"id": "on-created",
					"objectClass": "player_base",
					"sid": 745493009369563
				}
			],
			"actions": [
				{
					"id": "set-instvar-value",
					"objectClass": "player_base",
					"sid": 234591359743533,
					"parameters": {
						"instance-variable": "health",
						"value": "PLAYER_MAX_HP"
					}
				},
				{
					"id": "set-solid-collision-filter",
					"objectClass": "player_base",
					"sid": 911835241896088,
					"parameters": {
						"mode": "exclusive",
						"tags": "\"shipcollider\""
					}
				},
				{
					"id": "set-visible",
					"objectClass": "player_base",
					"sid": 501778373950398,
					"parameters": {
						"visibility": "invisible"
					}
				}
			],
			"sid": 800819495970416
		},
		{
			"eventType": "block",
			"conditions": [
				{
					"id": "on-timer",
					"objectClass": "SysObj",
					"sid": 164237989166660,
					"behaviorType": "Timer",
					"parameters": {
						"tag": "\"invuln_timer\""
					}
				}
			],
			"actions": [
				{
					"id": "set-boolean-instvar",
					"objectClass": "player_base",
					"sid": 778417405057428,
					"parameters": {
						"instance-variable": "isInvulnerable",
						"value": "false"
					}
				}
			],
			"sid": 399582318413940
		},
		{
			"eventType": "group",
			"disabled": false,
			"title": "Player movement",
			"description": "",
			"isActiveOnStart": true,
			"children": [
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "is-button-down",
							"objectClass": "Gamepad",
							"sid": 575518790988567,
							"parameters": {
								"gamepad": "0",
								"button": "d-pad-down"
							}
						},
						{
							"id": "is-falling",
							"objectClass": "player_base",
							"sid": 905086365740227,
							"behaviorType": "Platform",
							"isInverted": true
						},
						{
							"id": "is-jumping",
							"objectClass": "player_base",
							"sid": 968323295392830,
							"behaviorType": "Platform",
							"isInverted": true
						}
					],
					"actions": [
						{
							"id": "set-boolean-instvar",
							"objectClass": "player_base",
							"sid": 213121758178697,
							"parameters": {
								"instance-variable": "isCrouching",
								"value": "true"
							}
						}
					],
					"sid": 353970814117523
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "compare-axis",
							"objectClass": "Gamepad",
							"sid": 749365781685690,
							"parameters": {
								"gamepad": "0",
								"axis": "left-analog-y-axis",
								"comparison": 4,
								"value": "50"
							}
						},
						{
							"id": "is-falling",
							"objectClass": "player_base",
							"sid": 276234478548756,
							"behaviorType": "Platform",
							"isInverted": true
						},
						{
							"id": "is-jumping",
							"objectClass": "player_base",
							"sid": 677616694544560,
							"behaviorType": "Platform",
							"isInverted": true
						}
					],
					"actions": [
						{
							"id": "set-boolean-instvar",
							"objectClass": "player_base",
							"sid": 331899697787755,
							"parameters": {
								"instance-variable": "isCrouching",
								"value": "true"
							}
						}
					],
					"sid": 745502921774587
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "on-button-pressed",
							"objectClass": "Gamepad",
							"sid": 727536907566861,
							"parameters": {
								"gamepad": "0",
								"button": "button-a"
							}
						},
						{
							"id": "is-button-down",
							"objectClass": "Gamepad",
							"sid": 276396156866965,
							"parameters": {
								"gamepad": "0",
								"button": "d-pad-down"
							}
						}
					],
					"actions": [
						{
							"id": "fall-through",
							"objectClass": "player_base",
							"sid": 330100457081646,
							"behaviorType": "Platform"
						}
					],
					"sid": 371392893668972
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "on-button-pressed",
							"objectClass": "Gamepad",
							"sid": 506097073613401,
							"parameters": {
								"gamepad": "0",
								"button": "button-a"
							}
						},
						{
							"id": "compare-axis",
							"objectClass": "Gamepad",
							"sid": 246784850946304,
							"parameters": {
								"gamepad": "0",
								"axis": "left-analog-y-axis",
								"comparison": 4,
								"value": "0"
							}
						}
					],
					"actions": [
						{
							"id": "fall-through",
							"objectClass": "player_base",
							"sid": 436897651213576,
							"behaviorType": "Platform"
						}
					],
					"sid": 355348435461702
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "is-button-down",
							"objectClass": "Gamepad",
							"sid": 948701794825067,
							"parameters": {
								"gamepad": "0",
								"button": "d-pad-down"
							},
							"isInverted": true
						},
						{
							"id": "compare-axis",
							"objectClass": "Gamepad",
							"sid": 767014308497294,
							"parameters": {
								"gamepad": "0",
								"axis": "left-analog-y-axis",
								"comparison": 3,
								"value": "50"
							}
						}
					],
					"actions": [
						{
							"id": "set-boolean-instvar",
							"objectClass": "player_base",
							"sid": 213619088307168,
							"parameters": {
								"instance-variable": "isCrouching",
								"value": "false"
							}
						}
					],
					"sid": 617221069659756
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "is-button-down",
							"objectClass": "Gamepad",
							"sid": 865918500864153,
							"parameters": {
								"gamepad": "0",
								"button": "d-pad-left"
							}
						}
					],
					"actions": [
						{
							"id": "simulate-control",
							"objectClass": "player_base",
							"sid": 549759622384548,
							"behaviorType": "Platform",
							"parameters": {
								"control": "left"
							}
						},
						{
							"id": "set-boolean-instvar",
							"objectClass": "player_base",
							"sid": 873829017654280,
							"parameters": {
								"instance-variable": "isMovingRight",
								"value": "false"
							}
						}
					],
					"sid": 424614335878968
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "is-button-down",
							"objectClass": "Gamepad",
							"sid": 563600725196223,
							"parameters": {
								"gamepad": "0",
								"button": "d-pad-right"
							}
						}
					],
					"actions": [
						{
							"id": "simulate-control",
							"objectClass": "player_base",
							"sid": 266051940706711,
							"behaviorType": "Platform",
							"parameters": {
								"control": "right"
							}
						},
						{
							"id": "set-boolean-instvar",
							"objectClass": "player_base",
							"sid": 522777852579116,
							"parameters": {
								"instance-variable": "isMovingRight",
								"value": "true"
							}
						}
					],
					"sid": 560188160438501
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "on-button-pressed",
							"objectClass": "Gamepad",
							"sid": 633898020509532,
							"parameters": {
								"gamepad": "0",
								"button": "button-a"
							}
						}
					],
					"actions": [
						{
							"id": "simulate-control",
							"objectClass": "player_base",
							"sid": 902763714730367,
							"behaviorType": "Platform",
							"parameters": {
								"control": "jump"
							}
						}
					],
					"sid": 707306685598762,
					"children": [
						{
							"eventType": "block",
							"conditions": [
								{
									"id": "is-jumping",
									"objectClass": "player_base",
									"sid": 355200731780207,
									"behaviorType": "Platform",
									"isInverted": true
								},
								{
									"id": "is-falling",
									"objectClass": "player_base",
									"sid": 599746322140150,
									"behaviorType": "Platform",
									"isInverted": true
								}
							],
							"actions": [
								{
									"id": "play-by-name",
									"objectClass": "Audio",
									"sid": 370473796966869,
									"parameters": {
										"folder": "sounds",
										"audio-file-name": "\"jump\"",
										"loop": "not-looping",
										"volume": "0",
										"tag-optional": "\"jump\""
									}
								}
							],
							"sid": 640234743605303
						}
					]
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "compare-axis",
							"objectClass": "Gamepad",
							"sid": 227621796451583,
							"parameters": {
								"gamepad": "0",
								"axis": "left-analog-x-axis",
								"comparison": 4,
								"value": "0"
							}
						}
					],
					"actions": [
						{
							"id": "simulate-control",
							"objectClass": "player_base",
							"sid": 798160765930876,
							"behaviorType": "Platform",
							"parameters": {
								"control": "right"
							}
						},
						{
							"id": "set-boolean-instvar",
							"objectClass": "player_base",
							"sid": 628055380132209,
							"parameters": {
								"instance-variable": "isMovingRight",
								"value": "true"
							}
						}
					],
					"sid": 324579378057540
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "compare-axis",
							"objectClass": "Gamepad",
							"sid": 408177941034418,
							"parameters": {
								"gamepad": "0",
								"axis": "left-analog-x-axis",
								"comparison": 2,
								"value": "0"
							}
						}
					],
					"actions": [
						{
							"id": "simulate-control",
							"objectClass": "player_base",
							"sid": 366154608661313,
							"behaviorType": "Platform",
							"parameters": {
								"control": "left"
							}
						},
						{
							"id": "set-boolean-instvar",
							"objectClass": "player_base",
							"sid": 685986681971230,
							"parameters": {
								"instance-variable": "isMovingRight",
								"value": "false"
							}
						}
					],
					"sid": 851878996679840
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "is-boolean-instance-variable-set",
							"objectClass": "shipController",
							"sid": 552674589474216,
							"parameters": {
								"instance-variable": "isActive"
							}
						}
					],
					"actions": [
						{
							"id": "set-position",
							"objectClass": "player_base",
							"sid": 203961938740819,
							"parameters": {
								"x": "shipController.X",
								"y": "shipController.Y"
							}
						}
					],
					"sid": 830849248572526
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "is-on-floor",
							"objectClass": "player_base",
							"sid": 174341150713176,
							"behaviorType": "Platform"
						},
						{
							"id": "trigger-once-while-true",
							"objectClass": "System",
							"sid": 870227551288569
						}
					],
					"actions": [
						{
							"id": "play-by-name",
							"objectClass": "Audio",
							"sid": 619223922204459,
							"parameters": {
								"folder": "sounds",
								"audio-file-name": "\"land\"",
								"loop": "not-looping",
								"volume": "0",
								"tag-optional": "\"land\""
							}
						}
					],
					"sid": 198637903678477
				}
			],
			"sid": 305367303219703
		},
		{
			"eventType": "group",
			"disabled": false,
			"title": "Crouching",
			"description": "",
			"isActiveOnStart": true,
			"children": [
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "is-boolean-instance-variable-set",
							"objectClass": "player_base",
							"sid": 256218709330252,
							"parameters": {
								"instance-variable": "isCrouching"
							}
						}
					],
					"actions": [
						{
							"id": "set-animation-frame",
							"objectClass": "player_base",
							"sid": 283230275195069,
							"parameters": {
								"frame-number": "1"
							}
						}
					],
					"sid": 620400580223005
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "else",
							"objectClass": "System",
							"sid": 607514565543231
						}
					],
					"actions": [
						{
							"id": "set-animation-frame",
							"objectClass": "player_base",
							"sid": 411224314946345,
							"parameters": {
								"frame-number": "0"
							}
						}
					],
					"sid": 188640382219482
				}
			],
			"sid": 760157679773339
		},
		{
			"eventType": "group",
			"disabled": false,
			"title": "Animation",
			"description": "",
			"isActiveOnStart": true,
			"children": [
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "is-enabled",
							"objectClass": "player_base",
							"sid": 910273434713221,
							"behaviorType": "Platform"
						}
					],
					"actions": [],
					"sid": 854503939951843,
					"children": [
						{
							"eventType": "block",
							"conditions": [
								{
									"id": "is-boolean-instance-variable-set",
									"objectClass": "player_base",
									"sid": 251431203362951,
									"parameters": {
										"instance-variable": "isMovingRight"
									}
								}
							],
							"actions": [
								{
									"id": "set-mirrored",
									"objectClass": "player_anim",
									"sid": 902604103085912,
									"parameters": {
										"state": "not-mirrored"
									}
								}
							],
							"sid": 559386644592717
						},
						{
							"eventType": "block",
							"conditions": [
								{
									"id": "is-boolean-instance-variable-set",
									"objectClass": "player_base",
									"sid": 369123633208075,
									"parameters": {
										"instance-variable": "isMovingRight"
									},
									"isInverted": true
								}
							],
							"actions": [
								{
									"id": "set-mirrored",
									"objectClass": "player_anim",
									"sid": 167642325230064,
									"parameters": {
										"state": "mirrored"
									}
								}
							],
							"sid": 949518219478551
						},
						{
							"eventType": "block",
							"conditions": [
								{
									"id": "is-boolean-instance-variable-set",
									"objectClass": "player_base",
									"sid": 721394692725006,
									"parameters": {
										"instance-variable": "isCrouching"
									}
								},
								{
									"id": "is-moving",
									"objectClass": "player_base",
									"sid": 874479917379689,
									"behaviorType": "Platform"
								}
							],
							"actions": [
								{
									"id": "set-animation",
									"objectClass": "player_anim",
									"sid": 113611139498664,
									"parameters": {
										"animation": "\"crawl\"",
										"from": "beginning"
									}
								}
							],
							"sid": 561800709810578
						},
						{
							"eventType": "block",
							"conditions": [
								{
									"id": "is-boolean-instance-variable-set",
									"objectClass": "player_base",
									"sid": 701021759700838,
									"parameters": {
										"instance-variable": "isCrouching"
									}
								},
								{
									"id": "is-moving",
									"objectClass": "player_base",
									"sid": 831069460470393,
									"behaviorType": "Platform",
									"isInverted": true
								}
							],
							"actions": [
								{
									"id": "set-animation",
									"objectClass": "player_anim",
									"sid": 887643072414104,
									"parameters": {
										"animation": "\"crouch\"",
										"from": "beginning"
									}
								}
							],
							"sid": 677825080253365
						},
						{
							"eventType": "block",
							"conditions": [
								{
									"id": "is-boolean-instance-variable-set",
									"objectClass": "player_base",
									"sid": 843159355471036,
									"parameters": {
										"instance-variable": "isCrouching"
									},
									"isInverted": true
								}
							],
							"actions": [],
							"sid": 259465014502294,
							"children": [
								{
									"eventType": "block",
									"conditions": [
										{
											"id": "is-moving",
											"objectClass": "player_base",
											"sid": 707567884496904,
											"behaviorType": "Platform"
										},
										{
											"id": "is-jumping",
											"objectClass": "player_base",
											"sid": 603391299537451,
											"behaviorType": "Platform",
											"isInverted": true
										}
									],
									"actions": [
										{
											"id": "set-animation",
											"objectClass": "player_anim",
											"sid": 964924855338769,
											"parameters": {
												"animation": "\"run\"",
												"from": "beginning"
											}
										}
									],
									"sid": 666232100445532
								},
								{
									"eventType": "block",
									"conditions": [
										{
											"id": "is-jumping",
											"objectClass": "player_base",
											"sid": 317081129522096,
											"behaviorType": "Platform"
										}
									],
									"actions": [
										{
											"id": "set-animation",
											"objectClass": "player_anim",
											"sid": 187109914211667,
											"parameters": {
												"animation": "\"jump\"",
												"from": "beginning"
											}
										}
									],
									"sid": 587897939194477,
									"isOrBlock": true
								},
								{
									"eventType": "block",
									"conditions": [
										{
											"id": "is-falling",
											"objectClass": "player_base",
											"sid": 600919939908402,
											"behaviorType": "Platform"
										}
									],
									"actions": [
										{
											"id": "set-animation",
											"objectClass": "player_anim",
											"sid": 214343139164245,
											"parameters": {
												"animation": "\"fall\"",
												"from": "beginning"
											}
										}
									],
									"sid": 744041677802110
								},
								{
									"eventType": "block",
									"conditions": [
										{
											"id": "is-moving",
											"objectClass": "player_base",
											"sid": 597242758934230,
											"behaviorType": "Platform",
											"isInverted": true
										}
									],
									"actions": [
										{
											"id": "set-animation",
											"objectClass": "player_anim",
											"sid": 947612993016705,
											"parameters": {
												"animation": "\"idle\"",
												"from": "beginning"
											}
										}
									],
									"sid": 384097359655549
								}
							]
						}
					]
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "else",
							"objectClass": "System",
							"sid": 590527296669645
						},
						{
							"id": "is-boolean-instance-variable-set",
							"objectClass": "player_base",
							"sid": 919122709557889,
							"parameters": {
								"instance-variable": "isRepairing"
							},
							"isInverted": true
						}
					],
					"actions": [
						{
							"id": "set-animation",
							"objectClass": "player_anim",
							"sid": 301847057341391,
							"parameters": {
								"animation": "\"idle\"",
								"from": "beginning"
							}
						}
					],
					"sid": 940659418535621
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "is-boolean-instance-variable-set",
							"objectClass": "player_base",
							"sid": 979048082994086,
							"parameters": {
								"instance-variable": "isRepairing"
							}
						},
						{
							"id": "trigger-once-while-true",
							"objectClass": "System",
							"sid": 522945586198075
						}
					],
					"actions": [
						{
							"id": "set-enabled",
							"objectClass": "player_base",
							"sid": 516267029115421,
							"behaviorType": "Platform",
							"parameters": {
								"state": "disabled"
							}
						},
						{
							"id": "set-animation",
							"objectClass": "player_anim",
							"sid": 695116611226626,
							"parameters": {
								"animation": "\"repair\"",
								"from": "beginning"
							}
						}
					],
					"sid": 342471976558411
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "is-boolean-instance-variable-set",
							"objectClass": "player_base",
							"sid": 341038363113792,
							"parameters": {
								"instance-variable": "isRepairing"
							},
							"isInverted": true
						}
					],
					"actions": [
						{
							"id": "set-enabled",
							"objectClass": "player_base",
							"sid": 873932572529143,
							"behaviorType": "Platform",
							"parameters": {
								"state": "enabled"
							}
						}
					],
					"sid": 968746425484393
				}
			],
			"sid": 566218327472240
		},
		{
			"eventType": "group",
			"disabled": false,
			"title": "Ship controls",
			"description": "",
			"isActiveOnStart": true,
			"children": [
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "on-created",
							"objectClass": "shipController",
							"sid": 984036491588106
						}
					],
					"actions": [
						{
							"id": "set-acceleration",
							"objectClass": "shipController",
							"sid": 556533001375597,
							"behaviorType": "8Direction",
							"parameters": {
								"acceleration": "SHIP_ACCEL"
							}
						},
						{
							"id": "set-enabled",
							"objectClass": "shipController",
							"sid": 843875799410162,
							"behaviorType": "8Direction",
							"parameters": {
								"state": "disabled"
							}
						},
						{
							"id": "set-instvar-value",
							"objectClass": "shipController",
							"sid": 224028831799832,
							"parameters": {
								"instance-variable": "dmgPercent",
								"value": "0"
							}
						}
					],
					"sid": 120258418584630
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "is-boolean-instance-variable-set",
							"objectClass": "shipController",
							"sid": 327037121600887,
							"parameters": {
								"instance-variable": "isActive"
							}
						}
					],
					"actions": [
						{
							"id": "set-enabled",
							"objectClass": "player_base",
							"sid": 554242185650519,
							"behaviorType": "Platform",
							"parameters": {
								"state": "disabled"
							}
						}
					],
					"sid": 919287060543065
				},
				{
					"eventType": "group",
					"disabled": false,
					"title": "Activate ship",
					"description": "",
					"isActiveOnStart": true,
					"children": [
						{
							"eventType": "block",
							"conditions": [
								{
									"id": "is-boolean-instance-variable-set",
									"objectClass": "shipController",
									"sid": 552714340182090,
									"parameters": {
										"instance-variable": "isActive"
									}
								},
								{
									"id": "trigger-once-while-true",
									"objectClass": "System",
									"sid": 886206379198210
								}
							],
							"actions": [
								{
									"id": "set-visible",
									"objectClass": "wheelHighlight",
									"sid": 521735312019654,
									"parameters": {
										"visibility": "invisible"
									}
								},
								{
									"id": "set-enabled",
									"objectClass": "ship_col_1",
									"sid": 796757429280354,
									"behaviorType": "Solid",
									"parameters": {
										"state": "disabled"
									}
								},
								{
									"id": "unpin",
									"objectClass": "ship_col_1",
									"sid": 502702494393935,
									"behaviorType": "Pin"
								},
								{
									"id": "set-enabled",
									"objectClass": "shipController",
									"sid": 749609226425147,
									"behaviorType": "8Direction",
									"parameters": {
										"state": "enabled"
									}
								},
								{
									"id": "set-collisions-enabled",
									"objectClass": "shipController",
									"sid": 768837992314470,
									"parameters": {
										"collisions": "disabled"
									}
								},
								{
									"id": "set-size",
									"objectClass": "shipController",
									"sid": 910421976557735,
									"parameters": {
										"width": "ship_entire_collider_1.Width - 8",
										"height": "ship_entire_collider_1.Height - 8"
									}
								},
								{
									"id": "set-position-to-another-object",
									"objectClass": "shipController",
									"sid": 800596218027603,
									"parameters": {
										"object": "ship_entire_collider_1",
										"image-point-optional": "0"
									}
								},
								{
									"id": "pin-to-object",
									"objectClass": "ship_col_1",
									"sid": 302703469121847,
									"behaviorType": "Pin",
									"parameters": {
										"pin-to": "shipController",
										"mode": "position-angle"
									}
								},
								{
									"id": "set-enabled",
									"objectClass": "player_base",
									"sid": 415910874472860,
									"behaviorType": "Platform",
									"parameters": {
										"state": "disabled"
									}
								},
								{
									"id": "set-collisions-enabled",
									"objectClass": "player_base",
									"sid": 802627736948111,
									"parameters": {
										"collisions": "disabled"
									}
								},
								{
									"id": "set-position",
									"objectClass": "player_base",
									"sid": 423802826550437,
									"parameters": {
										"x": "shipController.X",
										"y": "shipController.Y"
									}
								},
								{
									"id": "set-collisions-enabled",
									"objectClass": "shipController",
									"sid": 276315041844787,
									"parameters": {
										"collisions": "enabled"
									}
								}
							],
							"sid": 780642409012874
						}
					],
					"sid": 439491808654925
				},
				{
					"eventType": "group",
					"disabled": false,
					"title": "Ship movement",
					"description": "",
					"isActiveOnStart": true,
					"children": [
						{
							"eventType": "block",
							"conditions": [
								{
									"id": "is-boolean-instance-variable-set",
									"objectClass": "shipController",
									"sid": 902525577132129,
									"parameters": {
										"instance-variable": "isActive"
									}
								}
							],
							"actions": [
								{
									"id": "set-instvar-value",
									"objectClass": "shipController",
									"sid": 611054825061171,
									"parameters": {
										"instance-variable": "dirX",
										"value": "Gamepad.Axis(0, 0) / 100"
									}
								},
								{
									"id": "set-instvar-value",
									"objectClass": "shipController",
									"sid": 915552265053195,
									"parameters": {
										"instance-variable": "dirY",
										"value": "Gamepad.Axis(0, 1) / 100"
									}
								}
							],
							"sid": 210488695218392,
							"children": [
								{
									"eventType": "block",
									"conditions": [
										{
											"id": "compare-axis",
											"objectClass": "Gamepad",
											"sid": 745170260851091,
											"parameters": {
												"gamepad": "0",
												"axis": "left-analog-x-axis",
												"comparison": 4,
												"value": "0"
											}
										}
									],
									"actions": [
										{
											"id": "simulate-control",
											"objectClass": "shipController",
											"sid": 391924534397474,
											"behaviorType": "8Direction",
											"parameters": {
												"control": "right"
											}
										}
									],
									"sid": 326087954890515,
									"children": [
										{
											"eventType": "block",
											"conditions": [
												{
													"id": "is-tag-playing",
													"objectClass": "Audio",
													"sid": 406258605570054,
													"parameters": {
														"tag": "\"engine\""
													},
													"isInverted": true
												}
											],
											"actions": [
												{
													"id": "play-by-name",
													"objectClass": "Audio",
													"sid": 733245412566645,
													"parameters": {
														"folder": "sounds",
														"audio-file-name": "\"engine\"",
														"loop": "looping",
														"volume": "0",
														"tag-optional": "\"engine\""
													}
												}
											],
											"sid": 669148918110389
										}
									]
								},
								{
									"eventType": "block",
									"conditions": [
										{
											"id": "compare-axis",
											"objectClass": "Gamepad",
											"sid": 108229902140817,
											"parameters": {
												"gamepad": "0",
												"axis": "left-analog-x-axis",
												"comparison": 2,
												"value": "0"
											}
										}
									],
									"actions": [
										{
											"id": "simulate-control",
											"objectClass": "shipController",
											"sid": 170337743031352,
											"behaviorType": "8Direction",
											"parameters": {
												"control": "left"
											}
										}
									],
									"sid": 736142571537243,
									"children": [
										{
											"eventType": "block",
											"conditions": [
												{
													"id": "is-tag-playing",
													"objectClass": "Audio",
													"sid": 400569585421666,
													"parameters": {
														"tag": "\"engine\""
													},
													"isInverted": true
												}
											],
											"actions": [
												{
													"id": "play-by-name",
													"objectClass": "Audio",
													"sid": 601804647324968,
													"parameters": {
														"folder": "sounds",
														"audio-file-name": "\"engine\"",
														"loop": "looping",
														"volume": "0",
														"tag-optional": "\"engine\""
													}
												}
											],
											"sid": 184186437112573
										}
									]
								},
								{
									"eventType": "block",
									"conditions": [
										{
											"id": "compare-axis",
											"objectClass": "Gamepad",
											"sid": 425330585417403,
											"parameters": {
												"gamepad": "0",
												"axis": "left-analog-y-axis",
												"comparison": 2,
												"value": "0"
											}
										}
									],
									"actions": [
										{
											"id": "simulate-control",
											"objectClass": "shipController",
											"sid": 281264644073840,
											"behaviorType": "8Direction",
											"parameters": {
												"control": "up"
											}
										}
									],
									"sid": 843050880286876,
									"children": [
										{
											"eventType": "block",
											"conditions": [
												{
													"id": "is-tag-playing",
													"objectClass": "Audio",
													"sid": 923951021541081,
													"parameters": {
														"tag": "\"engine\""
													},
													"isInverted": true
												}
											],
											"actions": [
												{
													"id": "play-by-name",
													"objectClass": "Audio",
													"sid": 115849060439809,
													"parameters": {
														"folder": "sounds",
														"audio-file-name": "\"engine\"",
														"loop": "looping",
														"volume": "0",
														"tag-optional": "\"engine\""
													}
												}
											],
											"sid": 794455877334833
										}
									]
								},
								{
									"eventType": "block",
									"conditions": [
										{
											"id": "compare-axis",
											"objectClass": "Gamepad",
											"sid": 360963622185030,
											"parameters": {
												"gamepad": "0",
												"axis": "left-analog-y-axis",
												"comparison": 4,
												"value": "0"
											}
										}
									],
									"actions": [
										{
											"id": "simulate-control",
											"objectClass": "shipController",
											"sid": 652840433627092,
											"behaviorType": "8Direction",
											"parameters": {
												"control": "down"
											}
										}
									],
									"sid": 409909337589149,
									"children": [
										{
											"eventType": "block",
											"conditions": [
												{
													"id": "is-tag-playing",
													"objectClass": "Audio",
													"sid": 772185469529087,
													"parameters": {
														"tag": "\"engine\""
													},
													"isInverted": true
												}
											],
											"actions": [
												{
													"id": "play-by-name",
													"objectClass": "Audio",
													"sid": 877585185832512,
													"parameters": {
														"folder": "sounds",
														"audio-file-name": "\"engine\"",
														"loop": "looping",
														"volume": "0",
														"tag-optional": "\"engine\""
													}
												}
											],
											"sid": 307114811990829
										}
									]
								},
								{
									"eventType": "block",
									"conditions": [
										{
											"id": "is-button-down",
											"objectClass": "Gamepad",
											"sid": 511120901681060,
											"parameters": {
												"gamepad": "0",
												"button": "d-pad-up"
											}
										}
									],
									"actions": [
										{
											"id": "simulate-control",
											"objectClass": "shipController",
											"sid": 699026983545169,
											"behaviorType": "8Direction",
											"parameters": {
												"control": "up"
											}
										}
									],
									"sid": 193444816750689,
									"children": [
										{
											"eventType": "block",
											"conditions": [
												{
													"id": "is-tag-playing",
													"objectClass": "Audio",
													"sid": 155457736626458,
													"parameters": {
														"tag": "\"engine\""
													},
													"isInverted": true
												}
											],
											"actions": [
												{
													"id": "play-by-name",
													"objectClass": "Audio",
													"sid": 878558254093565,
													"parameters": {
														"folder": "sounds",
														"audio-file-name": "\"engine\"",
														"loop": "looping",
														"volume": "0",
														"tag-optional": "\"engine\""
													}
												}
											],
											"sid": 567937490965103
										}
									]
								},
								{
									"eventType": "block",
									"conditions": [
										{
											"id": "is-button-down",
											"objectClass": "Gamepad",
											"sid": 777571447003577,
											"parameters": {
												"gamepad": "0",
												"button": "d-pad-down"
											}
										}
									],
									"actions": [
										{
											"id": "simulate-control",
											"objectClass": "shipController",
											"sid": 633419295679581,
											"behaviorType": "8Direction",
											"parameters": {
												"control": "down"
											}
										}
									],
									"sid": 605115298274926,
									"children": [
										{
											"eventType": "block",
											"conditions": [
												{
													"id": "is-tag-playing",
													"objectClass": "Audio",
													"sid": 365077046727274,
													"parameters": {
														"tag": "\"engine\""
													},
													"isInverted": true
												}
											],
											"actions": [
												{
													"id": "play-by-name",
													"objectClass": "Audio",
													"sid": 131062620264499,
													"parameters": {
														"folder": "sounds",
														"audio-file-name": "\"engine\"",
														"loop": "looping",
														"volume": "0",
														"tag-optional": "\"engine\""
													}
												}
											],
											"sid": 377662918525117
										}
									]
								},
								{
									"eventType": "block",
									"conditions": [
										{
											"id": "is-button-down",
											"objectClass": "Gamepad",
											"sid": 254694931243345,
											"parameters": {
												"gamepad": "0",
												"button": "d-pad-left"
											}
										}
									],
									"actions": [
										{
											"id": "simulate-control",
											"objectClass": "shipController",
											"sid": 706637950350480,
											"behaviorType": "8Direction",
											"parameters": {
												"control": "left"
											}
										}
									],
									"sid": 205863562220467,
									"children": [
										{
											"eventType": "block",
											"conditions": [
												{
													"id": "is-tag-playing",
													"objectClass": "Audio",
													"sid": 646485999968963,
													"parameters": {
														"tag": "\"engine\""
													},
													"isInverted": true
												}
											],
											"actions": [
												{
													"id": "play-by-name",
													"objectClass": "Audio",
													"sid": 653080968223467,
													"parameters": {
														"folder": "sounds",
														"audio-file-name": "\"engine\"",
														"loop": "looping",
														"volume": "0",
														"tag-optional": "\"engine\""
													}
												}
											],
											"sid": 159410043472827
										}
									]
								},
								{
									"eventType": "block",
									"conditions": [
										{
											"id": "is-button-down",
											"objectClass": "Gamepad",
											"sid": 834314592148974,
											"parameters": {
												"gamepad": "0",
												"button": "d-pad-right"
											}
										}
									],
									"actions": [
										{
											"id": "simulate-control",
											"objectClass": "shipController",
											"sid": 254582302978049,
											"behaviorType": "8Direction",
											"parameters": {
												"control": "right"
											}
										}
									],
									"sid": 353954681525799,
									"children": [
										{
											"eventType": "block",
											"conditions": [
												{
													"id": "is-tag-playing",
													"objectClass": "Audio",
													"sid": 231594472923496,
													"parameters": {
														"tag": "\"engine\""
													},
													"isInverted": true
												}
											],
											"actions": [
												{
													"id": "play-by-name",
													"objectClass": "Audio",
													"sid": 767336725229152,
													"parameters": {
														"folder": "sounds",
														"audio-file-name": "\"engine\"",
														"loop": "looping",
														"volume": "0",
														"tag-optional": "\"engine\""
													}
												}
											],
											"sid": 543030437448133
										}
									]
								}
							]
						},
						{
							"eventType": "block",
							"conditions": [
								{
									"id": "compare-axis",
									"objectClass": "Gamepad",
									"sid": 308588985322324,
									"parameters": {
										"gamepad": "0",
										"axis": "left-analog-x-axis",
										"comparison": 0,
										"value": "0"
									}
								},
								{
									"id": "compare-axis",
									"objectClass": "Gamepad",
									"sid": 294044041606250,
									"parameters": {
										"gamepad": "0",
										"axis": "left-analog-y-axis",
										"comparison": 0,
										"value": "0"
									}
								},
								{
									"id": "is-button-down",
									"objectClass": "Gamepad",
									"sid": 973445308516145,
									"parameters": {
										"gamepad": "0",
										"button": "d-pad-up"
									},
									"isInverted": true
								},
								{
									"id": "is-button-down",
									"objectClass": "Gamepad",
									"sid": 644177403033489,
									"parameters": {
										"gamepad": "0",
										"button": "d-pad-down"
									},
									"isInverted": true
								},
								{
									"id": "is-button-down",
									"objectClass": "Gamepad",
									"sid": 361679422035696,
									"parameters": {
										"gamepad": "0",
										"button": "d-pad-left"
									},
									"isInverted": true
								},
								{
									"id": "is-button-down",
									"objectClass": "Gamepad",
									"sid": 217530228040903,
									"parameters": {
										"gamepad": "0",
										"button": "d-pad-right"
									},
									"isInverted": true
								}
							],
							"actions": [
								{
									"id": "stop",
									"objectClass": "Audio",
									"sid": 127564801593547,
									"parameters": {
										"tag": "\"engine\""
									}
								}
							],
							"sid": 963887297721547
						}
					],
					"sid": 857630001975342
				},
				{
					"eventType": "group",
					"disabled": false,
					"title": "Reactivate repairs",
					"description": "",
					"isActiveOnStart": true,
					"children": [
						{
							"eventType": "block",
							"conditions": [
								{
									"id": "compare-instance-variable",
									"objectClass": "shipController",
									"sid": 709257644695509,
									"parameters": {
										"instance-variable": "dmgPercent",
										"comparison": 5,
										"value": "60"
									}
								},
								{
									"id": "trigger-once-while-true",
									"objectClass": "System",
									"sid": 386181029992414
								}
							],
							"actions": [
								{
									"id": "stop",
									"objectClass": "shipController",
									"sid": 105256302797796,
									"behaviorType": "8Direction"
								},
								{
									"id": "set-enabled",
									"objectClass": "shipController",
									"sid": 348975089227261,
									"behaviorType": "8Direction",
									"parameters": {
										"state": "disabled"
									}
								},
								{
									"id": "set-enabled",
									"objectClass": "ship_col_1",
									"sid": 156278135412382,
									"behaviorType": "Solid",
									"parameters": {
										"state": "enabled"
									}
								},
								{
									"id": "set-enabled",
									"objectClass": "shipController",
									"sid": 439216378224373,
									"behaviorType": "8Direction",
									"parameters": {
										"state": "disabled"
									}
								},
								{
									"id": "set-boolean-instvar",
									"objectClass": "shipController",
									"sid": 895792571311170,
									"parameters": {
										"instance-variable": "isActive",
										"value": "false"
									}
								},
								{
									"id": "set-enabled",
									"objectClass": "player_base",
									"sid": 845869931021626,
									"behaviorType": "Platform",
									"parameters": {
										"state": "enabled"
									}
								},
								{
									"id": "set-collisions-enabled",
									"objectClass": "player_base",
									"sid": 280757489737908,
									"parameters": {
										"collisions": "enabled"
									}
								},
								{
									"id": "set-eventvar-value",
									"objectClass": "System",
									"sid": 250840972557815,
									"parameters": {
										"variable": "zoomLevel",
										"value": "ZOOMED_IN"
									}
								}
							],
							"sid": 520351193283555,
							"children": [
								{
									"eventType": "block",
									"conditions": [
										{
											"id": "repeat",
											"objectClass": "System",
											"sid": 268347134642465,
											"parameters": {
												"count": "floor(random(2, 5))"
											}
										},
										{
											"id": "pick-random-instance",
											"objectClass": "System",
											"sid": 753447232851867,
											"parameters": {
												"object": "repairObj"
											}
										}
									],
									"actions": [
										{
											"id": "set-instvar-value",
											"objectClass": "repairObj",
											"sid": 264937277914295,
											"parameters": {
												"instance-variable": "repairProg",
												"value": "0"
											}
										},
										{
											"id": "set-instvar-value",
											"objectClass": "repairObj",
											"sid": 207195510784036,
											"parameters": {
												"instance-variable": "repairProg",
												"value": "0"
											}
										},
										{
											"id": "set-animation",
											"objectClass": "repairObj",
											"sid": 509638550153932,
											"parameters": {
												"animation": "Self.rndAnim & \"_broken\"",
												"from": "beginning"
											}
										}
									],
									"sid": 167444319168093,
									"children": [
										{
											"eventType": "block",
											"conditions": [
												{
													"id": "compare-instance-variable",
													"objectClass": "repairProgressBar",
													"sid": 461006285884984,
													"parameters": {
														"instance-variable": "id",
														"comparison": 0,
														"value": "repairObj.id"
													}
												}
											],
											"actions": [
												{
													"id": "set-instvar-value",
													"objectClass": "repairProgressBar",
													"sid": 650655151177727,
													"parameters": {
														"instance-variable": "prog",
														"value": "0"
													}
												},
												{
													"id": "set-boolean-instvar",
													"objectClass": "repairProgressBar",
													"sid": 740706641090000,
													"parameters": {
														"instance-variable": "isDone",
														"value": "false"
													}
												}
											],
											"sid": 671193044414949
										}
									]
								},
								{
									"eventType": "comment",
									"text": "Find the ship wheel"
								},
								{
									"eventType": "block",
									"conditions": [
										{
											"id": "for",
											"objectClass": "System",
											"sid": 303870168218996,
											"parameters": {
												"name": "\"tileX\"",
												"start-index": "0",
												"end-index": "200"
											}
										}
									],
									"actions": [],
									"sid": 132922378493945,
									"children": [
										{
											"eventType": "block",
											"conditions": [
												{
													"id": "for",
													"objectClass": "System",
													"sid": 920302850754315,
													"parameters": {
														"name": "\"tileY\"",
														"start-index": "0",
														"end-index": "500"
													}
												}
											],
											"actions": [],
											"sid": 586196029529719,
											"children": [
												{
													"eventType": "block",
													"conditions": [
														{
															"id": "compare-tile-at",
															"objectClass": "ship_BG2_1",
															"sid": 687389519067296,
															"parameters": {
																"tile-x": "loopindex(\"tileX\")",
																"tile-y": "loopindex(\"tileY\")",
																"comparison": 0,
																"tile": "332"
															}
														}
													],
													"actions": [
														{
															"id": "set-collisions-enabled",
															"objectClass": "shipController",
															"sid": 937349820581244,
															"parameters": {
																"collisions": "disabled"
															}
														},
														{
															"id": "set-position",
															"objectClass": "shipController",
															"sid": 366106224121892,
															"parameters": {
																"x": "ship_BG2_1.TileToPositionX(loopindex(\"tileX\"))",
																"y": "ship_BG2_1.TileToPositionY(loopindex(\"tileY\"))"
															}
														},
														{
															"id": "pin-to-object",
															"objectClass": "ship_col_1",
															"sid": 948898565710132,
															"behaviorType": "Pin",
															"parameters": {
																"pin-to": "shipController",
																"mode": "position-only"
															}
														},
														{
															"id": "set-size",
															"objectClass": "shipController",
															"sid": 795360754934912,
															"parameters": {
																"width": "32",
																"height": "32"
															}
														},
														{
															"id": "set-collisions-enabled",
															"objectClass": "shipController",
															"sid": 445843459167141,
															"parameters": {
																"collisions": "enabled"
															}
														},
														{
															"id": "stop-loop",
															"objectClass": "System",
															"sid": 414207459671753
														}
													],
													"sid": 713007051249963
												}
											]
										}
									]
								}
							]
						}
					],
					"sid": 888829196477040
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "is-boolean-instance-variable-set",
							"objectClass": "shipController",
							"sid": 153946691244662,
							"parameters": {
								"instance-variable": "canActivate"
							}
						},
						{
							"id": "trigger-once-while-true",
							"objectClass": "System",
							"sid": 492782793338114
						}
					],
					"actions": [
						{
							"id": "set-visible",
							"objectClass": "wheelHighlight",
							"sid": 682046171764518,
							"parameters": {
								"visibility": "visible"
							}
						}
					],
					"sid": 149399843725729
				}
			],
			"sid": 824279731104129
		},
		{
			"eventType": "group",
			"disabled": false,
			"title": "Player death",
			"description": "",
			"isActiveOnStart": true,
			"children": [
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "compare-instance-variable",
							"objectClass": "player_base",
							"sid": 114134303266372,
							"parameters": {
								"instance-variable": "health",
								"comparison": 3,
								"value": "0"
							}
						},
						{
							"id": "trigger-once-while-true",
							"objectClass": "System",
							"sid": 797532418151154
						}
					],
					"actions": [
						{
							"id": "set-instvar-value",
							"objectClass": "player_base",
							"sid": 494741302615990,
							"parameters": {
								"instance-variable": "health",
								"value": "PLAYER_MAX_HP"
							}
						},
						{
							"callFunction": "DestroyShipAndReset",
							"sid": 873958805247969
						},
						{
							"callFunction": "FadeOut",
							"sid": 185036295489380,
							"parameters": [
								"FADE_TIME"
							]
						},
						{
							"id": "wait",
							"objectClass": "System",
							"sid": 169140199291008,
							"parameters": {
								"seconds": "FADE_TIME"
							}
						},
						{
							"id": "go-to-layout",
							"objectClass": "System",
							"sid": 383308985926220,
							"parameters": {
								"layout": "lay_gameover"
							}
						}
					],
					"sid": 967036427426341
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "compare-instance-variable",
							"objectClass": "shipController",
							"sid": 957876845232989,
							"parameters": {
								"instance-variable": "dmgPercent",
								"comparison": 5,
								"value": "100"
							}
						},
						{
							"id": "trigger-once-while-true",
							"objectClass": "System",
							"sid": 123519783189742
						}
					],
					"actions": [
						{
							"callFunction": "DestroyShipAndReset",
							"sid": 643578571803979
						},
						{
							"callFunction": "FadeOut",
							"sid": 950538464737540,
							"parameters": [
								"FADE_TIME"
							]
						},
						{
							"id": "wait",
							"objectClass": "System",
							"sid": 303335234475107,
							"parameters": {
								"seconds": "FADE_TIME"
							}
						},
						{
							"id": "go-to-layout",
							"objectClass": "System",
							"sid": 255992243617008,
							"parameters": {
								"layout": "lay_gameover"
							}
						}
					],
					"sid": 767398082196446
				}
			],
			"sid": 909935578718493
		},
		{
			"eventType": "group",
			"disabled": false,
			"title": "Repair ship part",
			"description": "",
			"isActiveOnStart": true,
			"children": [
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "is-button-down",
							"objectClass": "Gamepad",
							"sid": 666609831607436,
							"parameters": {
								"gamepad": "0",
								"button": "button-b"
							}
						},
						{
							"id": "is-overlapping-another-object",
							"objectClass": "player_base",
							"sid": 385319546638632,
							"parameters": {
								"object": "repairObj"
							}
						}
					],
					"actions": [
						{
							"id": "add-to-instvar",
							"objectClass": "repairObj",
							"sid": 824782327004497,
							"parameters": {
								"instance-variable": "repairProg",
								"value": "repairSpeed * dt"
							}
						},
						{
							"id": "set-instvar-value",
							"objectClass": "repairObj",
							"sid": 803904217689194,
							"parameters": {
								"instance-variable": "repairProg",
								"value": "clamp(Self.repairProg, 0, 100)"
							}
						},
						{
							"id": "set-boolean-instvar",
							"objectClass": "player_base",
							"sid": 314922230568970,
							"parameters": {
								"instance-variable": "isRepairing",
								"value": "true"
							}
						}
					],
					"sid": 781050142099252,
					"children": [
						{
							"eventType": "block",
							"conditions": [
								{
									"id": "compare-instance-variable",
									"objectClass": "repairProgressBar",
									"sid": 242175288006758,
									"parameters": {
										"instance-variable": "id",
										"comparison": 0,
										"value": "repairObj.id"
									}
								}
							],
							"actions": [
								{
									"id": "set-instvar-value",
									"objectClass": "repairProgressBar",
									"sid": 900657327679875,
									"parameters": {
										"instance-variable": "prog",
										"value": "repairObj.repairProg"
									}
								},
								{
									"id": "set-visible",
									"objectClass": "repairProgressBar",
									"sid": 511247738023540,
									"parameters": {
										"visibility": "visible"
									}
								},
								{
									"id": "set-visible",
									"objectClass": "repairProgressBarBG",
									"sid": 821955998137648,
									"parameters": {
										"visibility": "visible"
									}
								}
							],
							"sid": 642946770569167
						}
					]
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "on-button-released",
							"objectClass": "Gamepad",
							"sid": 203447463668037,
							"parameters": {
								"gamepad": "0",
								"button": "button-b"
							}
						}
					],
					"actions": [
						{
							"id": "set-boolean-instvar",
							"objectClass": "player_base",
							"sid": 629397765620329,
							"parameters": {
								"instance-variable": "isRepairing",
								"value": "false"
							}
						},
						{
							"id": "set-visible",
							"objectClass": "repairProgressBar",
							"sid": 352444844158151,
							"parameters": {
								"visibility": "invisible"
							}
						},
						{
							"id": "set-visible",
							"objectClass": "repairProgressBarBG",
							"sid": 117878873207969,
							"parameters": {
								"visibility": "invisible"
							}
						}
					],
					"sid": 499619049196084
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "compare-instance-variable",
							"objectClass": "repairProgressBar",
							"sid": 259020692372488,
							"parameters": {
								"instance-variable": "prog",
								"comparison": 5,
								"value": "100"
							}
						},
						{
							"id": "is-boolean-instance-variable-set",
							"objectClass": "repairProgressBar",
							"sid": 322709004809130,
							"parameters": {
								"instance-variable": "isDone"
							},
							"isInverted": true
						}
					],
					"actions": [
						{
							"id": "set-boolean-instvar",
							"objectClass": "repairProgressBar",
							"sid": 760827722689614,
							"parameters": {
								"instance-variable": "isDone",
								"value": "true"
							}
						},
						{
							"id": "set-effect-enabled",
							"objectClass": "repairProgressBar",
							"sid": 147039082877260,
							"parameters": {
								"mode": "enable",
								"effect": "\"BlackWhite\""
							}
						},
						{
							"id": "start-timer",
							"objectClass": "SysObj",
							"sid": 842707517663672,
							"behaviorType": "Timer",
							"parameters": {
								"duration": "0.2",
								"type": "once",
								"tag": "\"progEffect\""
							}
						},
						{
							"id": "play-by-name",
							"objectClass": "Audio",
							"sid": 282240722810772,
							"parameters": {
								"folder": "sounds",
								"audio-file-name": "\"fixed\"",
								"loop": "not-looping",
								"volume": "-20",
								"tag-optional": "\"fixed\""
							}
						}
					],
					"sid": 196537849662222,
					"children": [
						{
							"eventType": "block",
							"conditions": [
								{
									"id": "compare-instance-variable",
									"objectClass": "repairObj",
									"sid": 811692859628526,
									"parameters": {
										"instance-variable": "id",
										"comparison": 0,
										"value": "repairProgressBar.id"
									}
								}
							],
							"actions": [
								{
									"id": "set-animation",
									"objectClass": "repairObj",
									"sid": 365902985210669,
									"parameters": {
										"animation": "Self.rndAnim & \"_fixed\"",
										"from": "beginning"
									}
								}
							],
							"sid": 652441339337687
						}
					]
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "on-timer",
							"objectClass": "SysObj",
							"sid": 738533147551511,
							"behaviorType": "Timer",
							"parameters": {
								"tag": "\"progEffect\""
							}
						}
					],
					"actions": [
						{
							"id": "set-effect-enabled",
							"objectClass": "repairProgressBar",
							"sid": 733006892981881,
							"parameters": {
								"mode": "disable",
								"effect": "\"BlackWhite\""
							}
						}
					],
					"sid": 653151215675474
				}
			],
			"sid": 770917563332131
		},
		{
			"eventType": "group",
			"disabled": false,
			"title": "Check if can activate wheel",
			"description": "",
			"isActiveOnStart": true,
			"children": [
				{
					"eventType": "variable",
					"name": "foundBroken",
					"type": "boolean",
					"initialValue": "false",
					"comment": "",
					"isStatic": false,
					"isConstant": false,
					"sid": 157871356186092
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "for-each",
							"objectClass": "System",
							"sid": 842176760314214,
							"parameters": {
								"object": "repairObj"
							}
						}
					],
					"actions": [],
					"sid": 964773402295646,
					"children": [
						{
							"eventType": "block",
							"conditions": [
								{
									"id": "compare-instance-variable",
									"objectClass": "repairObj",
									"sid": 822865025686757,
									"parameters": {
										"instance-variable": "repairProg",
										"comparison": 2,
										"value": "100"
									}
								}
							],
							"actions": [
								{
									"id": "set-boolean-eventvar",
									"objectClass": "System",
									"sid": 686434132510811,
									"parameters": {
										"variable": "foundBroken",
										"value": "true"
									}
								}
							],
							"sid": 583149446203700
						}
					]
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "compare-boolean-eventvar",
							"objectClass": "System",
							"sid": 844738136124876,
							"parameters": {
								"variable": "foundBroken"
							}
						}
					],
					"actions": [
						{
							"id": "set-boolean-instvar",
							"objectClass": "shipController",
							"sid": 296659821712504,
							"parameters": {
								"instance-variable": "canActivate",
								"value": "false"
							}
						}
					],
					"sid": 801497335516171
				},
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "else",
							"objectClass": "System",
							"sid": 873041043432774
						}
					],
					"actions": [
						{
							"id": "set-boolean-instvar",
							"objectClass": "shipController",
							"sid": 646816177146698,
							"parameters": {
								"instance-variable": "canActivate",
								"value": "true"
							}
						}
					],
					"sid": 590746664102585
				}
			],
			"sid": 450137823106553
		},
		{
			"eventType": "group",
			"disabled": false,
			"title": "Activate the ship",
			"description": "",
			"isActiveOnStart": true,
			"children": [
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "on-button-released",
							"objectClass": "Gamepad",
							"sid": 521088560703492,
							"parameters": {
								"gamepad": "0",
								"button": "button-b"
							}
						},
						{
							"id": "is-overlapping-another-object",
							"objectClass": "player_base",
							"sid": 732413204277668,
							"parameters": {
								"object": "shipController"
							}
						},
						{
							"id": "is-boolean-instance-variable-set",
							"objectClass": "shipController",
							"sid": 595481833166248,
							"parameters": {
								"instance-variable": "canActivate"
							}
						}
					],
					"actions": [
						{
							"id": "set-boolean-instvar",
							"objectClass": "shipController",
							"sid": 901199924631741,
							"parameters": {
								"instance-variable": "isActive",
								"value": "true"
							}
						}
					],
					"sid": 438107431753572
				}
			],
			"sid": 248718649681996
		},
		{
			"eventType": "group",
			"disabled": false,
			"title": "Progress bar",
			"description": "",
			"isActiveOnStart": true,
			"children": [
				{
					"eventType": "block",
					"conditions": [
						{
							"id": "for-each",
							"objectClass": "System",
							"sid": 136009953276517,
							"parameters": {
								"object": "repairProgressBar"
							}
						}
					],
					"actions": [
						{
							"id": "set-width",
							"objectClass": "repairProgressBar",
							"sid": 135536607087771,
							"parameters": {
								"width": "Self.originalWidth * (Self.prog / 100)"
							}
						},
						{
							"id": "set-instvar-value",
							"objectClass": "repairProgressBar",
							"sid": 784878320940653,
							"parameters": {
								"instance-variable": "prog",
								"value": "clamp(Self.prog, 0, 100)"
							}
						}
					],
					"sid": 314704623939655
				}
			],
			"sid": 293951223222752
		},
		{
			"eventType": "block",
			"conditions": [
				{
					"id": "on-flash-ended",
					"objectClass": "repairHighlight",
					"sid": 314828750210742,
					"behaviorType": "Flash"
				}
			],
			"actions": [
				{
					"id": "flash",
					"objectClass": "repairHighlight",
					"sid": 749122832104868,
					"behaviorType": "Flash",
					"parameters": {
						"on-time": "random(0.2, 0.4)",
						"off-time": "random(0.2, 0.4)",
						"duration": "2"
					}
				}
			],
			"sid": 437881766355391
		}
	],
	"sid": 263282355959929
}