mirror of
https://github.com/4ian/GDevelop.git
synced 2025-10-15 10:19:04 +00:00
95 lines
3.2 KiB
C++
95 lines
3.2 KiB
C++
/*
|
|
* GDevelop Core
|
|
* Copyright 2008-2016 Florian Rival (Florian.Rival@gmail.com). All rights
|
|
* reserved. This project is released under the MIT License.
|
|
*/
|
|
#include "AllBuiltinExtensions.h"
|
|
#include "GDCore/Tools/Localization.h"
|
|
|
|
using namespace std;
|
|
namespace gd {
|
|
|
|
void GD_CORE_API BuiltinExtensionsImplementer::ImplementsAdvancedExtension(
|
|
gd::PlatformExtension& extension) {
|
|
extension
|
|
.SetExtensionInformation(
|
|
"BuiltinAdvanced",
|
|
_("Advanced control features"),
|
|
_("Built-in extension providing advanced control features."),
|
|
"Florian Rival",
|
|
"Open source (MIT License)")
|
|
.SetExtensionHelpPath("" /*TODO: Add a documentation page for this */);
|
|
|
|
#if defined(GD_IDE_ONLY)
|
|
extension
|
|
.AddCondition("Toujours",
|
|
_("Always"),
|
|
_("This condition always returns true (or always false, if "
|
|
"the condition is inverted)."),
|
|
_("Always"),
|
|
_("Other"),
|
|
"res/conditions/toujours24.png",
|
|
"res/conditions/toujours.png")
|
|
.AddCodeOnlyParameter("conditionInverted", "")
|
|
.MarkAsAdvanced();
|
|
|
|
extension
|
|
.AddAction(
|
|
"SetReturnNumber",
|
|
_("Set number return value"),
|
|
_("Set the return value of the events function to the specified "
|
|
"number (to be used with \"Expression\" functions)."),
|
|
_("Set return value to number _PARAM0_"),
|
|
_("Functions"),
|
|
"res/function24.png",
|
|
"res/function16.png")
|
|
.AddParameter("expression", "The number to be returned")
|
|
.MarkAsAdvanced();
|
|
|
|
extension
|
|
.AddAction(
|
|
"SetReturnString",
|
|
_("Set text return value"),
|
|
_("Set the return value of the events function to the specified text "
|
|
"(to be used with \"String Expression\" functions)."),
|
|
_("Set return value to text _PARAM0_"),
|
|
_("Functions"),
|
|
"res/function24.png",
|
|
"res/function16.png")
|
|
.AddParameter("string", "The text to be returned")
|
|
.MarkAsAdvanced();
|
|
|
|
extension
|
|
.AddAction("SetReturnBoolean",
|
|
_("Set condition return value"),
|
|
_("Set the return value of the Condition events function to "
|
|
"either true (condition will pass) or false."),
|
|
_("Set return value of the condition to _PARAM0_"),
|
|
_("Functions"),
|
|
"res/function24.png",
|
|
"res/function16.png")
|
|
.AddParameter("trueorfalse", "Should the condition be true or false?")
|
|
.MarkAsAdvanced();
|
|
|
|
extension
|
|
.AddExpression(
|
|
"GetArgumentAsNumber",
|
|
_("Get function parameter value"),
|
|
_("Get function parameter (also called \"argument\") value"),
|
|
_("Functions"),
|
|
"res/function16.png")
|
|
.AddParameter("string", "Parameter name");
|
|
|
|
extension
|
|
.AddStrExpression(
|
|
"GetArgumentAsString",
|
|
_("Get function parameter text"),
|
|
_("Get function parameter (also called \"argument\") text "),
|
|
_("Functions"),
|
|
"res/function16.png")
|
|
.AddParameter("string", "Parameter name");
|
|
#endif
|
|
}
|
|
|
|
} // namespace gd
|