Build a GameCreating Shatterfield

Appendix E — Troubleshooting

Every chapter’s If it didn’t work names the slips most likely in that chapter, and how to find each one. Here they are together, chapter by chapter.

Two checks find most of them. First, names must match exactly: a message, a timer or a table row is matched letter for letter, capitals included. Second, compare with the chapter’s game. Every chapter’s Goal holds the game as it is at the end of that chapter, and its catch-up download is that chapter’s finished project. Play it next to yours.

E.1 Chapter 1: The Ship Flies

No Ship at all? Look in Space for its placement, at X 16 and Y 12. Then look at Start Scene in the Game Settings. It should say Space · 2D.

The keys do nothing? Open the Ship and switch the list to Logic, where Rotate-and-thrust Controls should be in the Attached Logic. Then open the Input Manager. Its Command needs all eight keys from your setup card, each in its place.

The Ship turns slowly and feels heavy, or never slows down? Perhaps the four values never reached the Ship’s Variables. A Ship that flies with the Logic Component’s starting numbers turns at 260 and never passes 6.875. Its coastDrag starts at 0, so it never slows down either. Type the Ship card’s values into their Value boxes, in Components. It wakes up.

The Ship stops dead at the edge, as if it hit a wall? Open the Physics section of the Ship’s Transform, where Stay inside the scene should be off, as it starts. Turn it off, and the wall is gone.

The Ship flies off and never comes back? Then Wrap Around World is missing from the Ship’s Attached Logic, and attaching it brings the Ship home.

The flame shows when you hold Left? The first Event’s Direction is still on Left, where every new one starts. Open its Command section and click Up.

Switch Mode’s Event list has no Event with Up Is Held in its name? That Event’s Direction is still Left, and its name says so. Click Up in its Command section, and the name follows.

No flame and no hum? Follow each line on Thrust Feedback’s canvas: Coasting’s should hold three Actions, and Thrusting’s none. The Released Event’s Mode 1 holds the other three. An Action on the wrong line went in from another line’s right-click. Right-click it, choose Delete, and add it again from the right line. One at a time, in the card’s order.

Still no flame and no hum? Look on Thrust Feedback’s canvas for a block standing apart, with no arrow into it. That block does nothing yet. Right-click it, and Connect to sequence puts it to work.

The flame shows, but it never flickers? Coasting is starting it over on every step, because nothing turns the sign. Its last Action, Switch Mode, should pick Thrusting.

No flame, but the hum plays? Perhaps the Clip list still holds another clip, when Set Animation Clip’s should be Ship Sprite/Thrust.

The flame shows, but you never hear the hum? Look at Control Sound. Its Operation should be Loop, and its Sound should be Thrust.

The flame stays after you let go, or the hum never stops? Check the second Event against its card. Its When bar is 2D Direction Released, with Up as its Direction, and its Control Sound has the Operation Stop.

The flame comes once, and never again? The Released Event’s Switch Mode should turn the sign back to Coasting.

E.2 Chapter 2: Shots

Space does nothing at all? Perhaps the Command isn’t there. Open the Input Manager and look for Fire, a Button, with Space bound to it. If it’s there, open the Ship and switch to Logic, where Ship Gun should be in the Attached Logic. In Components, the Value of shot should read Shot.

Still nothing? Look on Ship Gun’s canvas for a block standing apart, with no arrow into it. That block does nothing yet. Right-click it, and Connect to sequence puts it to work.

The Fire sound plays, but no dart appears? Then the If let the gun fire, and Create Instance is the step to look at. Is it standing apart from the True line? Join it with Connect to sequence, and look at its Object to Create, which should be @self.shot. And on the Ship, the Value of shot should read Shot, not None.

The If has a red edge? A name in its box isn’t one Ship Gun knows. Check the spelling against the card, letter by letter, with .value after both answers.

Check Instance Count’s list has no @self.shot? Then shot’s Type isn’t Object. On the Shared Variables card, the bin beside shot deletes it, and you add it again, with Object picked in its Type list.

After four Shots, the gun goes quiet for good? The Shots aren’t ending. They’re still out there, wrapping round and round. Open Shot Lifetime. The second Event should name the timer shotLife. That’s the Timer Name in the first Event’s Action, spelled the same, because a timer and its Event find each other by that name. If they differ, type the Timer Name again to match. Under that Event, Destroy Instance should sit joined to the line.

Shots never end, though the names match? Perhaps Destroy Instance went onto the first Event’s line, from the wrong Mode 1. Each Event has its own. Right-click the stray block, choose Delete, and add it again from the second Event’s Mode 1.

With fireCooldownSeconds at 1, the gun still fires on every tap? Look at the two cooldown Actions in Ship Gun, Check Cooldown Ready and Start Cooldown. Both need the Cooldown Key fireCooldown, spelled the same. And Start Cooldown’s Applies To should be Self, not newShot, the Shot it made a moment before.

Shots come out of the Ship’s side, or its tail? Look at Create Instance. Position Relative To is Self, and Angle Relative To is Creator, with a Launch Angle of 90. And muzzleDistance belongs in Y, not X.

Shots fly the right way but point backward? The facingOffset may be 90, without the minus, and that puts each dart half a turn off. Make it -90, and they turn around.

E.3 Chapter 3: Hyperspace

Shift does nothing at all? Perhaps the Command isn’t there. Open the Input Manager and look for Hyperspace, a Button, with Shift in its key row. If it’s there, look in the Ship’s Attached Logic for Ship Hyperspace.

Space fires and jumps, and Shift does nothing? The Event still listens for Fire, the Command its window picked first. On Ship Hyperspace’s canvas, the Event’s block has a Command line, folded at first. Click it open, and change the Command to Hyperspace.

Still nothing? Look on Ship Hyperspace’s canvas for a block standing apart, with no arrow into it. Right-click it, and Connect to sequence puts it to work. If the If has a red edge, a name in its box isn’t one Ship Hyperspace knows. Check it against the card, letter by letter.

Sparks and a sound, but the Ship stays where it was? The message isn’t reaching Random Teleport. Is Random Teleport attached to the Ship? Is the Custom Event in Ship Hyperspace spelled randomTeleport, with a capital T and nothing else?

A sound, but no sparks? Each Burst Particles needs Impact Sparks picked in its Particles list, and @self.sparkCount in its Count.

The Ship never lands near the right edge, or along the bottom? Random Teleport is still using its own box. Look at the Ship’s Variables. maximumX and maximumY should each be Kind Expression, holding $areaWidth and $areaHeight, with the dollar signs. And minimumY should be 0.

The Ship always lands right on the left edge, or right on the bottom? Perhaps a Global Variable is still at 0. Open Ship Gun, where you made them, and look at its Globals card. The pencil beside $areaWidth opens it again, with its Default, which should be 32. For $areaHeight, it’s 24.

The Ship jumps, but keeps drifting the way it was going? Look at Set Velocity. Its X Velocity and Y Velocity both need a 0, because a blank box keeps the old speed.

Both bursts of sparks show up at the new place? The first Burst Particles has ended up below Trigger Custom Event on Object. It belongs above it, before the jump. The round handles move a joined block, as the passage on Actions shows.

Shift jumps every time, with no wait at all? Look at the two cooldown blocks. Both need the Cooldown Key hyperspaceCooldown, spelled the same, in place of the cooldown they arrived with.

E.4 Chapter 4: Asteroids

The rocks sit still? Perhaps Asteroid Drift isn’t attached. Open each size, switch the list to Logic, and look for it first in the Attached Logic. Still not moving? Look on Asteroid Drift’s canvas for a block standing apart from the line, with no arrow into it. Right-click it and choose Connect to sequence.

Every rock wears the same face? Look at Set Frame in Asteroid Drift, where the Frame should read poseNumber.value * 4.

The rocks drift, but never spin? Allow Rotation is off, in the Transform’s Physics section. If the switch was missed on Asteroid Large, the copies missed it too. Turn it on in each size.

The rocks drift off the edges and never come back? Look for Wrap Around World in each size’s Attached Logic, third, below Break Apart.

Two rocks that meet push each other aside, instead of sliding through? Their Collision is still Solid. Pick Sensor, the middle of the three buttons, on each size.

Your Shots fly straight through the rocks? The Shot’s Collide Only With list needs Tagged Asteroid on it. If it’s there, look at the rocks: each size needs its Tags, with Asteroid listed. Then look for Shot Impact in the Shot’s Attached Logic, and check that its Collision Target says Tagged Asteroid.

A Shot touches a rock and vanishes, and nothing breaks? Perhaps Trigger Custom Event on Object still has Self in its Applies To, so hit goes to the Shot. Pick Other.

Shoot one rock, and every rock breaks? Shot Impact may be using Trigger Custom Event, which tells every rock at once. It needs Trigger Custom Event on Object. Its Applies To should be Other.

The fragments always start out at a corner of the screen, not where the rock was? Create Instance’s Position Relative To is still World. Pick Self.

A rock breaks, but nothing comes out of it, or only one rock? Look at the size’s fragment Value first, which should name the next size down, not None. Then look at Break Apart’s Repeat. If it, or its Create Instance, stands apart with no arrow into it, join it with Connect to sequence. And its Count should read @self.fragments, not the 1 it started with.

The Repeat hangs under Camera Shake, on the If’s True line, not below the If? Right-click the Repeat on its name and choose Delete. Then add it again from Mode 1’s right-click, and its Create Instance with Add inside Repeat.

A rock sprays its sparks and stays put? Look for Destroy Instance at the end of Break Apart’s line, joined. A Shot that flies on after a hit needs the same, at the end of Shot Impact.

A Large rock breaks into more Large rocks? Asteroid Large’s fragment should be Asteroid Medium. Each size breaks into the next size down, and only Asteroid Small names itself.

A rock breaks without a sound? Open that size and look at its breakSound Value, under Variables. It should name the sound on its card, where None means silence. And in Break Apart, Control Sound’s list should read @self.breakSound, the Shared Variable, not a sound of its own.

E.5 Chapter 5: Crash and Lives

The Ship flies through rocks and never crashes? Perhaps Ship Crash isn’t attached, or its sign is stuck on Shielded. Look in Ship Shield’s shieldTime Event for the Trigger Custom Event on Object that sends shieldDown. If it’s there, check that Ship Crash’s shieldDown Event turns the sign to Exposed. One more place to look is the Ship’s Collider. Its Collide Only With list needs Tagged Asteroid, as Chapter 4 left it.

Still no crash? Follow the lines on Ship Crash’s canvas. Exposed’s line should hold all eight Actions, and Shielded’s none. An Action on the wrong line went in from the other Mode’s right-click. Right-click it, choose Delete, and add it again from Exposed’s line, in the card’s order.

The Ship crashes while it’s still blinking? Ship Crash’s shieldUp Event should turn the sign to Shielded, and Shielded should have no Actions at all.

The Errors bar counts an error in Ship Shield? Look at the If’s box and at both Change Component Values. Each path should read self.shipShieldData.isFaded, spelled as the card spells it. If the spelling is right, check that Ship Shield Data is on Ship Shield’s Data Structures card.

No new Ship ever comes, and no icons show? Game Rules may not be in the Scene, and its Logic only runs there. Look for it in the Scene Explorer of Space, under Objects.

The icons work, but no new Ship ever comes? Open Game Rules, and look under Variables. ship’s Value should read Ship, not None. If it does, perhaps the timer rings for nobody. The Timer Name in Start Recurring Timer and the name on the Recurring Timer’s block must be the same word, respawnDelay. And Ring Once should be Yes, so the timer rings once for each crash.

The Thrust hum goes on after a crash? Look at Thrust Feedback’s Destroy Event. Its Control Sound should be joined, with Stop in its Operation list.

The new Ship never blinks, though rocks still pass through it for 3 seconds? Look at the shieldBlink Event. The Set Alpha on its False line should have @self.fadedAlpha as its Alpha. Left at 1, both answers make the Ship solid. If it’s right, check the timer’s name: the first Start Recurring Timer and the shieldBlink Event’s block must both say shieldBlink.

The Ship stays faint after the blinking stops? Look at the Set Alpha in the shieldTime Event, its step 2. Its Alpha should be 1.

The icons wear the Ship’s picture? The Add Sprite Component window kept its first picture. Select Sprite in each icon’s Attached Components, and pick Life Icon Sprite in its Sprite list.

The icons never change? Look at Life Icon’s second Event. Its When bar should be Variable Changed, with lives as its Global Variable. Then check Show Life Icon. Both its Set Visibles should apply to icon, and the one on the True line should be Yes.

E.6 Chapter 6: Waves

A piece that does nothing at all? Look on its canvas for a block with no arrow into it, and join it with Connect to sequence.

The banner never shows, and no rocks come? Perhaps Waves isn’t attached to Game Rules, or Game Rules isn’t in Space. If both are fine, look at the Game Start Event. Its Trigger Custom Event should send nextWave, spelled the same as the Event that listens.

WAVE 1 shows and stays? The Event that listens for the timer needs the timer’s own name, bannerTime.

The banner goes out, and no rocks come? Look at the call to Create Asteroids Along Edges, in Waves’ bannerTime Event. Its creator list should say self. Its asteroid list should hold @self.asteroid. Under Game Rules’ Variables, the Value of asteroid should read Asteroid Large, not None. If those are right, open the Function. Each Create Instance’s Applies To should be creator, not Self.

Rocks keep pouring in, a fresh handful every second and a half, and the banner never comes back? The bannerTime timer’s Ring Once is No, so pick Yes. If the banner flashes WAVE 2, WAVE 3, WAVE 4 instead, a new number every second and a half, it’s the sectorJump timer’s Ring Once.

Every wave has only two rocks? The call’s perBand box still holds the Function’s own 1. Type perBandThisWave there.

The banner reads WAVE with no number, or WAVE 0? Check the Text you typed, WAVE {$wave}, braces and all. If it reads WAVE {value}, that’s Myth’s way of showing it, and it’s fine. Then check nextWave’s Change Variable: $wave in its Variable box, += after it, and 1 in its Value.

The banner sits in a corner, or never shows? Look at its placement’s Screen Anchor. The middle dot should be lit, with 0 and 80 in Screen Offset (px).

The first wave has eight rocks? The four from Chapter 4 are still placed, so remove them from Space.

The field empties and no new wave comes? Open the No Instances Left block’s Object section, where Collision Target should say Tagged Asteroid. If it does, check that the sectorJump timer and the Event that listens for it share one name.

A new wave arrives while Mediums are still drifting? No Instances Left may be set to Asteroid Large, which is gone sooner. Pick Tagged Asteroid. Every size wears that Tag, so it waits for the last rock of all.

The rocks never speed up, though both wave boxes say $wave? Look at Asteroid Drift’s order. Set Speed must be the last step. If it sits above the new ones, move it down with the handles.

The material never changes, or the rocks never speed up? Perhaps a size’s wave is still Constant, at 1. On each size, wave needs Expression in its Kind list, and $wave in the box that takes the Value’s place.

Every wave is Standard, though the rocks speed up? Look at the Sprite of Asteroid Material’s Set Sprite, out at the end of the line. It should hold the card’s formula, not a picture’s name. If Myth turned the formula red, perhaps Set Sprite was still loose when you typed it. Join it to the line, and type the formula again.

Every rock in a wave shows the same pose? Asteroid Material has slipped below Asteroid Drift in that size’s Attached Logic, so move it back to the top.

E.7 Chapter 7: Score

The score stays at 0, and no number rises off a broken rock? Break Apart’s three new steps may have joined at the bottom, after Destroy Instance, where nothing runs. Make the handle moves from Break Apart’s part again. The handles move a block from wherever it sits, so they bring all three back to the top.

A number rises, but the score stays at 0? Break Apart’s Change Variable needs $score in its Variable box, dollar sign and all.

The score jumps about instead of climbing? Then that Change Variable needs += on its block, before @self.points. With =, the score only ever shows the last rock’s points.

The score climbs, but no number rises? Popup Text may still have no arrow into it, waiting to be joined after Trigger Custom Event with the handles.

The top left shows the word score, or nothing at all, where the number should be? Check the Text in Score Display: {$score}, braces, dollar sign and all. If it reads {value} when you open it again, that’s how Myth shows it once typed, as with the Wave Banner, and it’s fine.

The score works, but HI stays at 0? Perhaps Score was never attached to Game Rules, or it went onto another Object by mistake. If it’s on Game Rules, perhaps nothing reaches its scored Event. Break Apart’s Trigger Custom Event has to send scored, spelled the same way. And Score’s If compares $score with $highScore.

The score starts far in from the left edge, or the wave number stops short of the right one? Check Text Bounds on Score Display and Wave Display. Each should be Wrap to Width, with the card’s number in W.

The numbers sit in the wrong corners? Check each Screen Anchor on the three cards, one at a time. Score Display has none, so it stays at Top Left. If a number is off the screen, its X or Y in PLACE THESE may have lost its minus sign.

An extra Ship comes with the very first rock you break? The finish line was never painted, so it started at 0 and the first rock crossed it. Look in Extra Ships’ Game Start Event.

Extra Ships come with every rock once you pass the first line? The line isn’t moving on. Check the Change Component Value inside the If. Its path is self.extraShipsData.nextExtraShipAt, with Plus in its Operator list and @self.extraShipEvery as its Value.

No extra Ship ever comes, even at 100? First make sure Extra Ships is attached to Game Rules at all, and that its second Event waits for scored. If it does, check the If’s comparison, >=, and make sure the score in it is $score, with its dollar sign.

A rock shows words instead of its points, such as text(@self.points)? Its Popup Text needs the braces form, {sharedVar("self","points")}, typed whole.

E.8 Chapter 8: Saucers

Rocks you shoot don’t break anymore? Perhaps the hit Event lost the Action at its end. Look below Popup Text for a Trigger Custom Event on Object, sending breakUp, with its Applies To on Self. Then look in On Break Up. Its first block, Burst Particles, needs an arrow into it from Mode 1.

The pasted blocks won’t join On Break Up’s line? Perhaps they landed in the hit Event, because the spot you right-clicked was nearer to it. Undo the paste, and paste again from a spot right beside On Break Up’s Mode 1.

No saucer ever comes? Is Saucer Spawner attached to Game Rules, with Saucer Large and Saucer Small picked under Variables? Its timer’s name needs to be saucerCheck in both places it appears.

Two saucers at once? Look at Check Instance Count. Its Object should read tag:Saucer, so it counts both kinds.

The saucer stops crossing when it weaves? Its nextWeave Event’s Set Velocity has something in the X Velocity box. Empty it.

The saucer flies dead level all the way? Perhaps nextWeave never starts again. The last Action of its own Event restarts it, by the same name.

The siren wails on after the saucer is gone? Saucer Flight needs its When Destroyed Event, with Control Sound on Stop, to end Saucer Siren when it goes.

An Orb breaks a rock, and the score goes up? Saucer Shot Flight is sending the rock hit, when it should send breakUp.

Your Shots still pass through the saucer? Check both sides. The Shot’s Collide Only With list needs Tagged Saucer, the saucer’s needs Shot, and Shot Impact’s Collision Target needs Any Object.

Your Events kept older names, like When Starting to Hit Asteroid? That happens if you started from Chapter 7’s download, and it’s fine. A name is only a label. What counts is the Any Object in each Collision Target, so look there.

An Orb shoves your blinking Ship along? Look at On Shield Up’s Change Component Value. It needs self.collider.trigger and true, with an arrow into it from Switch Mode.

The Lances fly off at random? Look at Saucer Lance’s Variables, and set aimed to Yes.

E.9 Chapter 9: Screens

The game starts playing behind the title? Look at Game Rules’ Attached Logic. Five switches need to be off: Lives and Respawn, Waves, Extra Ships, Saucer Spawner and Pause.

Enter does nothing on the title? Perhaps Menus still reads Inactive at Start in the Input Manager, so click it. Or look at the Start Command itself, in Menus. Its two rows should read Enter and Space.

P pauses, but Esc doesn’t? The Pause Command’s first row may still read No Input Assigned. Click it and press Escape twice, quickly.

No Ship after Enter? Lives and Respawn’s On Enable needs the Trigger Custom Event on Object, sending spawnShip. And check that the Value of ship, under Game Rules’ Variables, still says Ship.

WAVE 2 comes straight after WAVE 1? Perhaps Start Game sets Playing before clearField. Set Game State has to be last, so move it below Trigger Custom Event with the handles.

PRESS ENTER TO PLAY AGAIN shows the moment GAME OVER does? Play Again Prompt may have a Group, typed in by habit. Empty its Group box.

PAUSED never closes? Look at Paused’s UI Interaction: Confirm Command Start, Cancel Command Pause, and gameResumed in both Event and Cancel Event. And Pause’s gameResumed Event should send hideMenu.

The engine hums on under PAUSED? Thrust Feedback’s gamePaused Event needs its Control Sound on Stop, with Thrust.

Esc pauses on the title? Pause needs its switch off on Game Rules, and its two lines in Play Switch.

GAME OVER never comes? Lives and Respawn’s If needs its Else, with Set Game State on Game Over. Its list starts on Title, so check it.

Every rock scores twice? The scoring steps may have been copied, not cut, so the old three still sit below the If in Break Apart. Delete those three.

No points rise off a broken rock at all? Perhaps the three scoring steps landed beside the If, with no arrow into them. Cut them again, and paste them on a block inside the If, as above.

The title’s rocks wear a later wave’s material? Title Asteroid’s wave row may still read Expression in its Kind list. Pick Constant, and it reads 1.

The high score is gone the next time? Score’s Save Persistent Value and Load Persistent Value need the same Key, "highScore".

E.10 Chapter 10: Heartbeat

No beat at all? Heartbeat only beats while a wave’s rocks are out, so start a game first. Then look in Heartbeat for a block with no arrow into it, inside the Ifs too. Then look at Waves. Its two new Trigger Custom Events need arrows into them as well. Check their spelling too: waveStarted and waveCleared. Play Switch’s True line needs the Set Logic State that names Heartbeat, too.

One note, then silence? The heartbeat timer’s Event has to start the timer again. Look for Start Recurring Timer at the very bottom of its line, joined, with heartbeat as its Timer Name and Ring Once on Yes.

The same note every time? Each side of the first If gives nextNote the other number: 2 on its True line, and 1 on its Else line.

A steady beat, a little under a second, that never quickens? The Change Component Value below the first If needs *= in its Operator list. With =, every gap is speedUp itself, 0.97 seconds.

The beat jumps to its fastest at once, or races on into a buzz? Look at the second If, the one below that Change Component Value. Its box should read self.heartbeatData.beatSeconds < @self.fastestSeconds.

The beat keeps going after the last rock? Perhaps Waves’ No Instances Left is missing its new Trigger Custom Event, the one sending waveCleared. Or perhaps Heartbeat’s waveCleared Event has no Stop Recurring Timer, with heartbeat in its Timer Name.

The beat goes on under GAME OVER? Play Switch’s Else line needs the Set Logic State that names Heartbeat, with Disable in its State list.

E.11 Chapter 11: Sky

The sky is still black? Look at Space’s Screen Backgrounds, under the Scene’s Properties. All six names should be there, Nebula Panorama at the top.

The sky shows, but only one layer, or the dust is behind the nebula? The order in Screen Backgrounds is back to front. Drag each row by its grip until the list matches the card.

Everything shows, but nothing moves? Perhaps Sky Parallax isn’t on Game Rules, or its switch is off. Then look at the End Step Event. Set Background Sliding Speed must sit inside the Repeat, joined, with an arrow into it.

Only the nebula moves, and the others hang still? The Repeat’s Count should read dataCount("Sky Layers"), spelled like the table. And the first Change Component Value inside it needs local.index, so row changes on each turn.

The sky doesn’t follow the Ship? The three Change Component Values at the bottom of Every Step need Plus in their Operator lists, the card’s +=. With =, the sky takes one small slice and forgets the rest.

A layer drifts the wrong way, or races? Look at its row in Sky Layers, where each number should match the card’s, minus signs and all.

The sky never surges? Waves’ No Instances Left needs the Trigger Custom Event that sends waveCleared, from Chapter 10, and Sky Parallax’s waveCleared Event needs jumpTarget set to 1.

The surge never stops? The nextWave and playStopped Events each set jumpTarget back to 0.