MicrosoftDocs / minecraft-creator

This is the repository for Minecraft Bedrock documentation.
Creative Commons Attribution 4.0 International
180 stars 131 forks source link

Incorrect documentation of `query.life_time`. #772

Open Amman-Works opened 10 months ago

Amman-Works commented 10 months ago

Describe the bug The current documentation for query.life_time states, "Returns the time in seconds since the current animation started, else 0.0 if not called within an animation." However, this information is inaccurate, and it aligns with the documentation of query.anim_time. query.life_time actually returns the time in seconds since the entity is loaded and can be invoked outside of an animation.

To Reproduce Steps to reproduce the behavior:

  1. Go to 'https://learn.microsoft.com/en-us/minecraft/creator/reference/content/molangreference/examples/molangconcepts/queryfunctions?view=minecraft-bedrock-stable'
  2. Click on 'List of Entity Queries'
  3. Scroll down to 'query.life_time'
  4. See error

Expected behavior I had anticipated the description of query.life_time to be more aligned with "Returns the time in seconds since the entity is loaded in the world" rather than the current phrasing of "Returns the time in seconds since the current animation started, else 0.0 if not called within an animation.

Screenshots N/A

Desktop (please complete the following information):

Smartphone (please complete the following information):

Additional context N/A