G General

Simple Tile Swapping Game Version 1

Simple Tile Swapping Game
Details
Features
Contents
Reviews

Learn about scripting games in second life with this basic light flipping game.

1. To win you have to make all squares green.
2. When you start the game four random squares will become green.
3. When you touch a square, the square you touched and its neighbors will change color.
4. When you touch the board the game will reset.
5. When you win a short message will display and particle effects will occur.

Please feel free to modify or share this code with someone. If you want to sell your modification please add me as a co-creator.

Code features:
- Multi-prim object
- Parallel arrays
- 2D arrays stored as 1D arrays
- Parsing metadata from object names
- Updating linked objects
- State and timers
- Multiple buttons and events
- Basic particle effects

The script is stored inside the large blue prim.

Ideas for features you could write yourself:
- A scoreboard
- Chat integration
- Sound
- Textures and more details buttons
- A reset button
- Make the particles look like confetti

  • Random board on start
  • Particle effects on win
  • Fully modifiable
  • Efficient scripting