Advanced debugging?

  • #1, by SergioWednesday, 06. March 2013, 10:34 7 years ago
    Hi all.

    I'm testing the engine and I've successfully been able to develop the first two scenes of a game. But I have some bugs which I don't have any idea on how to fix them. Maybe because of my developer background, I'm missing something to inspect the values of the objects in real time, or at least, have some window to enter some LUA command.

    I'll put an example to see my point. I have one object in a scene with an external image. No matter which object center I select, the object is always over the character. So it would we of great help being able to take a look, I don't know, maybe both objects center, or the z index table just to know if I'm doing something wrong or it is a bug on the engine.

    Do we have this possibility?

    Thanks for your time and best regards,
    Sergio.

    Newbie

    6 Posts


  • #2, by afrlmeWednesday, 06. March 2013, 12:56 7 years ago
    if it is not working how it is supposed to - then the object has probably corrupted!
    try deleting the object with the image & creating a new object to add it to!

    also via the editor settings: Extras > Options...
    * Settings: there's 2 options here ...
    ** Set object center automatically
    ** activate debug output (not sure exactly what this does - anyone?)

    * Player:
    ** Log Level: set as "info" includes more to the log.

    the log you can view inside of the editor with a pop-up panel:
    help > Log-window - or you can open messages.txt inside of the root folder of your project.

    when you are running your game via the editor - you can also have access to a command panel by hitting tab which allows you to change things while the game is running by typing in lua etc.

    P.S: if you change an object center during a game using lua, then you need to reload the scene for the change to take effect.

    Imperator

    6812 Posts

  • #3, by SergioWednesday, 06. March 2013, 14:15 7 years ago
    Ok, I will split this into two. One for my particular bug itself (I'll create a new post on bug-report), and this one for the debugging thing.

    First of all I want to thank you for the extended post. Those values you tell me are set from the very beggining wink But while they are useful for automatic messages from the engine, I can't do anything with them to debug values when I want.

    I also saw the log window, but it's only for VisEdit.log. It's useful, but it will be even more useful if we could see also message.log in real time. I tried to use external commands as tail, or notepad++ with real-time monitoring, but they don't work with fine (maybe because of the way Visionaire opens the file).

    And finally, I tried the console, but I'm not so sure I can send LUA commands. I tried to define a variable but I couldn't.

    Indeed, what I was asking for was like the log window, but with the ability to send commands to the player. Maybe a mixture between the console and the log window.

    Newbie

    6 Posts

  • #4, by afrlmeWednesday, 06. March 2013, 15:20 7 years ago
    ahh David or Alex will have to answer about this ...
    I don't use the log window in editor or the developer console in games run via editor.

    I use sublime text editor - was using notepad++ myself before.

    Maybe if David gets some spare time he could make the log window run in realtime or have it display in the in game console.

    visedit.txt only shows certain things ...
    it's messages.txt you need to check out as it's where all messages (error/info) are printed out.

    there are also 2 dump files that may be created if something goes wrong with either the editor or the player.exe (visedit.dmp & vsplayer.dmp) - you can send these to David (BigStans) for analysis to see what caused the issue.

    could you tell me what exactly is the issue you are having? in more detail please! smile

    Imperator

    6812 Posts

  • #5, by SergioWednesday, 06. March 2013, 16:27 7 years ago
    Poor devs wink

    I think the message.log is already dumped in the console, but since it is with the game font, I find it annoying to look, besides having all the game stuff behind.

    It was only something I missed these days trying to understand how Visionaire works, and also if I'm going to do some LUA scripting, having messages.log in real time (at least) could be really useful.

    Cheers!

    Newbie

    6 Posts

  • #6, by afrlmeWednesday, 06. March 2013, 16:51 7 years ago
    I write my lua scripts inside of sublime while I'm working on them as I don't like using the in editor lua editor by including the files with a little bit of code - I have added an example on how to include lua files; which can be found via the wiki above.

    https://www.visionaire-studio.net/wiki/article/how-to-loadin...

    if you have messages.txt & visedit.txt opened insie of notepad++ then each time you run your game it will add various info/errors to them as it comes to them all you have to do to see updated messages is click to another tab then back inside of notepad++ & click yes on the changes have been made - reload file? pop-up box.

    this is the current way I work, when I'm writing scripts.

    P.S: I'm currently writing up full documentation in English for the next release of VS ...
    When I'm done, anyone who is willing to translate into any other languages can do so by asking me to create them an account as I have turned off registration & unregistered users can only read whatever sections of the new wiki we don't set as private.

    Imperator

    6812 Posts

Write post