Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Targetable check, fix / complete implementation, polish #135

Closed
vatro opened this issue Aug 14, 2022 · 1 comment · Fixed by #191
Closed

Targetable check, fix / complete implementation, polish #135

vatro opened this issue Aug 14, 2022 · 1 comment · Fixed by #191
Assignees
Labels
Milestone

Comments

@vatro
Copy link
Owner

vatro commented Aug 14, 2022

see (e.g.):

/** Defaults to `true` which means that components / objects with targets (_`DirectionalLight`, `SpotLight`, `OrthographicCamera` and `PerspectiveCamera`_)
* will add the built-in 'blank' target-Object3D to component's / object's parent on initialization. `target` can be either set to `false` ( TODO ) (_which will remove the target from parent only if it's
* not the built-in 'blank' `Object3D`_) or some other object in the scene (_any `Object3D`, an `Empty` component or a `Mesh` component_) */
export let target: Targetable | boolean = undefined
$: if (target === undefined) target = true

target can be either set to false ( TODO )`

and

} else if (typeof this.target === "boolean") {
// light_comp_ref.target = true -> use the built-in 'Object3D' as target (add it to the scene)
this.light["target"].userData.is_builtin_target = true
this.scene.add(this.light["target"])
}

@vatro vatro added this to the 1.0.0-next.1 milestone Aug 14, 2022
@vatro vatro self-assigned this Aug 14, 2022
vatro added a commit that referenced this issue Oct 4, 2022
Fix remaining ESLint warnings, leave those with issues.
See #170 for more details.

Current Status:
svelte-check: no errors / warnings / hints
lint: 0 errors, 3 warnings

The remaining 3 warnings should be fixed by: #135, #175 and #176
@vatro vatro pinned this issue Nov 25, 2022
@vatro
Copy link
Owner Author

vatro commented Nov 26, 2022

This is a mess, will need a refactor:

  • deprecate / drop target prop incl. related logic (use only lookAt prop)
  • Lights with target: Fix / refactor target & lookAt logic incl. helper handling
  • Fix / refactor PropUtils.setLookAtFromValue

@vatro vatro added refactor bug Something isn't working labels Nov 26, 2022
vatro pushed a commit that referenced this issue Dec 3, 2022
@vatro vatro mentioned this issue Dec 3, 2022
@vatro vatro closed this as completed in #191 Dec 3, 2022
vatro pushed a commit that referenced this issue Dec 3, 2022
@vatro vatro unpinned this issue Dec 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant