PcoWSkbVqDnWTu_dm2ix
We use cookies on this site to enhance your user experience

Change the Points Given

Change the Points Given

Besides just the map, other aspects of Create and Destroy can be customized. Would you like players to earn hundreds of points every time they knock down a building or a tree? Make that happen by changing numbers in a script, an object that holds code.

Open the Script

  1. At the top of the Explorer, a list of everything included in a game, on the right-hand side, type GameSettings.

If you closed the Explorer, or don’t see it, you can enable it by going to the View tab and clicking Explorer.


  1. Double-click GameSettings to open the script editor.

The GameSettings Script

In the script, you’ll see a section with the three different point values given to players for large buildings (HighPoints), medium buildings (MediumPoints), and for props (LowPoints).

-- Game Variables
GameSettings.intermissionDuration = 10
GameSettings.roundDuration = 30
GameSettings.minimumPlayers = 1
GameSettings.transitionStart = 3
GameSettings.transitionEnd = 3
GameSettings.pointValues = {
	 -- Value types must match folder names to award points correctly
	LowPoints = 0,
	MediumPoints = 10,
	HighPoints = 15,
}

Change the Points Value

Giving players more points can make smashing buildings feel even more rewarding.

  1. Make the large buildings worth 150 points by changing HighPoints = 15, to HighPoints = 150.
-- Game Variables
GameSettings.intermissionDuration = 10
GameSettings.roundDuration = 30
GameSettings.minimumPlayers = 1
GameSettings.transitionStart = 3
GameSettings.transitionEnd = 3
GameSettings.pointValues = {
	 -- Value types must match folder names to award points correctly
	LowPoints = 0,
	MediumPoints = 10,
	HighPoints = 150,
}
Don't Delete the Commas

This section of code is called an array. Arrays are used to organize values, and if they don’t have commas, the code will break. To learn more about arrays and coding in general, check out our resources at the end of the challenge.


  1. Playtest and see how the change feels. Ask yourself if you’d like players to get more points for smashing the medium sized buildings as well. You can change that too.

You can experiment with other settings in this section as well. For instance, make rounds last longer by changing the number after GameSettings.roundDuration. If you do make each round last longer, you might want to consider adding more buildings.



Previous Polishing & Publishing Next Create a Game Icon