New out of bounds vsarray crash

Issue: New out of bounds vsarray crash
Crash (y/n): n
Platform (Windows/Mac/Linux): windowns
Description:
While placing roads I recived this crash

MMORPG Tycoon 2
win64
0.12.34-g9aa189b
Checking supported resolutions…
Available Modes
0: 1600 x 900
1: 1440 x 900
2: 1366 x 768
3: 1360 x 768
4: 1280 x 800
5: 1280 x 768
6: 1280 x 720
7: 1280 x 600
8: 1152 x 864
9: 1024 x 768
10: 800 x 600
11: 640 x 480
12: 640 x 400
13: 512 x 384
14: 400 x 300
15: 320 x 240
16: 320 x 200
Initialising [1280x800] resolution…
Found 1 displays:
Display #0 Generic PnP Monitor (1600x900)

OpenGL Context:
Vendor: NVIDIA Corporation
Renderer: GeForce GT 540M/PCIe/SSE2
Version: 3.3.0 NVIDIA 372.70
Shading Language Version: 3.30 NVIDIA via Cg compiler
== Begin OpenGL limits ==
Max 3D texture size: 2048
Max array texture layers: 2048
Max clip distances: 8
Max samples in a color multisample texture: 32
Maximum atomic counters: 98304
Maximum fragment shader uniform components: 233472
Maximum geometry shader uniform components: 231424
Maximum combined texture image units: 192
Maximum combined uniform blocks: 84
Maximum cube map dimensions: 16384
Maximum samples in a multisample depth or depth-stencil texture: 32
Maximum simultaneous draw buffers: 8
Maximum simultaneous draw buffers with dual-source blending: 1
Recommended maximum number of vertex array indices: 1048576
Recommended maximum number of vertex array vertices: 1048576
Max fragment shader input components: 128
Max fragment shader uniform components: 4096
Maximum texels in the texel array of a texture buffer: 134217728
Maximum supported texture image units in a fragment shader: 32
Maximum texture size (rough estimate): 16384
Maximum uniform buffer binding points: 84
Maximum uniform block size: 65536
Maximum uniform locations: 65536
Maximum varying components: 124
Maximum floating point varying components: 124
Maximum atomic counters in vertex shaders: 16384
Maximum vertex attributes in vertex shader: 16
Maximum active shader storage blocks in a vertex shader: 16
Maximum texture image units in vertex shader: 32
Maximum uniform components in vertex shader: 4096
Maximum output components in vertex shader: 128
Maximum uniform blocks per vertex shader: 14
Maximum simultaneous viewports: 16
Maximum MSAA samples: 32
NVidia-only: Currently available video memory: 2037768
ATI-only: Currently available video memory: 2037768
== End OpenGL limits ==
VSync: ENABLED
TextureUnits: 32 from vertex shader, 192 total
Screen Ratio: 1.600000
– Initialising game “MMORPG”
TextInput was enabled by default; turning it off until we need it!
No joystick found. Using keyboard input.
Shown
Exposed
Event 0: Path event:/UI/window close end: min range 0.000000: max range 0.000000
Event 1: Path event:/UI/button slot deselect: min range 0.000000: max range 0.000000
Event 2: Path event:/UI/button slot desocket: min range 0.000000: max range 0.000000
Event 3: Path event:/old/general click: min range 0.000000: max range 0.000000
Event 4: Path event:/UI/general cancel: min range 0.000000: max range 0.000000
Event 5: Path event:/Title screens/loading screen world appear: min range 0.000000: max range 0.000000
Event 6: Path event:/UI/window open start: min range 0.000000: max range 0.000000
Event 7: Path event:/UI/button slot socket: min range 0.000000: max range 0.000000
Event 8: Path event:/Title screens/loading screen whoosh 01: min range 20.000000: max range 300.000000
Event 9: Path event:/Title screens/loading screen whoosh 02: min range 16.000000: max range 65.000000
Event 10: Path event:/Title screens/loading screen launch: min range 0.000000: max range 0.000000
Event 11: Path event:/UI/general notification: min range 0.000000: max range 0.000000
Event 12: Path event:/Title screens/loading screen white flash: min range 0.000000: max range 0.000000
Event 13: Path event:/UI/button click: min range 0.000000: max range 0.000000
Event 14: Path event:/UI/window close start: min range 0.000000: max range 0.000000
Event 15: Path event:/old/button release toggle on: min range 0.000000: max range 0.000000
Event 16: Path event:/UI/window open end: min range 0.000000: max range 0.000000
Event 17: Path event:/UI/window looping: min range 0.000000: max range 0.000000
Event 18: Path event:/Title screens/loading screen loop: min range 0.000000: max range 0.000000
Event 19: Path event:/UI/button click up new field: min range 0.000000: max range 0.000000
Bus 0: Path ‘bus:/UI/UI_UnD’: Volume: 1.000000
Bus 1: Path ‘bus:/UI’: Volume: 1.000000
Bus 2: Path ‘bus:/UI/UI_d1’: Volume: 1.000000
Bus 3: Path ‘bus:/UI/UI_d2’: Volume: 1.000000
Bus 4: Path ‘bus:/Reverb’: Volume: 1.000000
Bus 5: Path ‘bus:/’: Volume: 1.000000
Param 0: dramaticMIX [0.00-1.00] (default 0.00)
Rebuild front plate mesh
Rebuild front plate mesh
Unable to find requested power “TerrainEdit”
Unable to find requested power “ShapeEdit”
Unable to find requested power “ColorEdit”
Unable to find requested power “Business”
Unable to find requested power “Build”
Unable to find requested power “Terrain”
Unable to find requested power “EditSelect”
Unable to find requested power “EditSelectMulti”
Unable to find requested power “Buildings”
Unable to find requested power “Roads”
Unable to find requested power “CastleBuild”
Unable to find requested power “NPCs”
Unable to find requested power “Town Edit”
Unable to find requested power “Destroy Town”
Unable to find requested power “Build Capital”
Unable to find requested power “Ability0”
Unable to find requested power “Ability1”
Unable to find requested power “Ability2”
Unable to find requested power “Ability3”
Unable to find requested power “Ability4”
Unhandled command: MessageTo CursorBehaviour MaxUp

Unhandled command: MessageTo CursorBehaviour MaxUp

Unhandled command: MessageTo CursorBehaviour MaxDown

MISSING VARIANT INFORMATION
MISSING VARIANT INFORMATION
MISSING VARIANT INFORMATION
MISSING VARIANT INFORMATION
MISSING VARIANT INFORMATION
About to load save file
Processing save file
Finished processing save file
Unable to find requested power “TerrainEdit”
Unable to find requested power “ShapeEdit”
Unable to find requested power “ColorEdit”
Unable to find requested power “Business”
Unable to find requested power “Build”
Unable to find requested power “Terrain”
Unable to find requested power “EditSelect”
Unable to find requested power “EditSelectMulti”
Unable to find requested power “Buildings”
Unable to find requested power “Roads”
Unable to find requested power “CastleBuild”
Unable to find requested power “NPCs”
Unable to find requested power “Town Edit”
Unable to find requested power “Destroy Town”
Unable to find requested power “Build Capital”
Unable to find requested power “Ability0”
Unable to find requested power “Ability1”
Unable to find requested power “Ability2”
Unable to find requested power “Ability3”
Unable to find requested power “Ability4”
Exposed
Unhandled command: MessageTo CursorBehaviour SetOption “Free”

Failed assertion: Out of bounds vsArray access
Failed condition: (id >= 0 && id < m_arrayLength)
at VS_Array.h:190

Yup, I saw that crash report as it came in, and am already debugging. Looks like somehow you’ve maybe wound up with a road which contains zero points? Am trying to figure out how that happened.

i think its to do with double clicking a road starting point with the road tool selected.

Its like laying a road on the circle point of the road. If that makes any sense

Yup, that’s exactly it; double-clicking on an intersection without moving the mouse even slightly. If you move the mouse away from the intersection and then back again, it doesn’t do it. Same if you make a zero-length road by adding and then removing points; it only crashes if you do it by an immediate double-click.

Will be fixed in the next build!

1 Like

it looks the same thing happens with the wall.

Yes; walls are the same as paths, under the hood. (As are ramps, and mountain passes). They’ll all be affected by this same issue. (Except that it may not be possible to do with passes.) The same fix will handle all of them.