#is there a way to obtain world time like q.life_time
1 messages · Page 1 of 1 (latest)
not possible, unless u mark the entity with da date
for world, it's prob the ```js
world.getAbsoluteTime()
only thru /scoreboard
can
world.scoreboard.getScore(world.scoreboard.getObjective("worldtime")
i tried doing this
creating a dummy is just thru /scoreboard
but they said they need 2 args
objective and participant
yea so whats the participant
ye, and who's on sidebar
world.getDimension("overworld").runCommandAsync(`scoreboard players set dummy worldtime ${worldtime})}`)
world.getDimension("overworld").runCommandAsync(`title @a actionbar ${world.scoreboard.getScore(world.scoreboard.getObjective("worldtime"),"dummy")}`)
it says native type conversion failed
const sBoard = world.scoreboard
const objective = sBoard.getObjective('worldtime')
const participant = objective.getParticipants().find(({ displayName: n }) => n === 'dummy')
const timeScore = objective.getScore(participant)
thanks
np
why do u need that scoreboard if u can directly get the number from world.getAbsoluteTime()
trying to make a timing system