Giter Club home page Giter Club logo

Comments (7)

adngdb avatar adngdb commented on June 15, 2024

Thanks! The actual file in the repo is up-to-date, but for some reason readthedocs isn't. I'll take a look.

from entity-system-js.

maxailloud avatar maxailloud commented on June 15, 2024

Yes I saw.
Maybe hosting it in the gh-pages could be easier.

from entity-system-js.

adngdb avatar adngdb commented on June 15, 2024

It was a configuration issue with rtfd. It's solved now: https://entity-system-js.readthedocs.io/en/latest/#components (you might have to refresh your cache).

from entity-system-js.

maxailloud avatar maxailloud commented on June 15, 2024

Oh I just saw the commit fixing the documentation.

from entity-system-js.

Hectate avatar Hectate commented on June 15, 2024

This error still exists in the Processors section.
https://github.com/adngdb/entity-system-js/blob/master/docs/index.md#processors

That said; is there not a way to query the manager for all entities with a component? The example requires an entity ID to be passed to manager.getEntityWithComponent() but I'm looking for a way to get an array (or similar) of all entity ids that have the component assigned without knowing the IDs beforehand.

from entity-system-js.

Hectate avatar Hectate commented on June 15, 2024

Reviewing the Concentration example I came across this:

RenderingProcessor.prototype.initTiles = function () {
        var cards = this.manager.getComponentsData('Card');
        for (var entityId in cards) {
            this.createCardTile(entityId, cards[entityId]);
        }
};

Is that the recommended approach?

from entity-system-js.

adngdb avatar adngdb commented on June 15, 2024

@Hectate Yes, getComponentsData is how to get all entities that have the specified component. In version 1.5.0, that method returns an object of entityID -> componentData. Thanks for noticing the mismatch in documentation, I'm on it!

from entity-system-js.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.