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

Use TryGetComponent instead of GetComponent #1039

Open
alexandrunechita-popcore opened this issue Oct 4, 2022 · 0 comments
Open

Use TryGetComponent instead of GetComponent #1039

alexandrunechita-popcore opened this issue Oct 4, 2022 · 0 comments

Comments

@alexandrunechita-popcore

https://docs.unity3d.com/ScriptReference/Component.TryGetComponent.html

In here. This place is called at least once per Entity.

namespace Entitas.Unity
{
  public static class EntityLinkExtension
  {
    public static EntityLink GetEntityLink(this GameObject gameObject) => gameObject.GetComponent<EntityLink>();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: New
Development

No branches or pull requests

1 participant