Skip to content
Snippets Groups Projects
Commit c7b5cc5b authored by Robin Ruud Kristensen's avatar Robin Ruud Kristensen
Browse files

option to generate rooms in editor view

parent 199450f1
No related branches found
No related tags found
2 merge requests!52Updating master,!42Ruud
using Bigsock;
using System.Collections;
using System.Collections.Generic;
using UnityEditor;
using UnityEngine;
namespace BigSock
{
[CustomEditor(typeof(AbstractMapGen), true)]
public class RandomMapGeneratorEditor : Editor
{
AbstractMapGen generator;
private void Awake()
{
generator = (AbstractMapGen) target;
}
public override void OnInspectorGUI()
{
base.OnInspectorGUI();
if(GUILayout.Button("Create Map"))
{
generator.Generate();
}
if(GUILayout.Button("Clear Map"))
{
generator.ClearMap();
}
}
}
}
\ No newline at end of file
fileFormatVersion: 2
guid: 495198b4c25bfef41a170198c98139e1
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment