MCPcopy
hub / github.com/4ian/GDevelop / v

Function v

GDevelop.js/__tests__/GDJSElseCodeGenerationIntegrationTests.js:1259–1262  ·  view source on GitHub ↗
(name)

Source from the content-addressed store, hash-verified

1257 runCompiledEvents(gdjs, runtimeScene, []);
1258
1259 const v = (name) =>
1260 runtimeScene.getVariables().has(name)
1261 ? runtimeScene.getVariables().get(name).getAsNumber()
1262 : 0;
1263
1264 // Scenario 1: Standard(true) → Else not run
1265 expect(v('S01_if')).toBe(1);

Calls 4

getMethod · 0.65
hasMethod · 0.45
getVariablesMethod · 0.45
getAsNumberMethod · 0.45

Tested by

no test coverage detected