October 2017
Intermediate to advanced
548 pages
13h 23m
English
The PictureController manages picture editing commands from the UI. Our picture editor can perform various actions on a picture object. These are enumerated in the PictureComand enum. We will design it to encapsulate the implementation of the commands and only expose them through a single Execute() API function.
File: PictureController.csusing UnityEngine; public enum PictureCommand { ADD, EDIT, DONE, CANCEL, MOVE, SCALE, DELETE, IMAGE, FRAME } public class PictureController : MonoBehaviour { public GameObject toolbar; void Start() { BeginEdit(); } public void Execute(PictureCommand ...Read now
Unlock full access