Skip to content

[Reviewed] [3D spot light] Light up a cone like a flashlight#2075

Draft
D8H wants to merge 5 commits intomainfrom
3d-spot-light
Draft

[Reviewed] [3D spot light] Light up a cone like a flashlight#2075
D8H wants to merge 5 commits intomainfrom
3d-spot-light

Conversation

@D8H
Copy link
Copy Markdown
Contributor

@D8H D8H commented Mar 31, 2026

No description provided.

@D8H D8H self-assigned this Mar 31, 2026
@D8H D8H added the ✨ New extension A new extension label Mar 31, 2026
@D8H D8H requested a review from a team as a code owner March 31, 2026 08:37
@D8H D8H added the 🔍 Reviewed extension An extension that is to be reviewed in great detail before merging. label Mar 31, 2026
@github-project-automation github-project-automation bot moved this to Needs review in Extensions review Mar 31, 2026
@D8H D8H requested a review from a team as a code owner March 31, 2026 11:05
@GDevelopApp GDevelopApp deleted a comment from github-actions bot Mar 31, 2026
@GDevelopApp GDevelopApp deleted a comment from github-actions bot Mar 31, 2026
"/** @type {gdjs.CustomRuntimeObject} */",
"const object = objects[0];",
"// Here runtimeScene is the gdjs.CustomRuntimeObjectInstanceContainer inside the custom object.",
"const gameScene = object.getRuntimeScene();",
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nitpicking: unused variable?

" break;",
" }",
" this.spotLight.shadow.mapSize.width = size;",
" this.spotLight.shadow.mapSize.height = size;",
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For directional light I had to dispose, set to null and then set it again to force the re-creation:

Image

Not sure if you need a dirty flag or not, just flagging this.

@D8H D8H marked this pull request as draft March 31, 2026 17:15
@github-actions
Copy link
Copy Markdown
Contributor

Errors were detected in this submission:

❌ 1 Error found in extension 'SpotLight3D':

  ⟶ ❌ [JavaScript disallowed properties]: JavaScript usage of the extension 'SpotLight3D' must be checked by the reviewer:
{
  allowedProperties: [
    'makeUuid',
    'rgbToHex',
    'rgbOrHexToRGBColor',
    'rgbToHexNumber',
    'hexNumberToRGB',
    'hexToRGBColor',
    'rgbOrHexStringToNumber',
    'hexNumberToRGBArray',
    'copyArray',
    'staticArray',
    'staticArray2',
    'staticObject',
    'toDegrees',
    'toRad',
    'random',
    'randomFloat',
    'randomFloatInRange',
    'randomInRange',
    'randomWithStep',
    'evtTools',
    'Variable',
    'RuntimeObject',
    'Logger',
    '__spotLight3DExtension',
    'CustomRuntimeObject',
    'CustomRuntimeObjectInstanceContainer',
    'CustomRuntimeObject3DRenderer',
    'CustomRuntimeObject3D',
    'registerRuntimeScenePreEventsCallback',
    'registerInGameEditorPostStepCallback',
    'scene3d'
  ],
  disallowedProperty: 'RuntimeScene',
  objectName: 'gdjs'
}
{
  allowedProperties: [
    'getVariables',
    'getLayer',
    'getGame',
    'getBackgroundColor',
    'getName',
    'createObject',
    'createObjectsFrom',
    'setBackgroundColor',
    'sceneJustResumed',
    'requestChange',
    'hasLayer',
    'enableDebugDraw',
    '__spotLight3DExtension'
  ],
  disallowedProperty: 'getScene',
  objectName: 'runtimeScene'
}
{
  allowedProperties: [
    'getVariables',
    'getLayer',
    'getGame',
    'getBackgroundColor',
    'getName',
    'createObject',
    'createObjectsFrom',
    'setBackgroundColor',
    'sceneJustResumed',
    'requestChange',
    'hasLayer',
    'enableDebugDraw',
    '__spotLight3DExtension'
  ],
  disallowedProperty: '__spotLightManager',
  objectName: 'runtimeScene'
}


❌ 1 Error found in extensions - please fix it before generating the registry.
No fatal error found the extension can be updated but still need fixes.

@github-actions
Copy link
Copy Markdown
Contributor

Errors were detected in this submission:

❌ 1 Error found in extension 'SpotLight3D':

  ⟶ ❌ [JavaScript disallowed properties]: JavaScript usage of the extension 'SpotLight3D' must be checked by the reviewer:
{
  allowedProperties: [
    'makeUuid',
    'rgbToHex',
    'rgbOrHexToRGBColor',
    'rgbToHexNumber',
    'hexNumberToRGB',
    'hexToRGBColor',
    'rgbOrHexStringToNumber',
    'hexNumberToRGBArray',
    'copyArray',
    'staticArray',
    'staticArray2',
    'staticObject',
    'toDegrees',
    'toRad',
    'random',
    'randomFloat',
    'randomFloatInRange',
    'randomInRange',
    'randomWithStep',
    'evtTools',
    'Variable',
    'RuntimeObject',
    'Logger',
    '__spotLight3DExtension',
    'CustomRuntimeObject',
    'CustomRuntimeObjectInstanceContainer',
    'CustomRuntimeObject3DRenderer',
    'CustomRuntimeObject3D',
    'registerRuntimeScenePreEventsCallback',
    'registerInGameEditorPostStepCallback',
    'scene3d'
  ],
  disallowedProperty: 'RuntimeScene',
  objectName: 'gdjs'
}
{
  allowedProperties: [
    'getVariables',
    'getLayer',
    'getGame',
    'getBackgroundColor',
    'getName',
    'createObject',
    'createObjectsFrom',
    'setBackgroundColor',
    'sceneJustResumed',
    'requestChange',
    'hasLayer',
    'enableDebugDraw',
    '__spotLight3DExtension'
  ],
  disallowedProperty: 'getScene',
  objectName: 'runtimeScene'
}
{
  allowedProperties: [
    'getVariables',
    'getLayer',
    'getGame',
    'getBackgroundColor',
    'getName',
    'createObject',
    'createObjectsFrom',
    'setBackgroundColor',
    'sceneJustResumed',
    'requestChange',
    'hasLayer',
    'enableDebugDraw',
    '__spotLight3DExtension'
  ],
  disallowedProperty: '__spotLightManager',
  objectName: 'runtimeScene'
}


❌ 1 Error found in extensions - please fix it before generating the registry.
No fatal error found the extension can be updated but still need fixes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

✨ New extension A new extension 🔍 Reviewed extension An extension that is to be reviewed in great detail before merging.

Projects

Status: Needs review

Development

Successfully merging this pull request may close these issues.

2 participants