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

Animation Event OnCreate #258

Open
DCurrent opened this issue Apr 22, 2022 · 1 comment
Open

Animation Event OnCreate #258

DCurrent opened this issue Apr 22, 2022 · 1 comment
Assignees
Labels

Comments

@DCurrent
Copy link
Owner

DCurrent commented Apr 22, 2022

Description

Animation scripts fire oncreate() event on every frame.

Debugging

Reproduce

  1. Add an animation script to any model text.
  2. Add an oncreate() function with a debug trace (ex: log("\n Hello world!");).
  3. Load the module and play level with entity spawned from model.
  4. Oncreate() fires on each frame along with main().

Expected behavior

Oncreate() should only fire during initial creation of script (i.e. spawning entity).

Version

Unknown. Anecdotally this bug has existed for several years and may have been present since addition of oncreate().

@DCurrent
Copy link
Owner Author

Bug remains, and frankly I haven't a clue what to do about it. Nothing in the script parser stands out. My guess is it has something to do with animation scripts assembling a main() instead of having user defined main(), but tracing through uTunnel's logic is like finding a needle in a stack of needles blindfolded.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants