From 350935812d4610c500bdf6d7973d4165b8b6f5d6 Mon Sep 17 00:00:00 2001 From: chrisgregan Date: Thu, 30 Apr 2015 11:18:13 +0100 Subject: [PATCH] Improved reference doc export Tweaks to make exported reference files work nicely on Github wiki --- Assets/Fungus/Flowchart/Editor/BlockEditor.cs | 4 ++-- Assets/Fungus/Flowchart/Scripts/Commands/DeleteSaveKey.cs | 2 +- Assets/Fungus/Flowchart/Scripts/Commands/LoadVariable.cs | 2 +- Assets/Fungus/Flowchart/Scripts/Commands/RandomFloat.cs | 2 +- Assets/Fungus/Flowchart/Scripts/Commands/RandomInteger.cs | 2 +- Assets/Fungus/Flowchart/Scripts/Commands/Reset.cs | 2 +- Assets/Fungus/Flowchart/Scripts/Commands/SaveVariable.cs | 2 +- Assets/Fungus/Flowchart/Scripts/Commands/SetSaveProfile.cs | 2 +- Assets/Fungus/Flowchart/Scripts/Commands/SetVariable.cs | 2 +- Assets/Fungus/Sprite/Scripts/EventHandlers/DragCancelled.cs | 2 +- Assets/Fungus/Sprite/Scripts/EventHandlers/DragCompleted.cs | 2 +- Assets/Fungus/Sprite/Scripts/EventHandlers/DragEntered.cs | 2 +- Assets/Fungus/Sprite/Scripts/EventHandlers/DragExited.cs | 2 +- Assets/Fungus/Sprite/Scripts/EventHandlers/DragStarted.cs | 2 +- Assets/Fungus/Sprite/Scripts/EventHandlers/ObjectClicked.cs | 2 +- 15 files changed, 16 insertions(+), 16 deletions(-) diff --git a/Assets/Fungus/Flowchart/Editor/BlockEditor.cs b/Assets/Fungus/Flowchart/Editor/BlockEditor.cs index 1d5403ff..77067a80 100644 --- a/Assets/Fungus/Flowchart/Editor/BlockEditor.cs +++ b/Assets/Fungus/Flowchart/Editor/BlockEditor.cs @@ -553,7 +553,7 @@ namespace Fungus } } - string filePath = path + "/commands/" + category + ".md"; + string filePath = path + "/commands/" + category.ToLower() + "_commands.md"; Directory.CreateDirectory(Path.GetDirectoryName(filePath)); File.WriteAllText(filePath, markdown); @@ -594,7 +594,7 @@ namespace Fungus } } - string filePath = path + "/event_handlers/" + category + ".md"; + string filePath = path + "/event_handlers/" + category.ToLower() + "_events.md"; Directory.CreateDirectory(Path.GetDirectoryName(filePath)); File.WriteAllText(filePath, markdown); diff --git a/Assets/Fungus/Flowchart/Scripts/Commands/DeleteSaveKey.cs b/Assets/Fungus/Flowchart/Scripts/Commands/DeleteSaveKey.cs index 5d6baea1..18d85082 100644 --- a/Assets/Fungus/Flowchart/Scripts/Commands/DeleteSaveKey.cs +++ b/Assets/Fungus/Flowchart/Scripts/Commands/DeleteSaveKey.cs @@ -4,7 +4,7 @@ using System.Collections; namespace Fungus { - [CommandInfo("Variables", + [CommandInfo("Variable", "Delete Save Key", "Deletes a saved value from permanent storage.")] [AddComponentMenu("")] diff --git a/Assets/Fungus/Flowchart/Scripts/Commands/LoadVariable.cs b/Assets/Fungus/Flowchart/Scripts/Commands/LoadVariable.cs index 1465e1f8..a0e18427 100644 --- a/Assets/Fungus/Flowchart/Scripts/Commands/LoadVariable.cs +++ b/Assets/Fungus/Flowchart/Scripts/Commands/LoadVariable.cs @@ -4,7 +4,7 @@ using System.Collections; namespace Fungus { - [CommandInfo("Variables", + [CommandInfo("Variable", "Load Variable", "Loads a saved value and stores it in a Boolean, Integer, Float or String variable. If the key is not found then the variable is not modified.")] [AddComponentMenu("")] diff --git a/Assets/Fungus/Flowchart/Scripts/Commands/RandomFloat.cs b/Assets/Fungus/Flowchart/Scripts/Commands/RandomFloat.cs index e3bbff11..dcf48fe7 100644 --- a/Assets/Fungus/Flowchart/Scripts/Commands/RandomFloat.cs +++ b/Assets/Fungus/Flowchart/Scripts/Commands/RandomFloat.cs @@ -3,7 +3,7 @@ using System.Collections; namespace Fungus { - [CommandInfo("Variables", + [CommandInfo("Variable", "Random Float", "Sets an float variable to a random value in the defined range.")] [AddComponentMenu("")] diff --git a/Assets/Fungus/Flowchart/Scripts/Commands/RandomInteger.cs b/Assets/Fungus/Flowchart/Scripts/Commands/RandomInteger.cs index 324967dd..59913fdb 100644 --- a/Assets/Fungus/Flowchart/Scripts/Commands/RandomInteger.cs +++ b/Assets/Fungus/Flowchart/Scripts/Commands/RandomInteger.cs @@ -3,7 +3,7 @@ using System.Collections; namespace Fungus { - [CommandInfo("Variables", + [CommandInfo("Variable", "Random Integer", "Sets an integer variable to a random value in the defined range.")] [AddComponentMenu("")] diff --git a/Assets/Fungus/Flowchart/Scripts/Commands/Reset.cs b/Assets/Fungus/Flowchart/Scripts/Commands/Reset.cs index b5c2744a..763cf56c 100644 --- a/Assets/Fungus/Flowchart/Scripts/Commands/Reset.cs +++ b/Assets/Fungus/Flowchart/Scripts/Commands/Reset.cs @@ -4,7 +4,7 @@ using System.Collections.Generic; namespace Fungus { - [CommandInfo("Variables", + [CommandInfo("Variable", "Reset", "Resets the state of all commands and variables in the Flowchart.")] [AddComponentMenu("")] diff --git a/Assets/Fungus/Flowchart/Scripts/Commands/SaveVariable.cs b/Assets/Fungus/Flowchart/Scripts/Commands/SaveVariable.cs index 0533a531..807ac8c5 100644 --- a/Assets/Fungus/Flowchart/Scripts/Commands/SaveVariable.cs +++ b/Assets/Fungus/Flowchart/Scripts/Commands/SaveVariable.cs @@ -4,7 +4,7 @@ using System.Collections; namespace Fungus { - [CommandInfo("Variables", + [CommandInfo("Variable", "Save Variable", "Save an Boolean, Integer, Float or String variable to persistent storage using a string key. " + "The value can be loaded again later using the Load Variable command. You can also " + diff --git a/Assets/Fungus/Flowchart/Scripts/Commands/SetSaveProfile.cs b/Assets/Fungus/Flowchart/Scripts/Commands/SetSaveProfile.cs index bccf761d..27e1ddea 100644 --- a/Assets/Fungus/Flowchart/Scripts/Commands/SetSaveProfile.cs +++ b/Assets/Fungus/Flowchart/Scripts/Commands/SetSaveProfile.cs @@ -4,7 +4,7 @@ using System.Collections; namespace Fungus { - [CommandInfo("Variables", + [CommandInfo("Variable", "Set Save Profile", "Sets the active profile that the Save Variable and Load Variable commands will use. This is useful to crete multiple player save games. Once set, the profile applies across all Flowcharts and will also persist across scene loads.")] [AddComponentMenu("")] diff --git a/Assets/Fungus/Flowchart/Scripts/Commands/SetVariable.cs b/Assets/Fungus/Flowchart/Scripts/Commands/SetVariable.cs index 882819b6..8317e589 100644 --- a/Assets/Fungus/Flowchart/Scripts/Commands/SetVariable.cs +++ b/Assets/Fungus/Flowchart/Scripts/Commands/SetVariable.cs @@ -3,7 +3,7 @@ using System.Collections; namespace Fungus { - [CommandInfo("Variables", + [CommandInfo("Variable", "Set Variable", "Sets a Boolean, Integer, Float or String variable to a new value using a simple arithmetic operation. The value can be a constant or reference another variable of the same type.")] [AddComponentMenu("")] diff --git a/Assets/Fungus/Sprite/Scripts/EventHandlers/DragCancelled.cs b/Assets/Fungus/Sprite/Scripts/EventHandlers/DragCancelled.cs index 8138a457..5fd0b2e2 100644 --- a/Assets/Fungus/Sprite/Scripts/EventHandlers/DragCancelled.cs +++ b/Assets/Fungus/Sprite/Scripts/EventHandlers/DragCancelled.cs @@ -5,7 +5,7 @@ using System.Collections.Generic; namespace Fungus { - [EventHandlerInfo("Sprites", + [EventHandlerInfo("Sprite", "Drag Cancelled", "The block will execute when the player drags an object and releases it without dropping it on a target object.")] [AddComponentMenu("")] diff --git a/Assets/Fungus/Sprite/Scripts/EventHandlers/DragCompleted.cs b/Assets/Fungus/Sprite/Scripts/EventHandlers/DragCompleted.cs index 95fc3e10..83fdedf0 100644 --- a/Assets/Fungus/Sprite/Scripts/EventHandlers/DragCompleted.cs +++ b/Assets/Fungus/Sprite/Scripts/EventHandlers/DragCompleted.cs @@ -5,7 +5,7 @@ using System.Collections.Generic; namespace Fungus { - [EventHandlerInfo("Sprites", + [EventHandlerInfo("Sprite", "Drag Completed", "The block will execute when the player drags an object and successfully drops it on a target object.")] [AddComponentMenu("")] diff --git a/Assets/Fungus/Sprite/Scripts/EventHandlers/DragEntered.cs b/Assets/Fungus/Sprite/Scripts/EventHandlers/DragEntered.cs index 8ab1f5fc..ff27bf04 100644 --- a/Assets/Fungus/Sprite/Scripts/EventHandlers/DragEntered.cs +++ b/Assets/Fungus/Sprite/Scripts/EventHandlers/DragEntered.cs @@ -6,7 +6,7 @@ using System.Collections.Generic; namespace Fungus { - [EventHandlerInfo("Sprites", + [EventHandlerInfo("Sprite", "Drag Entered", "The block will execute when the player is dragging an object which starts touching the target object.")] [AddComponentMenu("")] diff --git a/Assets/Fungus/Sprite/Scripts/EventHandlers/DragExited.cs b/Assets/Fungus/Sprite/Scripts/EventHandlers/DragExited.cs index 8c2d2df5..e52e12b6 100644 --- a/Assets/Fungus/Sprite/Scripts/EventHandlers/DragExited.cs +++ b/Assets/Fungus/Sprite/Scripts/EventHandlers/DragExited.cs @@ -6,7 +6,7 @@ using System.Collections.Generic; namespace Fungus { - [EventHandlerInfo("Sprites", + [EventHandlerInfo("Sprite", "Drag Exited", "The block will execute when the player is dragging an object which stops touching the target object.")] [AddComponentMenu("")] diff --git a/Assets/Fungus/Sprite/Scripts/EventHandlers/DragStarted.cs b/Assets/Fungus/Sprite/Scripts/EventHandlers/DragStarted.cs index ee7803a9..a770576e 100644 --- a/Assets/Fungus/Sprite/Scripts/EventHandlers/DragStarted.cs +++ b/Assets/Fungus/Sprite/Scripts/EventHandlers/DragStarted.cs @@ -5,7 +5,7 @@ using System.Collections.Generic; namespace Fungus { - [EventHandlerInfo("Sprites", + [EventHandlerInfo("Sprite", "Drag Started", "The block will execute when the player starts dragging an object.")] [AddComponentMenu("")] diff --git a/Assets/Fungus/Sprite/Scripts/EventHandlers/ObjectClicked.cs b/Assets/Fungus/Sprite/Scripts/EventHandlers/ObjectClicked.cs index ef1bca98..0be7eb78 100644 --- a/Assets/Fungus/Sprite/Scripts/EventHandlers/ObjectClicked.cs +++ b/Assets/Fungus/Sprite/Scripts/EventHandlers/ObjectClicked.cs @@ -3,7 +3,7 @@ using System.Collections; namespace Fungus { - [EventHandlerInfo("Sprites", + [EventHandlerInfo("Sprite", "Object Clicked", "The block will execute when the user clicks or taps on the clickable object.")] [AddComponentMenu("")]