project-navigation
Personal tools

Author Topic: Laser defense crash  (Read 5937 times)

White_Cat

  • Guest
Laser defense crash
« on: September 02, 2009, 02:46:51 am »
If a UFO is shot down by a laser defense the game crashes. This doesn't always happen.

My guess is it happens when UFOs end up crashing to water... It isn't very easy to recreate (as UFOs avoid my bases in my game) for me so I am not certain as to why.

Offline Kildor

  • Project Artist
  • Captain
  • ***
  • Posts: 757
  • Project mapper and some other stuff`er
    • View Profile
    • http://ufoai.nx0.ru
Re: Laser defense crash
« Reply #1 on: September 02, 2009, 03:14:58 am »
And where is crashlog? Where is GDB output? Where is other information?

BTW, what system do you have?

White_Cat

  • Guest
Re: Laser defense crash
« Reply #2 on: September 02, 2009, 03:27:18 am »
And where is crashlog? Where is GDB output? Where is other information?

BTW, what system do you have?

XP Pro

Offline Kildor

  • Project Artist
  • Captain
  • ***
  • Posts: 757
  • Project mapper and some other stuff`er
    • View Profile
    • http://ufoai.nx0.ru
Re: Laser defense crash
« Reply #3 on: September 02, 2009, 03:32:52 am »
Update your system to SP3 first.

And where is answers on other questions?

White_Cat

  • Guest
Re: Laser defense crash
« Reply #4 on: September 02, 2009, 03:46:29 am »
Update your system to SP3 first.

And where is answers on other questions?

I do not have any logs. Game unloads itself completely. How do you expect me to generate logs if game just quits on you :)

I of course have SP3... But that shouldn't really matter for a game... :)

White_Cat

  • Guest
Re: Laser defense crash
« Reply #5 on: September 02, 2009, 06:24:08 am »
Ah the savefile. Game will crash the moment you resume as a ufo popped up right next to my laser defense.

Offline geever

  • Project Coder
  • PHALANX Commander
  • ***
  • Posts: 2561
    • View Profile
Re: Laser defense crash
« Reply #6 on: September 02, 2009, 01:57:12 pm »
Ah the savefile. Game will crash the moment you resume as a ufo popped up right next to my laser defense.

No crash with the attached save...

-geever

White_Cat

  • Guest
Re: Laser defense crash
« Reply #7 on: September 02, 2009, 08:11:11 pm »
No crash with the attached save...

-geever

Really? What build are you on. It still crashes over here...

Offline Kildor

  • Project Artist
  • Captain
  • ***
  • Posts: 757
  • Project mapper and some other stuff`er
    • View Profile
    • http://ufoai.nx0.ru
Re: Laser defense crash
« Reply #8 on: September 02, 2009, 08:29:26 pm »
Nice, I`ve got a silent exit with empty ufoconsole.log.
Code: [Select]
#0 0040B4CF AIRFIGHT_CheckWeapon(slot=0x2e8b404, distance=3.58572173) (D:\svn\ufoai\src\client\campaign\cp_airfight.c:233)
#1 0040C19C AIRFIGHT_BaseShoot(base=0x2e717d8, weapons=0x2e8b29c, maxWeapons=4) (D:\svn\ufoai\src\client\campaign\cp_airfight.c:688)
#2 0040C683 AIRFIGHT_CampaignRunBaseDefense(dt=1) (D:\svn\ufoai\src\client\campaign\cp_airfight.c:795)
#3 0041DF9F CL_CampaignRun() (D:\svn\ufoai\src\client\campaign\cp_campaign.c:780)
#4 004A8858 MN_MapNodeDraw(node=0x316cf28) (D:\svn\ufoai\src\client\menu\node\m_node_map.c:43)
#5 00494F2F MN_DrawNode(node=0x316cf28) (D:\svn\ufoai\src\client\menu\m_draw.c:235)
#6 00494F55 MN_DrawNode(node=0x316cd98) (D:\svn\ufoai\src\client\menu\m_draw.c:244)
#7 00495247 MN_Draw() (D:\svn\ufoai\src\client\menu\m_draw.c:332)
#8 00488740 SCR_UpdateScreen() (D:\svn\ufoai\src\client\cl_screen.c:501)
#9 00484239 CL_Frame(now=79089, data=0x0) (D:\svn\ufoai\src\client\cl_main.c:1103)
#10 004EBFF6 tick_timer(now=79089, data=0x19ccbccc) (D:\svn\ufoai\src\common\common.c:1046)
#11 004EC2A3 Qcommon_Frame() (D:\svn\ufoai\src\common\common.c:1127)
#12 0050F740 WinMain@16(hInstance=0x400000, hPrevInstance=0x0, lpCmdLine=0xfee207a "", nCmdShow=10) (D:\svn\ufoai\src\ports\windows\win_main.c:364)
#13 00000000 0x005a2a28 in main() (??:??)

Code: [Select]
Program received signal SIGSEGV, Segmentation fault.
At D:\svn\ufoai\src\client\campaign\cp_airfight.c:233

>bt
#0  0x0040b4cf in AIRFIGHT_CheckWeapon (slot=0x2e8b404, distance=3.58572173) at D:\svn\ufoai\src\client\campaign\cp_airfight.c:233
#1  0x0040c19c in AIRFIGHT_BaseShoot (base=0x2e717d8, weapons=0x2e8b29c, maxWeapons=4) at D:\svn\ufoai\src\client\campaign\cp_airfight.c:688
#2  0x0040c683 in AIRFIGHT_CampaignRunBaseDefense (dt=1) at D:\svn\ufoai\src\client\campaign\cp_airfight.c:795
#3  0x0041df9f in CL_CampaignRun () at D:\svn\ufoai\src\client\campaign\cp_campaign.c:780
#4  0x004a8858 in MN_MapNodeDraw (node=0x316cf28) at D:\svn\ufoai\src\client\menu\node\m_node_map.c:43
#5  0x00494f2f in MN_DrawNode (node=0x316cf28) at D:\svn\ufoai\src\client\menu\m_draw.c:235
#6  0x00494f55 in MN_DrawNode (node=0x316cd98) at D:\svn\ufoai\src\client\menu\m_draw.c:244
#7  0x00495247 in MN_Draw () at D:\svn\ufoai\src\client\menu\m_draw.c:332
#8  0x00488740 in SCR_UpdateScreen () at D:\svn\ufoai\src\client\cl_screen.c:501
#9  0x00484239 in CL_Frame (now=79089, data=0x0) at D:\svn\ufoai\src\client\cl_main.c:1103
#10 0x004ebff6 in tick_timer (now=79089, data=0x19ccbccc) at D:\svn\ufoai\src\common\common.c:1046
#11 0x004ec2a3 in Qcommon_Frame () at D:\svn\ufoai\src\common\common.c:1127
#12 0x0050f740 in WinMain@16 (hInstance=0x400000, hPrevInstance=0x0, lpCmdLine=0xfee207a "", nCmdShow=10) at D:\svn\ufoai\src\ports\windows\win_main.c:364
#13 0x005a2a28 in main ()

> bt full
#0  0x0040b4cf in AIRFIGHT_CheckWeapon (slot=0x2e8b404, distance=3.58572173) at D:\svn\ufoai\src\client\campaign\cp_airfight.c:233
No locals.
#1  0x0040c19c in AIRFIGHT_BaseShoot (base=0x2e717d8, weapons=0x2e8b29c, maxWeapons=4) at D:\svn\ufoai\src\client\campaign\cp_airfight.c:688
i = 3
test = -2
distance = 3.58572173
#2  0x0040c683 in AIRFIGHT_CampaignRunBaseDefense (dt=1) at D:\svn\ufoai\src\client\campaign\cp_airfight.c:795
idx = 4
base = (base_t *) 0x2e717d8
baseIdx = 7
installationIdx = 49836776
#3  0x0041df9f in CL_CampaignRun () at D:\svn\ufoai\src\client\campaign\cp_campaign.c:780
currenthour = 2
currentmin = 121
date = {
  year = -30672,
  month = 74 'J',
  day = 0 '\0',
  hour = 76 'L',
  min = 88 'X',
  sec = 96 '`'
}
currentinterval = 90
checks = 0
dt = 1
i = 0
timeAlreadyFlied = 0
#4  0x004a8858 in MN_MapNodeDraw (node=0x316cf28) at D:\svn\ufoai\src\client\menu\node\m_node_map.c:43
pos = {6.78968903e-039, 4.43170482e-037}
#5  0x00494f2f in MN_DrawNode (node=0x316cf28) at D:\svn\ufoai\src\client\menu\m_draw.c:235
child = (menuNode_t *) 0x49eee4
#6  0x00494f55 in MN_DrawNode (node=0x316cd98) at D:\svn\ufoai\src\client\menu\m_draw.c:244
child = (menuNode_t *) 0x316cf28
#7  0x00495247 in MN_Draw () at D:\svn\ufoai\src\client\menu\m_draw.c:332
hoveredNode = (menuNode_t *) 0x316cf28
menu = (menuNode_t *) 0x316cd98
pos = 0
mouseMoved = qfalse
#8  0x00488740 in SCR_UpdateScreen () at D:\svn\ufoai\src\client\cl_screen.c:501
No locals.
#9  0x00484239 in CL_Frame (now=79089, data=0x0) at D:\svn\ufoai\src\client\cl_main.c:1103
delta = 28
lastFrame = 79089
#10 0x004ebff6 in tick_timer (now=79089, data=0x19ccbccc) at D:\svn\ufoai\src\common\common.c:1046
timer = (struct timer *) 0x19ccbccc
old_interval = 20
lateness = 29
#11 0x004ec2a3 in Qcommon_Frame () at D:\svn\ufoai\src\common\common.c:1127
event = (struct event *) 0x1a69a71c
time_to_next = 0
#12 0x0050f740 in WinMain@16 (hInstance=0x400000, hPrevInstance=0x0, lpCmdLine=0xfee207a "", nCmdShow=10) at D:\svn\ufoai\src\ports\windows\win_main.c:364
No locals.
#13 0x005a2a28 in main ()
No symbol table info available.

I amaze. On of the first valuable topic from this nickname.

Offline Mattn

  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 4831
  • https://github.com/mgerhardy/vengi
    • View Profile
    • Vengi Voxel Tools
Re: Laser defense crash
« Reply #9 on: September 02, 2009, 09:07:39 pm »
we need the value of the slot and the slot->ammo pointer

do this by:
p *slot
p *slot->ammo

Offline vedrit

  • Sergeant
  • *****
  • Posts: 438
    • View Profile
Re: Laser defense crash
« Reply #10 on: September 03, 2009, 08:24:34 am »
wait, someone got the laser defense to work? I thought it wasnt fully implemented

Offline Kildor

  • Project Artist
  • Captain
  • ***
  • Posts: 757
  • Project mapper and some other stuff`er
    • View Profile
    • http://ufoai.nx0.ru
Re: Laser defense crash
« Reply #11 on: September 03, 2009, 09:41:16 am »
It did implement, and aerial particle beam and laser have been implemented too.

Offline Kildor

  • Project Artist
  • Captain
  • ***
  • Posts: 757
  • Project mapper and some other stuff`er
    • View Profile
    • http://ufoai.nx0.ru
Re: Laser defense crash
« Reply #12 on: September 04, 2009, 04:45:18 am »
>p *slot
$1 = {
  idx = 0,
  base = 0x0,
  installation = 0x0,
  aircraft = 0x0,
  type = AC_ITEM_BASE_MISSILE,
  item = 0x2fb2984,
  ammo = 0x1,
  size = ITEM_LIGHT,
  ammoLeft = 48873560,
  delayNextShot = 0,
  installationTime = 0,
  nextItem = 0x1,
  nextAmmo = 0x7625dcc,
  pos = 123908632
}

>p *slot->ammo
Cannot access memory at address 0x1

Offline geever

  • Project Coder
  • PHALANX Commander
  • ***
  • Posts: 2561
    • View Profile
Re: Laser defense crash
« Reply #13 on: September 05, 2009, 09:28:30 am »
Should be fixed in r26018.

-geever