Game crashes when you try to move over the northern border.
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
RTS-peli |
Fix Released
|
Medium
|
Milo |
Bug Description
Here are the final debugging print lines and a backtrace. Obviously it tries to move out of the range of vector, meaning it tries to access index below zero. Probably should check for below zero (x, y) values.
Click on 0 at 141988,-714265
109472 -728726 -718026
fps: 45, rps: 198
terminate called after throwing an instance of 'std::out_of_range'
what(): vector:
Program received signal SIGABRT, Aborted.
0x00007ffff6460ec5 in raise () from /lib/libc.so.6
(gdb) bt
#0 0x00007ffff6460ec5 in raise () from /lib/libc.so.6
#1 0x00007ffff64623c1 in abort () from /lib/libc.so.6
#2 0x00007ffff6ce38cc in __gnu_cxx:
from /usr/lib/
#3 0x00007ffff6ce1bc6 in ?? ()
from /usr/lib/
#4 0x00007ffff6ce1bf3 in std::terminate() ()
from /usr/lib/
#5 0x00007ffff6ce1cfa in __cxa_throw ()
from /usr/lib/
#6 0x00007ffff6c7e7bc in std::__
from /usr/lib/
#7 0x000000000042d736 in std::vector<Tile, std::allocator<
#8 0x000000000042d755 in std::vector<Tile, std::allocator<
#9 0x000000000042eb98 in Map::getTileAt(int, int) const ()
#10 0x0000000000428643 in View::renderUnits() ()
#11 0x0000000000428feb in View::updateScr
#12 0x0000000000432232 in Engine::runGame() ()
#13 0x0000000000407b9a in main ()
Related branches
Changed in rts-peli: | |
status: | New → Confirmed |
importance: | Undecided → Medium |
assignee: | nobody → Milo (meelo) |
milestone: | none → 0.3 |
Changed in rts-peli: | |
status: | Fix Committed → Fix Released |
description: | updated |
Created MapLimits.h which has some magical constants for those that need some static information about map. nates() " function to CoordinateAction, so it validates parameters before it assigns them to the object.
Also added a "validateCoordi