#Generating client assets

5 messages · Page 1 of 1 (latest)

nova kindle
#

I'm having a moment here where the consumer isn't consuming

ClientEvents.highPriorityAssets(event => {
        let id = "kubejs:testBlock"
        let rlID = Utils.id(id)
        
        let genLoc = `${rlID.getNamespace()}:block/${rlID.getPath()}`
        let genOnLoc = `${rlID.getNamespace()}:block/${rlID.getPath()}_on`

        event.addBlockState(id, blockState => {
            blockState.variant('facing=north, lit=false', v => v.model(genLoc))
            blockState.variant('facing=north, lit=true', v => v.model(genOnLoc))
            blockState.variant('facing=east, lit=false', v => v.model(genLoc).y(90))
            blockState.variant('facing=east, lit=true', v => v.model(genOnLoc).y(90))
            blockState.variant('facing=south, lit=false', v => v.model(genLoc).y(180))
            blockState.variant('facing=south, lit=true', v => v.model(genOnLoc).y(180))
            blockState.variant('facing=west, lit=false', v => v.model(genLoc).y(270))
            blockState.variant('facing=west, lit=true', v => v.model(genOnLoc).y(270))

            console.log(blockState.toJson())
        })

{variants={"facing=north, lit=false":{"model":"ArrowFunction (1) => {...}"},"facing=north, lit=true":{"model":"ArrowFunction (1) => {...}"},"facing=east, lit=false":{"model":"ArrowFunction (1) => {...}"},"facing=east, lit=true":{"model":"ArrowFunction (1) => {...}"},"facing=south, lit=false":{"model":"ArrowFunction (1) => {...}"},"facing=south, lit=true":{"model":"ArrowFunction (1) => {...}"},"facing=west, lit=false":{"model":"ArrowFunction (1) => {...}"},"facing=west, lit=true":{"model":"ArrowFunction (1) => {...}"}}} [java.util.HashMap]

tribal jasperBOT
#

Once your ticket has been resolved, please close it with </ticket close:1054771505520717835> command!

nova kindle
#

Max am I being dumb here or is this a rhino/kjs issue?

nova kindle
#

Guess I can close this, thanks for working on that Chief, never even thought to use the method signature for that.... or check the git issues lol