mirror of
https://github.com/4ian/GDevelop.git
synced 2025-10-15 10:19:04 +00:00
Fix GetArgumentAsString (and fix test game using it)
This commit is contained in:
@@ -120,7 +120,7 @@ AdvancedExtension::AdvancedExtension() {
|
||||
parameterNameCode + ")) || 0 : 0)";
|
||||
});
|
||||
|
||||
GetAllExpressions()["GetArgumentAsString"]
|
||||
GetAllStrExpressions()["GetArgumentAsString"]
|
||||
.GetCodeExtraInformation()
|
||||
.SetCustomCodeGenerator([&generateParameterNameCode](
|
||||
const std::vector<gd::Expression>& parameters,
|
||||
|
@@ -111,6 +111,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "p1_stand.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "p1_stand.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -119,6 +120,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "p1_jump.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "p1_jump.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -127,6 +129,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "p1_walk01.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "p1_walk01.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -135,6 +138,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "p1_walk02.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "p1_walk02.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -143,6 +147,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "p1_walk03.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "p1_walk03.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -151,6 +156,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "p1_walk04.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "p1_walk04.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -159,6 +165,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "p1_walk05.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "p1_walk05.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -167,6 +174,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "p1_walk06.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "p1_walk06.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -175,6 +183,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "p1_walk07.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "p1_walk07.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -183,6 +192,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "p1_walk08.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "p1_walk08.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -191,6 +201,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "p1_walk09.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "p1_walk09.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -199,6 +210,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "p1_walk10.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "p1_walk10.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -207,6 +219,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "p1_walk11.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "p1_walk11.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -215,6 +228,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "brickWall.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "brickWall.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -223,6 +237,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "bridge.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "bridge.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -231,6 +246,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "grassHalfMid.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "grassHalfMid.png",
|
||||
"smoothed": true,
|
||||
"userAdded": true
|
||||
@@ -239,6 +255,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "castleCenter.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "castleCenter.png",
|
||||
"smoothed": true,
|
||||
"userAdded": true
|
||||
@@ -247,6 +264,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "bridgeLogs.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "bridgeLogs.png",
|
||||
"smoothed": true,
|
||||
"userAdded": true
|
||||
@@ -255,6 +273,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "Left.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "Left.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -263,6 +282,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "Right.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "Right.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -271,6 +291,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "ladder_mid.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "ladder_mid.png",
|
||||
"smoothed": true,
|
||||
"userAdded": true
|
||||
@@ -279,6 +300,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "Grass.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "grass.png",
|
||||
"smoothed": true,
|
||||
"userAdded": true
|
||||
@@ -287,6 +309,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "PlayerArea.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "PlayerArea.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -295,6 +318,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "slimeWalk1.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "slimeWalk1.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -303,6 +327,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "slimeWalk2.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "slimeWalk2.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -311,6 +336,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "slimeDead.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "slimeDead.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -319,6 +345,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "flyFly1.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "flyFly1.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -327,6 +354,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "flyFly2.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "flyFly2.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -335,6 +363,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "flyDead.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "flyDead.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -343,6 +372,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "cloud1.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "cloud1.png",
|
||||
"smoothed": false,
|
||||
"userAdded": false
|
||||
@@ -351,6 +381,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "cloud2.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "cloud2.png",
|
||||
"smoothed": false,
|
||||
"userAdded": false
|
||||
@@ -359,6 +390,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "cloud3.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "cloud3.png",
|
||||
"smoothed": false,
|
||||
"userAdded": false
|
||||
@@ -367,6 +399,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "bush.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "bush.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -375,6 +408,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "cactus.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "cactus.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -383,6 +417,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "plant.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "plant.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -391,6 +426,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "coinGold.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "coinGold.png",
|
||||
"smoothed": true,
|
||||
"userAdded": true
|
||||
@@ -399,6 +435,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "shadedDark06.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "shadedDark06.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -407,6 +444,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "shadedDark05.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "shadedDark05.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -415,6 +453,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "shadedDark45.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "shadedDark45.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -423,6 +462,7 @@
|
||||
"alwaysLoaded": false,
|
||||
"file": "shadedDark09.png",
|
||||
"kind": "image",
|
||||
"metadata": "",
|
||||
"name": "shadedDark09.png",
|
||||
"smoothed": true,
|
||||
"userAdded": false
|
||||
@@ -3631,7 +3671,7 @@
|
||||
"textG": 0,
|
||||
"textR": 0
|
||||
},
|
||||
"comment": "Platform should rotate =====>",
|
||||
"comment": "Platform should rotate, platforms should be colored",
|
||||
"comment2": ""
|
||||
},
|
||||
{
|
||||
@@ -3684,7 +3724,9 @@
|
||||
},
|
||||
"parameters": [
|
||||
"",
|
||||
"Platform"
|
||||
"Platform",
|
||||
"\"0;255;100\"",
|
||||
""
|
||||
],
|
||||
"subInstructions": []
|
||||
}
|
||||
@@ -5227,8 +5269,8 @@
|
||||
"version": "",
|
||||
"eventsFunctions": [
|
||||
{
|
||||
"description": "t",
|
||||
"fullName": "t",
|
||||
"description": "Rotate the given object",
|
||||
"fullName": "Rotate function",
|
||||
"functionType": "Action",
|
||||
"name": "RotatePlease",
|
||||
"sentence": "Rotate the _PARAM1_ at speed _PARAM2_deg/sec",
|
||||
@@ -5256,15 +5298,6 @@
|
||||
}
|
||||
],
|
||||
"parameters": [
|
||||
{
|
||||
"codeOnly": true,
|
||||
"defaultValue": "",
|
||||
"description": "",
|
||||
"name": "runtimeScene",
|
||||
"optional": false,
|
||||
"supplementaryInformation": "",
|
||||
"type": "currentScene"
|
||||
},
|
||||
{
|
||||
"codeOnly": false,
|
||||
"defaultValue": "",
|
||||
@@ -5312,17 +5345,7 @@
|
||||
"events": []
|
||||
}
|
||||
],
|
||||
"parameters": [
|
||||
{
|
||||
"codeOnly": true,
|
||||
"defaultValue": "",
|
||||
"description": "",
|
||||
"name": "runtimeScene",
|
||||
"optional": false,
|
||||
"supplementaryInformation": "",
|
||||
"type": "currentScene"
|
||||
}
|
||||
]
|
||||
"parameters": []
|
||||
},
|
||||
{
|
||||
"description": "Return a speed of rotation",
|
||||
@@ -5351,24 +5374,14 @@
|
||||
"events": []
|
||||
}
|
||||
],
|
||||
"parameters": [
|
||||
{
|
||||
"codeOnly": true,
|
||||
"defaultValue": "",
|
||||
"description": "",
|
||||
"name": "runtimeScene",
|
||||
"optional": false,
|
||||
"supplementaryInformation": "",
|
||||
"type": "currentScene"
|
||||
}
|
||||
]
|
||||
"parameters": []
|
||||
},
|
||||
{
|
||||
"description": "Color the given sprite objects",
|
||||
"fullName": "Color sprites",
|
||||
"functionType": "Action",
|
||||
"name": "ColorThings",
|
||||
"sentence": "Color _PARAM1_",
|
||||
"sentence": "Color _PARAM1_ with color: _PARAM2_",
|
||||
"events": [
|
||||
{
|
||||
"disabled": false,
|
||||
@@ -5383,7 +5396,7 @@
|
||||
},
|
||||
"parameters": [
|
||||
"ObjectToColor",
|
||||
"\"0;255;50\""
|
||||
"GetArgumentAsString(\"Color\")"
|
||||
],
|
||||
"subInstructions": []
|
||||
}
|
||||
@@ -5392,15 +5405,6 @@
|
||||
}
|
||||
],
|
||||
"parameters": [
|
||||
{
|
||||
"codeOnly": true,
|
||||
"defaultValue": "",
|
||||
"description": "",
|
||||
"name": "runtimeScene",
|
||||
"optional": false,
|
||||
"supplementaryInformation": "",
|
||||
"type": "currentScene"
|
||||
},
|
||||
{
|
||||
"codeOnly": false,
|
||||
"defaultValue": "",
|
||||
@@ -5409,6 +5413,15 @@
|
||||
"optional": false,
|
||||
"supplementaryInformation": "Sprite",
|
||||
"type": "objectList"
|
||||
},
|
||||
{
|
||||
"codeOnly": false,
|
||||
"defaultValue": "",
|
||||
"description": "Color string",
|
||||
"name": "Color",
|
||||
"optional": false,
|
||||
"supplementaryInformation": "",
|
||||
"type": "string"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
Reference in New Issue
Block a user