Failing to Load Babylon Modules & 3DModels

I have been banging my head on the wall for like 10 hours… I’m too trash at this…

P L E A S E help me get babylonJS to just work again. Before this version I used to load local GLTF files no problem, attach textures to materials, all that jazz…

Now every single thing I do does not work, to the 9th degree. Problems:

  1. Every single ‘import’ in my .ts file is conflicted with the generated .js file, with the warning: “exports is not defined” as the line -> “exports.es.Modules = true;” populates the second line of the .js file corresponding to the import declaration in the .ts file.

  2. .GLTF models not loading. Do I actually need to host each and every single model on a server before I can view them now? I’ve tried the sandbox, and the files I drop also don’t work (free models, I’ve scoured forums on free models and seen people have had problems (sketchfab)).

  3. When trying to utilize the extra modules like GUI, Materials, I am met with more errors in the console. The line 'import * as BABYLON from ‘babylonjs’ gives me thousands of warnings/errors detailing that multiple definitions for variables and functions have been defined in the file “babylon.modules.d.ts”
    My question is, why are there two files with the same definitions anyways? I must’ve added this extra file on my own accord thinking I needed this. I’m thinking this file is “babylon.d.ts”
    There was no instruction on whether or not to omit adding the “babylon.d.ts” file IF you’ve installed babylon via NPM.
    Please clarify whether this ‘babylon.modules.d.ts’ is the same as ‘babylon.d.ts’ if so, which one should I delete?

TL:DR; I cannot ‘import’ modules. ‘babylon.d.ts’ conflicts ‘babylon.modules.d.ts’. I cannot load GLTF models.


The following errors I have:
babylon.d.ts:2:1 - error TS6200: Definitions of the following identifiers conflict with those in another file: Nullable, float, double, int, FloatArray, IndicesArray, DataArray, Primitive, Immutable, DeepImmutable, DeepImmutableObject, ArrayTools, Scalar, ToGammaSpace, ToLinearSpace, Epsilon, Color3, Color4, Vector2, Vector3, Vector4, Size, Quaternion, Matrix, Plane, Viewport, Frustum, LOCAL, WORLD, BONE, Axis, BezierCurve, CW, CCW, Angle, Arc2, Path2, Path3D, Curve3, PositionNormalVertex, PositionNormalTextureVertex, Tmp, EventState, Observer, MultiObserver, Observable, FilesInputStore, Constants, DomManagement, Logger, _TypeStore, DeepCopier, PrecisionDate, _DevTools, WebRequest, AndOrNotEvaluator, Tags,
MaterialDefines, DataBuffer, PerformanceMonitor, RollingAverage, StringDictionary, PromisePolyfill, Buffer, VertexBuffer, SphericalHarmonics, SphericalPolynomial, PanoramaToCubeMapTools, CubeMapToSphericalPolynomialTools, EngineStore, RenderTargetCreationOptions, _AlphaState, _DepthCullingState, _StencilState, _TimeToken, InternalTexture, EasingFunction, CircleEase, BackEase, BounceEase, CubicEase, ElasticEase, ExponentialEase, PowerEase, QuadraticEase, QuarticEase, QuinticEase, SineEase, BezierCurveEase, STEP, AnimationRange, AnimationEvent, IntersectionInfo, BoundingSphere, BoundingBox, Collider, BoundingInfo, SmartArray, SmartArrayNoDuplicate, MultiMaterial, SceneLoaderFlags, TransformNode, AnimationPropertiesOverride, Bone, Checkbox, Slider, Engine, CubeTexture, TargetCamera, CameraInputsManager, KeyboardEventTypes, KeyboardInfo, KeyboardInfoPre, FreeCameraKeyboardMoveInput, ShadowLight, MaterialHelper, BlurPostProcess, ShadowGenerator, Light, Action, Condition, ValueCondition, PredicateCondition, StateCondition, SwitchBooleanAction, SetStateAction, SetValueAction, IncrementValueAction, PlayAnimationAction, StopAnimationAction, DoNothingAction, CombineAction, ExecuteCodeAction, SetParentAction, ActionManager, Ray, TrianglePickingPredicate, Scene, SceneComponentConstants, MeshStageAction, EvaluateSubMeshStageAction, ActiveMeshStageAction, CameraStageAction, CameraStageFrameBufferAction, RenderTargetStageAction, RenderingGroupStageAction, RenderingMeshStageAction, SimpleStageAction, RenderTargetsStageAction, PointerMoveStageAction, PointerUpDownStageAction, Stage, SpriteSceneComponent, SpriteManager, Sprite, PickingInfo, PointerEventTypes, PointerInfoBase, PointerInfoPre, PointerInfo, FreeCameraMouseInput, FreeCameraTouchInput, FreeCameraInputsManager, FreeCamera, StickValues, Gamepad, GenericPad, VIVE, OCULUS, WINDOWS, GEAR_VR, DAYDREAM, GENERIC, PoseEnabledControllerHelper, PoseEnabledController, WebVRController, HemisphericLight,
MultiviewRenderTarget, Camera, VRMultiviewToSingleviewPostProcess, WebVRFreeCamera, PostProcessOptions, PostProcess, PostProcessManager, AbstractScene, LayerSceneComponent, Layer, ProceduralTextureSceneComponent, ProceduralTexture, BaseParticleSystem, ATTACHED, END, SubEmitter, ParticleSystem, Particle, BoxParticleEmitter, ConeParticleEmitter, CylinderParticleEmitter, CylinderDirectedParticleEmitter, HemisphericParticleEmitter, PointParticleEmitter, SphereParticleEmitter, SphereDirectedParticleEmitter, InstancedMesh, ShaderMaterial, LinesMesh, InstancedLinesMesh, AbstractMesh, EdgesRenderer, LineEdgesRenderer, RenderingGroup, RenderingGroupInfo, RenderingManager, RenderTargetTexture, MirrorTexture, Texture, RawTexture, RuntimeAnimation, Animatable, Skeleton, MorphTarget, MorphTargetManager, MeshLODLevel, GroundMesh, PhysicsJoint, DistanceJoint, MotorEnabledJoint, HingeJoint, Hinge2Joint, PhysicsRaycastResult, PhysicsImpostor, _CreationDataStorage, _InstanceDataStorage, _InstancesBatch, Mesh, Material, BaseSubMesh, SubMesh, Geometry, VertexData, DiscBuilder,
SolidParticleSystem, SolidParticle, ModelShape, DepthSortedParticle, _MeshCollisionData, _FacetDataStorage, _InternalAbstractMeshDataInfo, ActionEvent, AbstractActionManager, NodeConstructor, Node, _IAnimationState, Animation, BaseTexture, UniformBuffer, Analyser, AudioEngine, DefaultLoadingScreen, WebGLPipelineContext, WebGLDataBuffer, VideoTexture, InstancingAttributeInfo, DepthTextureCreationOptions, EngineCapabilities, EffectFallbacks, EffectCreationOptions, Effect, ColorCurves, ImageProcessingConfigurationDefines, ImageProcessingConfiguration, FresnelParameters, SerializationHelper, ColorGradient, Color3Gradient, FactorGradient, LoadFileError, RetryStrategy, Tools, PerfCounter, AsyncLoop, DefaultCollisionCoordinator, InputManager, TargetedAnimation, AnimationGroup, KeepAssets, AssetContainer, BabylonFileParser, IndividualBabylonFileParser, Sound, PlaySoundAction, StopSoundAction, InterpolateValueAction, SoundTrack, AudioSceneComponent, WeightedSound, BouncingBehavior, FramingBehavior, BaseCameraPointersInput, ArcRotateCameraPointersInput, ArcRotateCameraKeyboardMoveInput, ArcRotateCameraMouseWheelInput, ArcRotateCameraInputsManager, ArcRotateCamera, AutoRotationBehavior, AttachToBoxBehavior, FadeInOutBehavior, PivotTools, PlaneBuilder, PointerDragBehavior, MultiPointerScaleBehavior, SixDofDragBehavior, BoneIKController, BoneLookController, ArcRotateCameraGamepadInput, ArcRotateCameraVRDeviceOrientationInput, FlyCameraMouseInput, FlyCameraInputsManager, FlyCamera, FlyCameraKeyboardInput, FollowCameraMouseWheelInput, FollowCameraPointersInput, FollowCameraInputsManager, FollowCamera, ArcFollowCamera, FollowCameraKeyboardMoveInput, FreeCameraDeviceOrientationInput, FreeCameraGamepadInput, X, Y, Z, VirtualJoystick, FreeCameraVirtualJoystickInput, TouchCamera, DeviceOrientationCamera, A, B, Start, Back, LB, RB, LeftStick, RightStick, Up, Down, Left, Right, Xbox360Pad, GamepadManager, GamepadSystemSceneComponent, UniversalCamera, GamepadCamera, PassPostProcess, PassCubePostProcess, AnaglyphPostProcess, AnaglyphArcRotateCamera, AnaglyphFreeCamera, AnaglyphGamepadCamera, AnaglyphUniversalCamera, StereoscopicInterlacePostProcess, StereoscopicArcRotateCamera, StereoscopicFreeCamera, StereoscopicGamepadCamera, StereoscopicUniversalCamera, VirtualJoysticksCamera, VRCameraMetrics, VRDistortionCorrectionPostProcess, VRDeviceOrientationArcRotateCamera, VRDeviceOrientationFreeCamera, VRDeviceOrientationGamepadCamera, PushMaterial, MaterialFlags, StandardMaterialDefines, StandardMaterial, DynamicTexture, ImageProcessingPostProcess, GroundBuilder, TorusBuilder, CylinderBuilder, OnAfterEnteringVRObservableEvent, VRExperienceHelper, WebXRSessionManager, WebXRCamera, ENTERING_XR, EXITING_XR, IN_XR, NOT_IN_XR, WebXRExperienceHelper, WebXREnterExitUIButton, WebXREnterExitUIOptions, WebXREnterExitUI, WebXRController, WebXRInput, WebXRManagedOutputCanvas, OctreeBlock, Octree, OctreeSceneComponent, UtilityLayerRenderer, Gizmo, AxisDragGizmo, AxesViewer, BoneAxesViewer, PhysicsViewer, SkeletonViewer, DebugLayer, BoxBuilder, SphereBuilder, LinesBuilder, RayHelper, NullEngineOptions, NullEngine, _OcclusionDataStorage, MultiRenderTarget, ClipboardEventTypes, ClipboardInfo, SceneLoaderProgressEvent, SceneLoader, DaydreamController, GearVRController, GenericController, OculusTouchController, ViveController, WindowsMotionController, AxisScaleGizmo, BoundingBoxGizmo,
PlaneRotationGizmo, RotationGizmo, PositionGizmo, PolyhedronBuilder, ScaleGizmo, GizmoManager, DirectionalLight, HemisphereBuilder, SpotLight, LightGizmo, BackgroundMaterial, EnvironmentHelper, PhotoDome, BRDFTextureTools, PBRClearCoatConfiguration, PBRAnisotropicConfiguration, PBRBRDFConfiguration, PBRSheenConfiguration, PBRSubSurfaceConfiguration, PBRMaterialDefines, PBRBaseMaterial, PBRMaterial, DDSTools, _DDSTextureLoader, EnvironmentTextureTools, _ENVTextureLoader, KhronosTextureContainer, _KTXTextureLoader, VideoDome, EngineInstrumentation, SceneInstrumentation, EffectLayer, EffectLayerSceneComponent, GlowLayer, HighlightLayer, LensFlareSystem, LensFlare, LensFlareSystemSceneComponent, ShadowGeneratorSceneComponent, PointLight, HDRTools, HDRCubeTexture, PhysicsEngine, CannonJSPlugin, OimoJSPlugin, RibbonBuilder, ShapeBuilder, AmmoJSPlugin, ReflectionProbe, PBRBaseSimpleMaterial, PBRMetallicRoughnessMaterial, PBRSpecularGlossinessMaterial, ColorGradingTexture, EquiRectangularCubeTexture, TGATools, _TGATextureLoader, CustomProceduralTexture, NoiseProceduralTexture, RawCubeTexture, RawTexture3D, RefractionTexture, HtmlElementTexture, WorkerPool, DracoCompression, CSG, TrailMesh, TorusKnotBuilder, Polygon, PolygonMeshBuilder, PolygonBuilder, LatheBuilder, TubeBuilder, IcoSphereBuilder, DecalBuilder, MeshBuilder, SimplificationSettings, SimplificationQueue, QUADRATIC, SimplicationQueueSceneComponent, Database, GPUParticleSystem, ParticleSystemSet, ParticleHelper, PhysicsEngineSceneComponent, PhysicsHelper, PhysicsRadialExplosionEvent, PhysicsGravitationalFieldEvent, PhysicsUpdraftEvent, PhysicsVortexEvent, PhysicsRadialExplosionEventOptions, PhysicsUpdraftEventOptions, PhysicsVortexEventOptions, Constant, Linear, Center, Perpendicular, BlackAndWhitePostProcess, PostProcessRenderEffect, ExtractHighlightsPostProcess, BloomMergePostProcess, BloomEffect, ChromaticAberrationPostProcess, CircleOfConfusionPostProcess, ColorCorrectionPostProcess, ConvolutionPostProcess, DepthOfFieldBlurPostProcess, DepthOfFieldMergePostProcessOptions, DepthOfFieldMergePostProcess, Low, Medium, High, DepthOfFieldEffect, DisplayPassPostProcess, FilterPostProcess, FxaaPostProcess, GrainPostProcess, HighlightsPostProcess, GeometryBufferRenderer, GeometryBufferRendererSceneComponent, MotionBlurPostProcess, RefractionPostProcess, SharpenPostProcess, PostProcessRenderPipeline, PostProcessRenderPipelineManager, PostProcessRenderPipelineManagerSceneComponent, DefaultRenderingPipeline, LensRenderingPipeline, SSAO2RenderingPipeline, SSAORenderingPipeline, StandardRenderingPipeline, Hable, Reinhard, HejiDawson, Photographic, TonemapPostProcess, VolumetricLightScatteringPostProcess, BoundingBoxRenderer, DepthRenderer, DepthRendererSceneComponent, OutlineRenderer, INIT, RUNNING, DONE, ERROR, AbstractAssetTask, AssetsProgressEvent, MeshAssetTask, TextFileAssetTask, BinaryFileAssetTask, ImageAssetTask, TextureAssetTask, CubeTextureAssetTask, HDRCubeTextureAssetTask, EquiRectangularCubeTextureAssetTask, AssetsManager, Deferred,
MeshExploder, FilesInput, SceneOptimization, TextureOptimization, HardwareScalingOptimization, ShadowsOptimization, PostProcessesOptimization, LensFlaresOptimization, CustomOptimization, ParticlesOptimization, RenderTargetsOptimization, MergeMeshesOptimization, SceneOptimizerOptions, SceneOptimizer, SceneSerializer, TextureTools, VideoRecorder, ScreenshotTools, PathCursor

2 declare module BABYLON {


node_modules/babylonjs/babylon.module.d.ts:1:1
  1 declare module "babylonjs/types" {
    ~~~~~~~
  Conflicts are in this file.

CCC.ts:41:51 - error TS2551: Property 'uScale' does not exist on type 'BaseTexture'. Did you mean 'scale'?

41                 backgroundMaterial.diffuseTexture.uScale = 5.0;//Repeat 5 times on the Vertical Axes
                                                   ~~~~~~

node_modules/babylonjs/babylon.module.d.ts:26976:9
  26976         scale(ratio: number): void;
                ~~~~~
  'scale' is declared here.

CCC.ts:42:51 - error TS2551: Property 'vScale' does not exist on type 'BaseTexture'. Did you mean 'scale'?

42                 backgroundMaterial.diffuseTexture.vScale = 5.0;//Repeat 5 times on the Horizontal Axes
                                                   ~~~~~~

node_modules/babylonjs/babylon.module.d.ts:26976:9
  26976         scale(ratio: number): void;
                ~~~~~
  'scale' is declared here.

... and 300 more...
1 Like

@bghgary is this with his GLTF? or is this his ts?

Also, so I’ve removed both the “node_modules/babylon.module.d.ts” and only kept “babylon.d.s” and vice-versa, both have resulted in 7 errors in the console (same errors):

[11:16:24 AM] Starting compilation in watch mode…

babylon.d.ts:1:1 - error TS6200: Definitions of the following identifiers conflict with those in another file: (INSERT ALL TYPES FROM OP)

1 declare module BABYLON {


node_modules/babylonjs/babylon.module.d.ts:1:1
  1 declare module "babylonjs/types" {
    ~~~~~~~
  Conflicts are in this file.

CCC.ts:41:51 - error TS2551: Property 'uScale' does not exist on type 'BaseTexture'. Did you mean 'scale'?

41                 backgroundMaterial.diffuseTexture.uScale = 5.0;//Repeat 5 times on the Vertical Axes
                                                   ~~~~~~

node_modules/babylonjs/babylon.module.d.ts:26976:9
  26976         scale(ratio: number): void;
                ~~~~~
  'scale' is declared here.

CCC.ts:42:51 - error TS2551: Property 'vScale' does not exist on type 'BaseTexture'. Did you mean 'scale'?

42                 backgroundMaterial.diffuseTexture.vScale = 5.0;//Repeat 5 times on the Horizontal Axes
                                                   ~~~~~~

node_modules/babylonjs/babylon.module.d.ts:26976:9
  26976         scale(ratio: number): void;
                ~~~~~
  'scale' is declared here.

node_modules/babylonjs/babylon.module.d.ts:1:1 - error TS6200: Definitions of the following identifiers conflict with those in another file: Nullable, float, double, int, FloatArray, IndicesArray, DataArray, Primitive, Immutable, DeepImmutable, DeepImmutableObject, ArrayTools, Scalar, ToGammaSpace, ToLinearSpace, Epsilon, Color3, Color4, Vector2, Vector3, Vector4, Size, Quaternion, Matrix, Plane, Viewport, Frustum, LOCAL, WORLD, BONE, Axis, BezierCurve, CW, CCW, Angle, Arc2, Path2, Path3D, Curve3, PositionNormalVertex, PositionNormalTextureVertex, Tmp, EventState, Observer, MultiObserver, Observable, FilesInputStore, Constants, DomManagement, Logger, _TypeStore, DeepCopier, PrecisionDate, _DevTools, WebRequest, AndOrNotEvaluator, Tags, MaterialDefines, DataBuffer, PerformanceMonitor, RollingAverage, StringDictionary, PromisePolyfill, Buffer, VertexBuffer, SphericalHarmonics, SphericalPolynomial, PanoramaToCubeMapTools, CubeMapToSphericalPolynomialTools, EngineStore, RenderTargetCreationOptions, _AlphaState, _DepthCullingState, _StencilState, _TimeToken, InternalTexture, EasingFunction, CircleEase, BackEase, BounceEase, CubicEase, ElasticEase, ExponentialEase, PowerEase, QuadraticEase, QuarticEase, QuinticEase, SineEase, BezierCurveEase, STEP, AnimationRange, AnimationEvent, IntersectionInfo, BoundingSphere, BoundingBox, Collider, BoundingInfo, SmartArray, SmartArrayNoDuplicate, MultiMaterial, SceneLoaderFlags, TransformNode, AnimationPropertiesOverride, Bone, Checkbox, Slider, Engine, CubeTexture, TargetCamera, CameraInputsManager, KeyboardEventTypes, KeyboardInfo, KeyboardInfoPre, FreeCameraKeyboardMoveInput, ShadowLight, MaterialHelper, BlurPostProcess, ShadowGenerator, Light, Action, Condition, ValueCondition, PredicateCondition, StateCondition, SwitchBooleanAction, SetStateAction, SetValueAction, IncrementValueAction, PlayAnimationAction, StopAnimationAction, DoNothingAction, CombineAction, ExecuteCodeAction, SetParentAction, ActionManager, Ray, TrianglePickingPredicate, Scene, SceneComponentConstants, MeshStageAction, EvaluateSubMeshStageAction, ActiveMeshStageAction, CameraStageAction, CameraStageFrameBufferAction, RenderTargetStageAction, RenderingGroupStageAction, RenderingMeshStageAction, SimpleStageAction, RenderTargetsStageAction, PointerMoveStageAction, PointerUpDownStageAction, Stage, SpriteSceneComponent, SpriteManager, Sprite, PickingInfo, PointerEventTypes, PointerInfoBase, PointerInfoPre, PointerInfo, FreeCameraMouseInput, FreeCameraTouchInput, FreeCameraInputsManager, FreeCamera, StickValues, Gamepad, GenericPad, VIVE, OCULUS, WINDOWS, GEAR_VR, DAYDREAM, GENERIC, PoseEnabledControllerHelper, PoseEnabledController, WebVRController, HemisphericLight, MultiviewRenderTarget, Camera, VRMultiviewToSingleviewPostProcess, WebVRFreeCamera, PostProcessOptions, PostProcess, PostProcessManager, AbstractScene, LayerSceneComponent, Layer, ProceduralTextureSceneComponent, ProceduralTexture, BaseParticleSystem, ATTACHED, END, SubEmitter, ParticleSystem, Particle, BoxParticleEmitter, ConeParticleEmitter, CylinderParticleEmitter, CylinderDirectedParticleEmitter, HemisphericParticleEmitter, PointParticleEmitter, SphereParticleEmitter, SphereDirectedParticleEmitter, InstancedMesh, ShaderMaterial, LinesMesh, InstancedLinesMesh, AbstractMesh, EdgesRenderer, LineEdgesRenderer, RenderingGroup, RenderingGroupInfo, RenderingManager, RenderTargetTexture, MirrorTexture, Texture, RawTexture, RuntimeAnimation, Animatable, Skeleton, MorphTarget, MorphTargetManager, MeshLODLevel, GroundMesh, PhysicsJoint, DistanceJoint, MotorEnabledJoint, HingeJoint, Hinge2Joint, PhysicsRaycastResult, PhysicsImpostor, _CreationDataStorage, _InstanceDataStorage, _InstancesBatch, Mesh, Material, BaseSubMesh, SubMesh, Geometry, VertexData, DiscBuilder, SolidParticleSystem, SolidParticle, ModelShape, DepthSortedParticle, _MeshCollisionData, _FacetDataStorage, _InternalAbstractMeshDataInfo, ActionEvent, AbstractActionManager, NodeConstructor, Node, _IAnimationState, Animation, BaseTexture, UniformBuffer, Analyser, AudioEngine, DefaultLoadingScreen, WebGLPipelineContext, WebGLDataBuffer, VideoTexture, InstancingAttributeInfo, DepthTextureCreationOptions, EngineCapabilities, EffectFallbacks, EffectCreationOptions, Effect, ColorCurves, ImageProcessingConfigurationDefines, ImageProcessingConfiguration, FresnelParameters, SerializationHelper, ColorGradient, Color3Gradient, FactorGradient, LoadFileError, RetryStrategy, Tools, PerfCounter, AsyncLoop, DefaultCollisionCoordinator, InputManager, TargetedAnimation, AnimationGroup, KeepAssets, AssetContainer, BabylonFileParser, IndividualBabylonFileParser, Sound, PlaySoundAction, StopSoundAction, InterpolateValueAction, SoundTrack, AudioSceneComponent, WeightedSound, BouncingBehavior, FramingBehavior, BaseCameraPointersInput, ArcRotateCameraPointersInput, ArcRotateCameraKeyboardMoveInput, ArcRotateCameraMouseWheelInput, ArcRotateCameraInputsManager, ArcRotateCamera, AutoRotationBehavior, AttachToBoxBehavior, FadeInOutBehavior, PivotTools, PlaneBuilder, PointerDragBehavior, MultiPointerScaleBehavior, SixDofDragBehavior, BoneIKController, BoneLookController, ArcRotateCameraGamepadInput, ArcRotateCameraVRDeviceOrientationInput, FlyCameraMouseInput, FlyCameraInputsManager, FlyCamera, FlyCameraKeyboardInput, FollowCameraMouseWheelInput, FollowCameraPointersInput, FollowCameraInputsManager, FollowCamera, ArcFollowCamera, FollowCameraKeyboardMoveInput, FreeCameraDeviceOrientationInput, FreeCameraGamepadInput, X, Y, Z, VirtualJoystick, FreeCameraVirtualJoystickInput, TouchCamera, DeviceOrientationCamera, A, B, Start, Back, LB, RB, LeftStick, RightStick, 
Up, Down, Left, Right, Xbox360Pad, GamepadManager, GamepadSystemSceneComponent, UniversalCamera, GamepadCamera, PassPostProcess, PassCubePostProcess, AnaglyphPostProcess, AnaglyphArcRotateCamera, AnaglyphFreeCamera, AnaglyphGamepadCamera, AnaglyphUniversalCamera, StereoscopicInterlacePostProcess, StereoscopicArcRotateCamera, StereoscopicFreeCamera, StereoscopicGamepadCamera, StereoscopicUniversalCamera, VirtualJoysticksCamera, VRCameraMetrics, VRDistortionCorrectionPostProcess, VRDeviceOrientationArcRotateCamera, VRDeviceOrientationFreeCamera, VRDeviceOrientationGamepadCamera, PushMaterial, MaterialFlags, StandardMaterialDefines, StandardMaterial, DynamicTexture, ImageProcessingPostProcess, GroundBuilder, TorusBuilder, CylinderBuilder, OnAfterEnteringVRObservableEvent, VRExperienceHelper, WebXRSessionManager, WebXRCamera, ENTERING_XR, EXITING_XR, IN_XR, NOT_IN_XR, WebXRExperienceHelper, WebXREnterExitUIButton, WebXREnterExitUIOptions, WebXREnterExitUI, WebXRController, WebXRInput, WebXRManagedOutputCanvas, OctreeBlock, Octree, OctreeSceneComponent, UtilityLayerRenderer, Gizmo, AxisDragGizmo, AxesViewer, BoneAxesViewer, PhysicsViewer, SkeletonViewer, DebugLayer, BoxBuilder, SphereBuilder, LinesBuilder, RayHelper, NullEngineOptions, NullEngine, _OcclusionDataStorage, MultiRenderTarget, 
ClipboardEventTypes, ClipboardInfo, SceneLoaderProgressEvent, SceneLoader, DaydreamController, GearVRController, GenericController, OculusTouchController, ViveController, WindowsMotionController, AxisScaleGizmo, BoundingBoxGizmo, PlaneRotationGizmo, RotationGizmo, PositionGizmo, PolyhedronBuilder, ScaleGizmo, GizmoManager, DirectionalLight, HemisphereBuilder, SpotLight, LightGizmo, BackgroundMaterial, EnvironmentHelper, PhotoDome, 
BRDFTextureTools, PBRClearCoatConfiguration, PBRAnisotropicConfiguration, PBRBRDFConfiguration, PBRSheenConfiguration, PBRSubSurfaceConfiguration, PBRMaterialDefines, PBRBaseMaterial, PBRMaterial, DDSTools, _DDSTextureLoader, EnvironmentTextureTools, _ENVTextureLoader, KhronosTextureContainer, _KTXTextureLoader, VideoDome, EngineInstrumentation, SceneInstrumentation, EffectLayer, EffectLayerSceneComponent, GlowLayer, HighlightLayer, LensFlareSystem, LensFlare, LensFlareSystemSceneComponent, ShadowGeneratorSceneComponent, PointLight, HDRTools, HDRCubeTexture, PhysicsEngine, 
CannonJSPlugin, OimoJSPlugin, RibbonBuilder, ShapeBuilder, AmmoJSPlugin, ReflectionProbe, PBRBaseSimpleMaterial, PBRMetallicRoughnessMaterial, PBRSpecularGlossinessMaterial, ColorGradingTexture, EquiRectangularCubeTexture, TGATools, _TGATextureLoader, CustomProceduralTexture, NoiseProceduralTexture, RawCubeTexture, RawTexture3D, RefractionTexture, HtmlElementTexture, WorkerPool, DracoCompression, CSG, TrailMesh, TorusKnotBuilder, Polygon, PolygonMeshBuilder, PolygonBuilder, LatheBuilder, TubeBuilder, IcoSphereBuilder, DecalBuilder, MeshBuilder, SimplificationSettings, SimplificationQueue, QUADRATIC, SimplicationQueueSceneComponent, Database, GPUParticleSystem, ParticleSystemSet, ParticleHelper, PhysicsEngineSceneComponent, PhysicsHelper, PhysicsRadialExplosionEvent, PhysicsGravitationalFieldEvent, PhysicsUpdraftEvent, PhysicsVortexEvent, PhysicsRadialExplosionEventOptions, PhysicsUpdraftEventOptions, PhysicsVortexEventOptions, Constant, Linear, Center, Perpendicular, BlackAndWhitePostProcess, PostProcessRenderEffect, ExtractHighlightsPostProcess, BloomMergePostProcess, BloomEffect, ChromaticAberrationPostProcess, CircleOfConfusionPostProcess, ColorCorrectionPostProcess, ConvolutionPostProcess, DepthOfFieldBlurPostProcess, DepthOfFieldMergePostProcessOptions, DepthOfFieldMergePostProcess, Low, Medium, High, DepthOfFieldEffect, DisplayPassPostProcess, FilterPostProcess, FxaaPostProcess, GrainPostProcess, HighlightsPostProcess, GeometryBufferRenderer, GeometryBufferRendererSceneComponent, MotionBlurPostProcess, RefractionPostProcess, SharpenPostProcess, PostProcessRenderPipeline, PostProcessRenderPipelineManager, PostProcessRenderPipelineManagerSceneComponent, DefaultRenderingPipeline, LensRenderingPipeline, SSAO2RenderingPipeline, SSAORenderingPipeline, StandardRenderingPipeline, Hable, Reinhard, HejiDawson, Photographic, TonemapPostProcess, VolumetricLightScatteringPostProcess, BoundingBoxRenderer, DepthRenderer, DepthRendererSceneComponent, OutlineRenderer, INIT, RUNNING, DONE, ERROR, AbstractAssetTask, AssetsProgressEvent, MeshAssetTask, TextFileAssetTask, BinaryFileAssetTask, ImageAssetTask, TextureAssetTask, CubeTextureAssetTask, HDRCubeTextureAssetTask, EquiRectangularCubeTextureAssetTask, AssetsManager, Deferred, MeshExploder, FilesInput, SceneOptimization, TextureOptimization, HardwareScalingOptimization, ShadowsOptimization, PostProcessesOptimization, LensFlaresOptimization, CustomOptimization, ParticlesOptimization, RenderTargetsOptimization, MergeMeshesOptimization, SceneOptimizerOptions, SceneOptimizer, SceneSerializer, TextureTools, VideoRecorder, ScreenshotTools, PathCursor

1 declare module "babylonjs/types" {

babylon.d.ts:1:1
1 declare module BABYLON {
~~~~~~~
Conflicts are in this file.

node_modules/babylonjs/babylon.module.d.ts:68939:9 - error TS2374: Duplicate string index signature.

68939 [name: string]: ICameraInput;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

node_modules/babylonjs/babylon.module.d.ts:68943:9 - error TS2375: Duplicate number index signature.

68943 [idx: number]: ICameraInput;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

node_modules/babylonjs/babylon.module.d.ts:102028:9 - error TS2374: Duplicate string index signature.

102028 [extension: string]: {
~~~~~~~~~~~~~~~~~~~~~~
102029 isBinary: boolean;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
102030 };
~~~~~~~~~~

[11:16:29 AM] Found 7 errors. Watching for file changes.

  • Also deleted the global babylonjs module located in my home directory. There was a constant warning that another “babylon.module.d.ts” file had been created (via npm install -g babylonjs) and I suppose it didn’t like that either.

Pinging our module expert @sebavan

It should work without changing anything.

Could you try replacing import * as BABYLON by import * as bab for instance ? basically replacing the upperCase BABYLON by smthg else to prevent naming conflicts with the namespace ?

What was the EXACT change that began this sequence?

Often revisiting that, is how I go about solving this problem. : )

Roll back. Try again. Step by step. Isolate the error with templates.

:eagle:

1 Like