Painting Tiles using PlayMaker

PlayMaker by Hutong Games is a visual scripting tool for Unity which enables you to define behavior using states which is useful for both programmers and non-programmers alike. You may want to take a look at some of their video tutorials if you haven’t encountered PlayMaker before!

We have created a basic selection of actions allowing your PlayMaker state machines to interact with tile systems which can be downloaded from the RtsPlayMakerActions repository on BitBucket.

Since most of these actions require a tile system as input it makes sense to create a variable to hold the active tile system. This is easier to maintain since the active tile system can then be changed in one centralized placed rather than for each action in your state machine. In the above screenshot I chose to initialize this within an initial “Setup” state, but of course there are other approaches which may better suit your needs.

The following video demonstrates how to use a couple of these actions:

See action reference for further information.