Jump to content

how to read log userscript error reports ?

Recommended Posts


## Error
# Number has no properties (0)
Stack trace:
REPLACE(Source, Search value, New value) (#237, Line:1872, Column:30) in messages and text (ID:225)
returns en minuscule(message to change) (#1666, Line:568, Column:65) in PLAYER STORAGE (ID:100)
return attribute value(PLAYER STORAGE) (#1552, Line:139, Column:116) in skillCheck (ID:91)
base skill check(difficulty, skill to check, skillName, player, tool to check, XP gained mult, global XP gained mult, attribute) (#77, Line:4364, Column:180) in forest hidden object trigger zone (ID:523)
On Trigger enter(Trigger entity) (#1, Line:4363, Column:12) in forest hidden object trigger zone (ID:523)

Like the one above.

especialy what does stack trace mean ? 

Share this post

Link to post
Share on other sites

Tbh info like this is mainly for our Programmers, who then know, how to fix the issue according to this. I'm not even really sure, what that specifically means ? But if you have a problem you're encountering, let me know, and I'll send it to them for solving.

  • Thanks 1
  • Haha 1

Share this post

Link to post
Share on other sites

Hi, I can help with this one.

The problem is in the top row directly under "Stack trace:" line. Problem was encountered in REPLACE instruction. (probably Source argument was invalid. You can try to write to console content of Source argument before you call REPLACE. The problematic REPLACE was in VS defined in "messages and text" Game logic (with ID=225)

Steps should be:

  1. Open scripts for "messages and text" Game logic (with ID=225)
  2. Write "#237" to search and press enter. It should focus specific REPLACE instruction (needed in complicated pieces of code)
  3. Try to find out if any of REPLACE arguments can be invalid.

Regarding other lines in stack trace: they should help you to understand how the issue happened. In this case you should go from the bottom to the top line.

  1. On Trigger enter was triggered in forest hidden object trigger zone (ID:523)
  2. There was call of your custom instruction "base skill check" from the same trigger zone
  3. From there it went through your "return attribute value" instruction defined in skillCheck game logic object
  4. and you probably get the idea at the moment.

Line+Column info can help advance users who check text script which can be found next to output_log_clean.log (userscript.js) when you playtest your game. If you do not feel to look into text scripts then you can ignore this part.

  • Thanks 2

Share this post

Link to post
Share on other sites

This is great thanks a lot, very helpful.

Because I try my functions to be multi purpose, I have revy hard time jugling between items, items types, item templates, game object types and templates. 

Like if I want to create a global spawn function, I have to identify the precise type of object to spawn, and would have to cycle through all the items above, because trying to spawn the wrong object would return me a script breaking error.

Share this post

Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in

Sign In Now