1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

Path in runtime error messages for custom Lua files is truncated in both console +log

Discussion in 'Civ5 - Confirmed Bugs' started by Seraphim8400, Dec 24, 2010.

  1. Seraphim8400

    Seraphim8400 Warlord

    Joined:
    Nov 7, 2010
    Messages:
    112
    Code:
    [29916.311] \Users\Seraphim\Documents\My Games\Sid Meier's Civilization 5\MODS\RealNameEarth (v 7)\Context Files\Historical end\HistoricalEnd: 4	3189	8432
    [29916.311] Runtime Error: [string "C:\Users\Seraphim\Documents\My Games\Sid Me..."]:123: attempt to index field '?' (a nil value)
    after version 135
    the lua log will give a full path of the luafile
    but if there is a code error
    the string will cut off by the limit of character
    the modder will not get the file name
    it is worse than can not get the path
     
  2. Petek

    Petek Alpha Centaurian Administrator Supporter

    Joined:
    Nov 8, 2001
    Messages:
    3,647
    Location:
    Berkeley, Calif., USA
    I really don't know anything about these matters, but did you test this with patch 1.0.1.141? According to the change log for that patch:

    If this is still a problem, you might get a better response posting this in the C & C forum.
     
  3. Seraphim8400

    Seraphim8400 Warlord

    Joined:
    Nov 7, 2010
    Messages:
    112
    1.0.1.141 is same to 135
    the change your Quote is mean that at 141 they re-enabled some function removed at 135
    and you can look row2 of my code
    the path cut off like "Sid Me..." at 135 or higher
    the filename hide
    but the filename is more important and useful than the path like "C:\Users\Seraphim\Documents\My Games\Sid Me..."

    and what is the " C & C forum" mean ?
     
  4. Petek

    Petek Alpha Centaurian Administrator Supporter

    Joined:
    Nov 8, 2001
    Messages:
    3,647
    Location:
    Berkeley, Calif., USA
    Sorry, I was referring to the Civ5 - Creation & Customization forum. It has a Civ 5 - SDK / LUA subforum. That's probably the best place to post your question.
     
  5. MouseyPounds

    MouseyPounds Prince

    Joined:
    Nov 8, 2010
    Messages:
    417
    Location:
    Maryland, USA
    While the C&C forum is probably the best place to ask if anyone knows about a work-around, this is definitely a bug that started in 1.0.1.135 which is when full paths started being listed in the console/log instead of just filenames. Modders have no control over the syntax of error messages like this one, and since the filename is cut off much too early it can be quite difficult to isolate the error; having the full path listed or even the end of the path instead of the beginning of the path would be far preferable.
     
  6. Petek

    Petek Alpha Centaurian Administrator Supporter

    Joined:
    Nov 8, 2001
    Messages:
    3,647
    Location:
    Berkeley, Calif., USA
    It must be obvious that I know nothing about LUA. :lol:

    @MouseyPounds -- If you will be so kind as to confirm that the description of this bug is accurate, then I'll move this to the Confirmed Bugs forum and add it to the Bug List. Thanks.
     
  7. MouseyPounds

    MouseyPounds Prince

    Joined:
    Nov 8, 2010
    Messages:
    417
    Location:
    Maryland, USA
    Yep I can confirm although I'd personally word it like this: Path given in runtime error messages for custom Lua files is truncated in both console and Lua.log
     
  8. The_J

    The_J Say No 2 Net Validations Retired Moderator Supporter

    Joined:
    Oct 22, 2008
    Messages:
    32,938
    Location:
    DE/NL/FR
    I guess Petek will not be angry if i move the thread and list it...
    -> Moderator Action: Moved.
     

Share This Page