Author Topic: We added some extra error logging. You will not believe what happens next!  (Read 9862 times)

Offline SupSuper

  • Lazy Developer
  • Administrator
  • Commander
  • *****
  • Posts: 2162
    • View Profile
As we work hard at debugging common problems, we run into a lot of problems coming from third-party sources. As there is no way for a user to tell apart game bugs from mod bugs, and there's no prying them away from their mods, we'd really appreciate it if you helped us keep OpenXcom as stable as it can be. :) Here's some common issues:

Graphics:
- Use 8-bit PNG (recommended: Photoshop, Aseprite).
- Use vanilla palettes.
- Don't optimize palettes.
- Transparent color must always be palette index 0 (first color).

Maps:
(affects FMP, UFO Redux and any other mods that share these files)
Code: [Select]
ROUTES/RAILYARDURBAN19.RMP Node #0 is outside map boundaries at X:18 Y:18 Z:3
ROUTES/RAILYARDURBAN19.RMP Node #1 is outside map boundaries at X:15 Y:2 Z:3
ROUTES/RAILYARDURBAN19.RMP Node #2 is outside map boundaries at X:1 Y:17 Z:3
ROUTES/RAILYARDURBAN19.RMP Node #3 is outside map boundaries at X:11 Y:18 Z:3
ROUTES/RAILYARDURBAN19.RMP Node #4 is outside map boundaries at X:9 Y:15 Z:3
ROUTES/RAILYARDURBAN19.RMP Node #8 is outside map boundaries at X:12 Y:11 Z:2
ROUTES/RAILYARDURBAN19.RMP Node #10 is outside map boundaries at X:6 Y:14 Z:1
ROUTES/RAILYARDURBAN19.RMP Node #11 is outside map boundaries at X:16 Y:3 Z:2
ROUTES/RAILYARDURBAN19.RMP Node #13 is outside map boundaries at X:12 Y:2 Z:1
ROUTES/RAILYARDURBAN19.RMP Node #14 is outside map boundaries at X:15 Y:18 Z:1
ROUTES/RAILYARDURBAN19.RMP Node #17 is outside map boundaries at X:10 Y:17 Z:0
ROUTES/RAILYARDURBAN19.RMP Node #18 is outside map boundaries at X:15 Y:9 Z:0
ROUTES/RAILYARDURBAN24.RMP Node #0 is outside map boundaries at X:18 Y:18 Z:3
ROUTES/RAILYARDURBAN24.RMP Node #1 is outside map boundaries at X:15 Y:2 Z:3
ROUTES/RAILYARDURBAN24.RMP Node #2 is outside map boundaries at X:1 Y:17 Z:3
ROUTES/RAILYARDURBAN24.RMP Node #3 is outside map boundaries at X:11 Y:18 Z:3
ROUTES/RAILYARDURBAN24.RMP Node #4 is outside map boundaries at X:9 Y:15 Z:3
ROUTES/RAILYARDURBAN24.RMP Node #8 is outside map boundaries at X:12 Y:11 Z:2
ROUTES/RAILYARDURBAN24.RMP Node #10 is outside map boundaries at X:6 Y:14 Z:1
ROUTES/RAILYARDURBAN24.RMP Node #11 is outside map boundaries at X:16 Y:3 Z:2
ROUTES/RAILYARDURBAN24.RMP Node #12 is outside map boundaries at X:12 Y:2 Z:1
ROUTES/RAILYARDURBAN24.RMP Node #13 is outside map boundaries at X:15 Y:18 Z:1
ROUTES/RAILYARDURBAN24.RMP Node #16 is outside map boundaries at X:10 Y:17 Z:0
ROUTES/RAILYARDURBAN24.RMP Node #17 is outside map boundaries at X:15 Y:9 Z:0
ROUTES/RAILYARDURBAN21.RMP Node #0 is outside map boundaries at X:18 Y:18 Z:3
ROUTES/RAILYARDURBAN21.RMP Node #1 is outside map boundaries at X:15 Y:2 Z:3
ROUTES/RAILYARDURBAN21.RMP Node #2 is outside map boundaries at X:1 Y:17 Z:3
ROUTES/RAILYARDURBAN21.RMP Node #3 is outside map boundaries at X:11 Y:18 Z:3
ROUTES/RAILYARDURBAN21.RMP Node #4 is outside map boundaries at X:9 Y:15 Z:3
ROUTES/RAILYARDURBAN21.RMP Node #8 is outside map boundaries at X:12 Y:11 Z:2
ROUTES/RAILYARDURBAN21.RMP Node #10 is outside map boundaries at X:6 Y:14 Z:1
ROUTES/RAILYARDURBAN21.RMP Node #11 is outside map boundaries at X:16 Y:3 Z:2
ROUTES/RAILYARDURBAN21.RMP Node #13 is outside map boundaries at X:12 Y:2 Z:1
ROUTES/RAILYARDURBAN21.RMP Node #14 is outside map boundaries at X:15 Y:18 Z:1
ROUTES/RAILYARDURBAN21.RMP Node #17 is outside map boundaries at X:10 Y:17 Z:0
ROUTES/RAILYARDURBAN21.RMP Node #18 is outside map boundaries at X:15 Y:9 Z:0
ROUTES/LIGHTNI2.RMP Node #0 is outside map boundaries at X:5 Y:252 Z:251
ROUTES/LIGHTNI2.RMP Node #1 is outside map boundaries at X:15 Y:5 Z:2
ROUTES/PORTUFO20.RMP Node #30 is outside map boundaries at X:20 Y:11 Z:1
ROUTES/PORTUFO05.RMP Node #7 is outside map boundaries at X:255 Y:5 Z:2
ROUTES/PORTURBAN05.RMP Node #19 is outside map boundaries at X:20 Y:6 Z:3
ROUTES/PORTURBAN08.RMP Node #30 is outside map boundaries at X:20 Y:11 Z:1
ROUTES/CULTAFARM02.RMP Node #5 is outside map boundaries at X:16 Y:4 Z:3
ROUTES/CULTAFARM02.RMP Node #6 is outside map boundaries at X:13 Y:2 Z:2
ROUTES/CULTAFARM02.RMP Node #7 is outside map boundaries at X:15 Y:0 Z:2
ROUTES/CULTAFARM02.RMP Node #8 is outside map boundaries at X:18 Y:4 Z:2
ROUTES/CULTAFARM02.RMP Node #9 is outside map boundaries at X:15 Y:8 Z:2
ROUTES/CULTAFARM02.RMP Node #10 is outside map boundaries at X:11 Y:1 Z:2
ROUTES/CULTAFARM02.RMP Node #11 is outside map boundaries at X:11 Y:6 Z:2
ROUTES/CULTAFARM02.RMP Node #12 is outside map boundaries at X:13 Y:3 Z:1
ROUTES/CULTAFARM02.RMP Node #13 is outside map boundaries at X:12 Y:7 Z:3
ROUTES/CULTAFARM02.RMP Node #14 is outside map boundaries at X:12 Y:2 Z:3

Rulesets:
- Make sure all referenced IDs actually exist (except for dummies).
- File paths should match the casing in the ruleset.
- Not everything is modular (in general, only root-level elements with IDs are modular).

Falko's Tools might help, though they might also be out of date: https://falkooxc2.pythonanywhere.com/

Offline Hobbes

  • Commander
  • *****
  • Posts: 2102
  • Infiltration subroutine in progress
    • View Profile
Maps:
(affects FMP, UFO Redux and any other mods that share these files)

Thanks for the heads up!

Offline hellrazor

  • Commander
  • *****
  • Posts: 2027
  • Deep Ruleset Digger & Bughunter
    • View Profile
    • Github Account
Nice to get this additional Error msg's but its bad that you actually let the game exit with a fatal error.

I have to do a git rollback, so i can keep playing.

Offline Dioxine

  • Commander
  • *****
  • Posts: 5458
  • punk not dead
    • View Profile
    • Nocturnal Productions
As there is no way for a user to tell apart game bugs from mod bugs

I disagree, there's an easy way, known for decades: disable a mod, see if trouble persists :)
Kudos for these RMP error msgs (man these are nigh-impossible to check by hand), and you should immediately cut all ties with these vile and destructive "third parties", whoever they are! (first party: OXCom community, second: users, third: ???) :)
« Last Edit: January 12, 2016, 11:30:56 am by Dioxine »

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 9101
    • View Profile
I disagree with Dioxine and agree with SupSuper.

If you disable the mod... you may (especially in large mods and total conversions) not be able to reproduce the situation which led to the error in the first place.
So, you need to have the mod turned on.

With that assumption, it is not possible to distinguish between mod bugs and game bugs (for a normal user).

Example:
A week ago or so I have reported a game bug on Charts screen, when there are more than 16 countries. In vanilla, this cannot be reproduced, even though it is a game/engine bug. Only with the mod turned on, it surfaced... but it is still a game bug, not a mod bug.
« Last Edit: January 12, 2016, 12:22:03 pm by Meridian »

Offline davide

  • Commander
  • *****
  • Posts: 565
    • View Profile
I think that programs without bugs unfortunately are illusions. :-[

Mods are very near to program (in our case mods are described by metadata instead that code but it is the same).

In mine opinion,
bugs should be resolved as soon as possible taking into account the context,
here we have a open source game therefore patience and tollerance are the first choices ::)

In mine experience a lot of bugs made more and more damage that what they should do. :o
I mean that in a lot of cases the effects of a bug could be reduced. 8)

As example, 

while we waiting Hobbes/Solarious fix them RMP node issues with all the time they needs,
if  Developers share the idea,
them could study some euristic to allows Battlescape survives after these errors:
node chain could be cut on first error
or node outside map boundary could be move to legit boundary place.
Errors avoided (bettere reduced) should be logged to allows a future real and complete solution.

In this case RMP error effect move from program crash :'( to few aliens do not patrol on the map :P


 




« Last Edit: January 12, 2016, 01:47:13 pm by davide »

Offline SupSuper

  • Lazy Developer
  • Administrator
  • Commander
  • *****
  • Posts: 2162
    • View Profile
Nice to get this additional Error msg's but its bad that you actually let the game exit with a fatal error.

I have to do a git rollback, so i can keep playing.
We silently pruned the bad nodes before, but this can leave the map in an invalid state, leading to nastier surprises down the road: https://openxcom.org/bugs/openxcom/issues/1158
This way players can try to avoid the bad map and modders can actually fix the problems.

I disagree, there's an easy way, known for decades: disable a mod, see if trouble persists :)
There's no way to disable a large mod without starting over, therefore losing the bug. :P

Offline hellrazor

  • Commander
  • *****
  • Posts: 2027
  • Deep Ruleset Digger & Bughunter
    • View Profile
    • Github Account
TFTD seems also to have a lot of out of boundary nodes:
Unluckily the Triton Map Routes are effected, so basically unplayable, until someone fixes/redos those routes.

Code: [Select]
[13-01-2016 05:44:36] [ERROR] Error in RMP file: ROUTES/PORT20.RMP Node #30 is outside map boundaries at X:20 Y:11 Z:1
[13-01-2016 05:44:36] [ERROR] Error in RMP file: ROUTES/PORT17.RMP Node #19 is outside map boundaries at X:20 Y:6 Z:3
[13-01-2016 05:44:36] [ERROR] Error in RMP file: ROUTES/TRITON.RMP Node #2 is outside map boundaries at X:10 Y:9 Z:1
[13-01-2016 05:45:39] [ERROR] Error in RMP file: ROUTES/PORT05.RMP Node #7 is outside map boundaries at X:255 Y:5 Z:2
[13-01-2016 05:46:32] [ERROR] Error in RMP file: ROUTES/ISLAND12.RMP Node #3 is outside map boundaries at X:254 Y:5 Z:3
[13-01-2016 05:47:58] [ERROR] Error in RMP file: ROUTES/LINERT01.RMP Node #81 is outside map boundaries at X:13 Y:52 Z:1
[13-01-2016 05:49:40] [ERROR] Error in RMP file: ROUTES/ALSHIP02.RMP Node #17 is outside map boundaries at X:252 Y:4 Z:1
[13-01-2016 05:50:06] [ERROR] Error in RMP file: ROUTES/LEVEL07.RMP Node #1 is outside map boundaries at X:20 Y:4 Z:0
[13-01-2016 05:50:06] [ERROR] Error in RMP file: ROUTES/LEVEL07.RMP Node #2 is outside map boundaries at X:20 Y:3 Z:0
[13-01-2016 05:54:39] [ERROR] Error in RMP file: ROUTES/UFO05.RMP Node #22 is outside map boundaries at X:9 Y:20 Z:3
[13-01-2016 05:56:06] [ERROR] Error in RMP file: ROUTES/GAL03.RMP Node #12 is outside map boundaries at X:20 Y:16 Z:3
[13-01-2016 05:57:28] [ERROR] Error in RMP file: ROUTES/MU03.RMP Node #2 is outside map boundaries at X:255 Y:255 Z:3
[13-01-2016 05:57:28] [ERROR] Error in RMP file: ROUTES/MU03.RMP Node #3 is outside map boundaries at X:255 Y:7 Z:3
[13-01-2016 05:57:28] [ERROR] Error in RMP file: ROUTES/MU03.RMP Node #4 is outside map boundaries at X:255 Y:255 Z:3

EDIT: Since Warboy's Github Commit Those are culled and do not crash the game, but do show still up in the openxcom.log file.
Also in new Windows Nightly openxcom_git_master_2016_01_13_0640
« Last Edit: January 13, 2016, 09:48:18 am by hellrazor »

Offline SupSuper

  • Lazy Developer
  • Administrator
  • Commander
  • *****
  • Posts: 2162
    • View Profile
Yes as usual, TFTD has forced our hand. :P Hopefully this won't cause any problems later on, please throughly test the Battlescape and make sure there are no crashes in vanilla maps.
We keep the error logs so modders can keep an eye on any map problems.
« Last Edit: January 13, 2016, 11:26:57 am by SupSuper »

Offline davide

  • Commander
  • *****
  • Posts: 565
    • View Profile
Thank you very much to all People spends efforts to solve(reduce) quicky these issues.
 :-*



Offline Hobbes

  • Commander
  • *****
  • Posts: 2102
  • Infiltration subroutine in progress
    • View Profile
Re: We added some extra error logging. You will not believe what happens next!
« Reply #10 on: January 13, 2016, 02:50:13 pm »
Yes as usual, TFTD has forced our hand. :P

I have greatly increased my appreciation of TFTD' features, and bugs, due to all the improvements you guys had to add because of them. Thanks :)

Offline XOps

  • Colonel
  • ****
  • Posts: 193
  • Guy who drowns first
    • View Profile
Re: We added some extra error logging. You will not believe what happens next!
« Reply #11 on: January 15, 2016, 09:45:55 pm »
Hate to seem like an idiot here, but what exactly is this error and how does one fix it? How can a node be outside the map's boundary?

Offline Warboy1982

  • Administrator
  • Commander
  • *****
  • Posts: 2333
  • Developer
    • View Profile
Re: We added some extra error logging. You will not believe what happens next!
« Reply #12 on: January 16, 2016, 01:32:56 am »
it arises because each mapblock is made up of two files, the .MAP file which contains all the tile information, and the RMP file, which stores nodes as a series of x/y/z coordinates. if a given map block is 10x10x4 and the RMP says there's a node at 19,11,5, we face this problem.

how does one fix it? use map editor to resize the map to accommodate the node, select the node, and delete it. we've managed to code around these discrepancies so they no longer cause an issue in openxcom, but we still dump info about them to the log so map makers can get some feedback.