HeroEngine Forums
Welcome, Guest. Please login or Register for HeroCloud Account.

Author Topic: 19:05:38: !WARNING!System:HEBlade::HeroScriptExposedFuctions::CallPerFrameScript  (Read 903 times)

AWW_boss

  • General Accounts
  • *
  • Posts: 846
  • gdfgd
    • View Profile

Hi! I recently started using a RegisterForPerFrameMethodCallback on one of the objects and i started getting these messages spammed in the console. What is the reason for these messages and how can i get rid of them?

19:05:38: !WARNING!System:HEBlade::HeroScriptExposedFuctions::CallPerFrameScripts
19:05:38: !WARNING!System:HEBlade::HeroScriptExposedFuctions::CallPerFrameScripts
19:05:38: !WARNING!System:HEBlade::HeroScriptExposedFuctions::CallPerFrameScripts
19:05:40: !WARNING!System:HEBlade::HeroScriptExposedFuctions::CallPerFrameScripts
19:05:40: !WARNING!System:HEBlade::HeroScriptExposedFuctions::CallPerFrameScripts
19:05:40: !WARNING!System:HEBlade::HeroScriptExposedFuctions::CallPerFrameScripts
19:05:40: !WARNING!System:HEBlade::HeroScriptExposedFuctions::CallPerFrameScripts
19:05:42: !WARNING!System:HEBlade::HeroScriptExposedFuctions::CallPerFrameScripts
19:05:42: !WARNING!System:HEBlade::HeroScriptExposedFuctions::CallPerFrameScripts
Logged

HE-HERB

  • HeroEngine
  • *****
  • Posts: 530
    • View Profile
    • HeroEngine

There should be more specific information following that message.  FYI, the message pasted here breaks down  to:
1. time
2. type of message
3. logging channel
4. executable
5. system
6. context

These types of messages are because you've created an HSL script that is called every frame, instead of on a time interval.  Scripts called every frame are both 1) a time sink, and 2) can be kind of weird since frame rates are inherently variable.

Since "removing per-frame node callback on deleted node" is the only warning I see in that code, that's probably what you're getting. 

You've probably added an HSL script that, e.g.:
1. executes every frame
2. adds and/or deletes a callback every frame frame


I would recommend reviewing your code to determine which script it is, and then move it to a time interval

Cheers

/ninja spelling edit
« Last Edit: Feb 08, 15, 05:17:51 PM by HE-HERB »
Logged
herb marselas
graphics guy

AWW_boss

  • General Accounts
  • *
  • Posts: 846
  • gdfgd
    • View Profile

Hi!

Thanks, after code review i noticed that i was indeed missing "UnRegisterForPerFrameMethodCallback" just before the node is destroyed. Once i added the UnRegister just before the node is destroyed i no longer see the warning.

Best regards
Logged