Bus error when colliding with sensor

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
Post Reply
User avatar
AaronWizard
Citizen
Posts: 68
Joined: Sun Nov 06, 2011 2:45 pm
Location: Canada

Bus error when colliding with sensor

Post by AaronWizard »

I'm using the physics engine to handle collision detection and response. I have a bunch of coloured keys that players need to collect to open doors. These keys have a physics body and shape set to be a sensor. When players touch a key, the key's physics body is removed from the world. Except that right now I'm getting an error whenever I try to pick up a key.

The terminal reports a bus error while the problem report window that pops up after the crash shows this:

Code: Select all

Process:         love [617]
Path:            /Applications/love.app/Contents/MacOS/love
Identifier:      org.love2d.love
Version:         ??? (0.7.2)
Code Type:       X86 (Native)
Parent Process:  launchd [128]

Date/Time:       2012-03-28 12:12:34.011 -0300
OS Version:      Mac OS X 10.6.8 (10K549)
Report Version:  6

Interval Since Last Report:          139941 sec
Crashes Since Last Report:           53
Per-App Interval Since Last Report:  12198 sec
Per-App Crashes Since Last Report:   52
Anonymous UUID:                      471AF3B6-04C1-4F2C-96EB-E6735DF0F73B

Exception Type:  EXC_BAD_ACCESS (SIGBUS)
Exception Codes: KERN_PROTECTION_FAILURE at 0x0000000000000008
Crashed Thread:  0  Dispatch queue: com.apple.main-thread

Thread 0 Crashed:  Dispatch queue: com.apple.main-thread
0   org.love2d.love               	0x0002fe25 love::Reference::push() + 9
1   org.love2d.love               	0x0008070c love::physics::box2d::World::ContactCallback::process() + 100
2   org.love2d.love               	0x0008081d love::physics::box2d::World::update(float) + 51
3   org.love2d.love               	0x0007689f love::physics::box2d::w_World_update(lua_State*) + 79
4   com.yourcompany.Lua           	0x0059f623 luaD_precall + 890
5   com.yourcompany.Lua           	0x005b65f7 luaV_execute + 7461
6   com.yourcompany.Lua           	0x0059f895 luaD_call + 165
7   com.yourcompany.Lua           	0x00595145 f_call + 48
8   com.yourcompany.Lua           	0x0059eaba luaD_rawrunprotected + 73
9   com.yourcompany.Lua           	0x0059fc04 luaD_pcall + 99
10  com.yourcompany.Lua           	0x005951ea lua_pcall + 163
11  com.yourcompany.Lua           	0x0059acfd luaB_xpcall + 104
12  com.yourcompany.Lua           	0x0059f623 luaD_precall + 890
13  com.yourcompany.Lua           	0x005b65f7 luaV_execute + 7461
14  com.yourcompany.Lua           	0x0059f895 luaD_call + 165
15  com.yourcompany.Lua           	0x005950eb lua_call + 67
16  org.love2d.love               	0x0002fd94 SDL_main + 452
17  org.love2d.love               	0x00089447 -[SDLMain applicationDidFinishLaunching:] + 95
18  com.apple.Foundation          	0x98bafdb3 _nsnote_callback + 176
19  com.apple.CoreFoundation      	0x903ae763 __CFXNotificationPost + 947
20  com.apple.CoreFoundation      	0x903ae16a _CFXNotificationPostNotification + 186
21  com.apple.Foundation          	0x98ba4c50 -[NSNotificationCenter postNotificationName:object:userInfo:] + 128
22  com.apple.Foundation          	0x98bb205d -[NSNotificationCenter postNotificationName:object:] + 56
23  com.apple.AppKit              	0x96b25216 -[NSApplication _postDidFinishNotification] + 125
24  com.apple.AppKit              	0x96b25126 -[NSApplication _sendFinishLaunchingNotification] + 74
25  com.apple.AppKit              	0x96d3e9c5 -[NSApplication(NSAppleEventHandling) _handleAEOpenDocumentsForURLs:] + 975
26  com.apple.AppKit              	0x96c7bfe0 -[NSApplication(NSAppleEventHandling) _handleCoreEvent:withReplyEvent:] + 236
27  com.apple.Foundation          	0x98be51f8 -[NSAppleEventManager dispatchRawAppleEvent:withRawReply:handlerRefCon:] + 511
28  com.apple.Foundation          	0x98be4fbc _NSAppleEventManagerGenericHandler + 228
29  com.apple.AE                  	0x998f7f5c aeDispatchAppleEvent(AEDesc const*, AEDesc*, unsigned long, unsigned char*) + 166
30  com.apple.AE                  	0x998f7e5b dispatchEventAndSendReply(AEDesc const*, AEDesc*) + 43
31  com.apple.AE                  	0x998f7d65 aeProcessAppleEvent + 197
32  com.apple.HIToolbox           	0x97861197 AEProcessAppleEvent + 50
33  com.apple.AppKit              	0x96af57d2 _DPSNextEvent + 1420
34  com.apple.AppKit              	0x96af4dd6 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 156
35  com.apple.AppKit              	0x96ab71f3 -[NSApplication run] + 821
36  org.love2d.love               	0x00089cbc main + 1882
37  org.love2d.love               	0x0002fa66 start + 54

Thread 1:  Dispatch queue: com.apple.libdispatch-manager
0   libSystem.B.dylib             	0x99fd0382 kevent + 10
1   libSystem.B.dylib             	0x99fd0a9c _dispatch_mgr_invoke + 215
2   libSystem.B.dylib             	0x99fcff59 _dispatch_queue_invoke + 163
3   libSystem.B.dylib             	0x99fcfcfe _dispatch_worker_thread2 + 240
4   libSystem.B.dylib             	0x99fcf781 _pthread_wqthread + 390
5   libSystem.B.dylib             	0x99fcf5c6 start_wqthread + 30

Thread 2:
0   libSystem.B.dylib             	0x99fa9b5a semaphore_timedwait_signal_trap + 10
1   libSystem.B.dylib             	0x99fd76e1 _pthread_cond_wait + 1066
2   libSystem.B.dylib             	0x9a0065a8 pthread_cond_timedwait_relative_np + 47
3   com.apple.audio.CoreAudio     	0x902f83ab CAGuard::WaitFor(unsigned long long) + 219
4   com.apple.audio.CoreAudio     	0x902fb3dd CAGuard::WaitUntil(unsigned long long) + 289
5   com.apple.audio.CoreAudio     	0x902f8cda HP_IOThread::WorkLoop() + 1892
6   com.apple.audio.CoreAudio     	0x902f8571 HP_IOThread::ThreadEntry(HP_IOThread*) + 17
7   com.apple.audio.CoreAudio     	0x902f8488 CAPThread::Entry(CAPThread*) + 140
8   libSystem.B.dylib             	0x99fd7259 _pthread_start + 345
9   libSystem.B.dylib             	0x99fd70de thread_start + 34

Thread 3:
0   libSystem.B.dylib             	0x99fa9c0e mach_wait_until + 10
1   libSystem.B.dylib             	0x9a031429 nanosleep + 345
2   SDL                           	0x0055a453 SDL_Delay + 99
3   org.love2d.love               	0x0003c65d love::audio::openal::Audio::run(void*) + 35
4   SDL                           	0x0054becd SDL_Linked_Version + 397
5   SDL                           	0x0055a1f1 SDL_SemWait + 49
6   libSystem.B.dylib             	0x99fd7259 _pthread_start + 345
7   libSystem.B.dylib             	0x99fd70de thread_start + 34

Thread 4:
0   libSystem.B.dylib             	0x99fa9c0e mach_wait_until + 10
1   libSystem.B.dylib             	0x9a031429 nanosleep + 345
2   SDL                           	0x0055a5c3 SDL_Delay + 467
3   SDL                           	0x0054becd SDL_Linked_Version + 397
4   SDL                           	0x0055a1f1 SDL_SemWait + 49
5   libSystem.B.dylib             	0x99fd7259 _pthread_start + 345
6   libSystem.B.dylib             	0x99fd70de thread_start + 34

Thread 0 crashed with X86 Thread State (32-bit):
  eax: 0x00000004  ebx: 0x00000002  ecx: 0x00000004  edx: 0x01127ae4
  edi: 0x00000001  esi: 0x0082e9d0  ebp: 0xbfffe308  esp: 0xbfffe2f0
   ss: 0x00000023  efl: 0x00010286  eip: 0x0002fe25   cs: 0x0000001b
   ds: 0x00000023   es: 0x00000023   fs: 0x00000000   gs: 0x0000000f
  cr2: 0x00000008

Binary Images:
    0x1000 -    0xeafff +org.love2d.love ??? (0.7.2) <33856844-88EC-B439-7854-09DE84A05048> /Applications/love.app/Contents/MacOS/love
  0x1e1000 -   0x27dfff +com.yourcompany.IL 1.0 (1) <D822201D-0A85-2084-2E07-FB9CF2CE09F2> /Applications/love.app/Contents/Frameworks/IL.framework/Versions/A/IL
  0x34d000 -   0x36ffff +org.xiph.vorbis 1.1.3svn (1.1.3d1) /Applications/love.app/Contents/Frameworks/Vorbis.framework/Versions/A/Vorbis
  0x49b000 -   0x4c4fff  com.apple.audio.OpenAL 1.4 (1.4) <CDC6D2B8-3DCA-E511-2250-75567E4C94BD> /System/Library/Frameworks/OpenAL.framework/Versions/A/OpenAL
  0x4d2000 -   0x50fff7 +org.freetype.FreeType 2.4.3 (243) <B78A60A5-2D79-2DD8-6CB9-4F216D1168A9> /Applications/love.app/Contents/Frameworks/FreeType.framework/Versions/A/FreeType
  0x51b000 -   0x580f17 +SDL 1.2.14 (1.2.14) <FA2F2FC9-E936-DD87-FBB0-F5052D5CDAB8> /Applications/love.app/Contents/Frameworks/SDL.framework/Versions/A/SDL
  0x592000 -   0x5b8ff3 +com.yourcompany.Lua ??? (1.0) <E38E4660-72E2-9DC2-81ED-B853AF1187C8> /Applications/love.app/Contents/Frameworks/Lua.framework/Versions/A/Lua
  0x5c2000 -   0x5c4fc8 +org.xiph.ogg 1.1.4svn (1.1.4d1) /Applications/love.app/Contents/Frameworks/Ogg.framework/Versions/A/Ogg
  0x5c8000 -   0x5e2ff7 +org.icculus.physfs 1.0 (1) <49775755-37CD-2409-2AEC-AEBC0055FA95> /Applications/love.app/Contents/Frameworks/physfs.framework/Versions/A/physfs
  0x5ef000 -   0x62aff3 +net.sourceforge.libmodplug 1.0 (1) <EC9341D6-4183-4FD4-3396-58976B48F15A> /Applications/love.app/Contents/Frameworks/libmodplug.framework/Versions/A/libmodplug
  0x6b8000 -   0x701fef +mpg123 21.1.0 (compatibility 21.0.0) <F50F7C80-DD8F-4ADC-B6B7-9016AA718E41> /Applications/love.app/Contents/Frameworks/mpg123.framework/Versions/A/mpg123
  0x71b000 -   0x71effc +libltdl.3.dylib 5.4.0 (compatibility 5.0.0) <7EB66768-E1AB-E38C-3799-255E56CF3693> /Applications/love.app/Contents/Frameworks/mpg123.framework/Versions/A/Resources/libltdl.3.dylib
  0x724000 -   0x724ff7  libmx.A.dylib 315.0.0 (compatibility 1.0.0) <01401BF8-3FC7-19CF-ACCE-0F292BFD2F25> /usr/lib/libmx.A.dylib
  0xf75000 -   0xf79ff3  com.apple.audio.AudioIPCPlugIn 1.1.6 (1.1.6) <E9CB576C-283B-1DB2-0C69-E7C914BD7922> /System/Library/Extensions/AudioIPCDriver.kext/Contents/Resources/AudioIPCPlugIn.bundle/Contents/MacOS/AudioIPCPlugIn
  0xf7e000 -   0xf84ff7  com.apple.audio.AppleHDAHALPlugIn 2.0.5 (2.0.5f14) <38E3C1A4-84E4-C105-B55F-8FC4C154036D> /System/Library/Extensions/AppleHDA.kext/Contents/PlugIns/AppleHDAHALPlugIn.bundle/Contents/MacOS/AppleHDAHALPlugIn
0x139b8000 - 0x13b31ff7  GLEngine ??? (???) <76C922AA-A4A7-2835-537B-17F316AD95F6> /System/Library/Frameworks/OpenGL.framework/Resources/GLEngine.bundle/GLEngine
0x13b63000 - 0x13b87fe7  GLRendererFloat ??? (???) <F19DDBE8-1DF6-6618-F554-0E81ED85CE67> /System/Library/Frameworks/OpenGL.framework/Resources/GLRendererFloat.bundle/GLRendererFloat
0x17066000 - 0x17479fef  com.apple.ATIRadeonX2000GLDriver 1.6.36 (6.3.6) <257CAA1D-6573-2932-E344-E96F6C9CDA84> /System/Library/Extensions/ATIRadeonX2000GLDriver.bundle/Contents/MacOS/ATIRadeonX2000GLDriver
0x70000000 - 0x700cbfff  com.apple.audio.units.Components 1.6.5 (1.6.5) <412DBD1B-E9B5-E67C-99E4-820BF38239AC> /System/Library/Components/CoreAudio.component/Contents/MacOS/CoreAudio
0x8fe00000 - 0x8fe4162b  dyld 132.1 (???) <A4F6ADCC-6448-37B4-ED6C-ABB2CD06F448> /usr/lib/dyld
0x901a7000 - 0x9023ffe7  edu.mit.Kerberos 6.5.11 (6.5.11) <F36DB665-A88B-7F5B-6244-6A2E7FFFF668> /System/Library/Frameworks/Kerberos.framework/Versions/A/Kerberos
0x90289000 - 0x902c3ff7  libcups.2.dylib 2.8.0 (compatibility 2.0.0) <038731B1-CC44-3943-E3DE-4BAAA203EB72> /usr/lib/libcups.2.dylib
0x902d8000 - 0x90352fff  com.apple.audio.CoreAudio 3.2.6 (3.2.6) <156A532C-0B60-55B0-EE27-D02B82AA6217> /System/Library/Frameworks/CoreAudio.framework/Versions/A/CoreAudio
0x90353000 - 0x904cefe7  com.apple.CoreFoundation 6.6.6 (550.44) <F88C95CD-1264-782D-A1F5-204739847E93> /System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation
0x904cf000 - 0x90512ff7  com.apple.NavigationServices 3.5.4 (182) <753B8906-06C0-3AE0-3D6A-8FF5AC18ED12> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/NavigationServices.framework/Versions/A/NavigationServices
0x90513000 - 0x90516ffb  com.apple.help 1.3.2 (41.1) <8AC20B01-4A3B-94BA-D8AF-E39034B97D8C> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/Help.framework/Versions/A/Help
0x90587000 - 0x905a3fe3  com.apple.openscripting 1.3.1 (???) <DA16DE48-59F4-C94B-EBE3-7FAF772211A2> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/OpenScripting.framework/Versions/A/OpenScripting
0x905a4000 - 0x90613ff7  libvMisc.dylib 268.0.1 (compatibility 1.0.0) <2FC2178F-FEF9-6E3F-3289-A6307B1A154C> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libvMisc.dylib
0x90614000 - 0x906a6fe7  com.apple.print.framework.PrintCore 6.3 (312.7) <7410D1B2-655D-68DA-D4B9-2C65747B6817> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/PrintCore.framework/Versions/A/PrintCore
0x90ad0000 - 0x90b89fe7  libsqlite3.dylib 9.6.0 (compatibility 9.0.0) <52438E77-55D1-C231-1936-76F1369518E4> /usr/lib/libsqlite3.dylib
0x90d6d000 - 0x9155c557  com.apple.CoreGraphics 1.545.0 (???) <1D9DC7A5-228B-42CB-7018-66F42C3A9BB3> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/CoreGraphics.framework/Versions/A/CoreGraphics
0x9155d000 - 0x9156eff7  com.apple.LangAnalysis 1.6.6 (1.6.6) <97511CC7-FE23-5AC3-2EE2-B5479FAEB316> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/LangAnalysis.framework/Versions/A/LangAnalysis
0x915e6000 - 0x916b1fef  com.apple.CoreServices.OSServices 359.2 (359.2) <7C16D9C8-6F41-5754-17F7-2659D9DD9579> /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/OSServices.framework/Versions/A/OSServices
0x919f5000 - 0x91a1dff7  libxslt.1.dylib 3.24.0 (compatibility 3.0.0) <315D97C2-4E1F-A95F-A759-4A3FA5639E75> /usr/lib/libxslt.1.dylib
0x91a1e000 - 0x91abbfe3  com.apple.LaunchServices 362.3 (362.3) <15B47388-16C8-97DA-EEBB-1709E136169E> /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/LaunchServices
0x91ac8000 - 0x91b70ffb  com.apple.QD 3.36 (???) <FA2785A4-BB69-DCB4-3BA3-7C89A82CAB41> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/QD.framework/Versions/A/QD
0x91b7f000 - 0x91c81fe7  libcrypto.0.9.8.dylib 0.9.8 (compatibility 0.9.8) <015563C4-81E2-8C8A-82AC-31B38D904A42> /usr/lib/libcrypto.0.9.8.dylib
0x91c82000 - 0x91c86ff7  libGIF.dylib ??? (???) <3B4E6D0B-89EB-251F-3693-5187254D5BE2> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources/libGIF.dylib
0x91c87000 - 0x91db5fe7  com.apple.CoreData 102.1 (251) <E6A457F0-A0A3-32CD-6C69-6286E7C0F063> /System/Library/Frameworks/CoreData.framework/Versions/A/CoreData
0x91db6000 - 0x91df8ff7  libvDSP.dylib 268.0.1 (compatibility 1.0.0) <3F0ED200-741B-4E27-B89F-634B131F5E9E> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libvDSP.dylib
0x91df9000 - 0x91e03fe7  com.apple.audio.SoundManager 3.9.3 (3.9.3) <5F494955-7290-2D91-DA94-44B590191771> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/CarbonSound.framework/Versions/A/CarbonSound
0x93b95000 - 0x93b99ff7  libGFXShared.dylib ??? (???) <09540618-2ED1-72C4-61CB-938B35927568> /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGFXShared.dylib
0x93c05000 - 0x93c15ff7  libsasl2.2.dylib 3.15.0 (compatibility 3.0.0) <C8744EA3-0AB7-CD03-E639-C4F2B910BE5D> /usr/lib/libsasl2.2.dylib
0x93db4000 - 0x93db4ff7  com.apple.Carbon 150 (152) <9252D5F2-462D-2C15-80F3-109644D6F704> /System/Library/Frameworks/Carbon.framework/Versions/A/Carbon
0x93db5000 - 0x93dd6fe7  com.apple.opencl 12.3.6 (12.3.6) <B4104B80-1CB3-191C-AFD3-697843C6BCFF> /System/Library/Frameworks/OpenCL.framework/Versions/A/OpenCL
0x93dd7000 - 0x93df6ff7  com.apple.CoreVideo 1.6.2 (45.6) <EB53CAA4-5EE2-C356-A954-5775F7DDD493> /System/Library/Frameworks/CoreVideo.framework/Versions/A/CoreVideo
0x93fac000 - 0x9416efeb  com.apple.ImageIO.framework 3.0.5 (3.0.5) <051752C3-8C25-CF4A-9BFB-C7B6D20E58E8> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/ImageIO
0x94272000 - 0x942b8ff7  libauto.dylib ??? (???) <29422A70-87CF-10E2-CE59-FEE1234CFAAE> /usr/lib/libauto.dylib
0x942bb000 - 0x942c8ff7  com.apple.NetFS 3.2.2 (3.2.2) <DDC9C397-C35F-8D7A-BB24-3D1B42FA5FAB> /System/Library/Frameworks/NetFS.framework/Versions/A/NetFS
0x942c9000 - 0x94326ff7  com.apple.framework.IOKit 2.0 (???) <3DABAB9C-4949-F441-B077-0498F8E47A35> /System/Library/Frameworks/IOKit.framework/Versions/A/IOKit
0x952c6000 - 0x95372fe7  com.apple.CFNetwork 454.12.4 (454.12.4) <DEDCD006-389F-967F-3405-EDF541F406D7> /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/CFNetwork.framework/Versions/A/CFNetwork
0x95410000 - 0x9541eff7  com.apple.opengl 1.6.14 (1.6.14) <82622F67-E032-0BF6-A78D-50B346E8D0FD> /System/Library/Frameworks/OpenGL.framework/Versions/A/OpenGL
0x95576000 - 0x9558bfff  com.apple.ImageCapture 6.1 (6.1) <B909459A-EAC9-A7C8-F2A9-CD757CDB59E8> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/ImageCapture.framework/Versions/A/ImageCapture
0x959de000 - 0x95a48fe7  libstdc++.6.dylib 7.9.0 (compatibility 7.0.0) <411D87F4-B7E1-44EB-F201-F8B4F9227213> /usr/lib/libstdc++.6.dylib
0x95ac7000 - 0x95de7ff3  com.apple.CoreServices.CarbonCore 861.39 (861.39) <5C59805C-AF39-9010-B8B5-D673C9C38538> /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/CarbonCore.framework/Versions/A/CarbonCore
0x95de8000 - 0x95e00ff7  com.apple.CFOpenDirectory 10.6 (10.6) <F9AFC571-3539-6B46-ABF9-46DA2B608819> /System/Library/Frameworks/OpenDirectory.framework/Versions/A/Frameworks/CFOpenDirectory.framework/Versions/A/CFOpenDirectory
0x95e1f000 - 0x95e9ffeb  com.apple.SearchKit 1.3.0 (1.3.0) <9E18AEA5-F4B4-8BE5-EEA9-818FC4F46FD9> /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/SearchKit.framework/Versions/A/SearchKit
0x963a2000 - 0x963a8fff  com.apple.CommonPanels 1.2.4 (91) <2438AF5D-067B-B9FD-1248-2C9987F360BA> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/CommonPanels.framework/Versions/A/CommonPanels
0x963a9000 - 0x963b3ffb  com.apple.speech.recognition.framework 3.11.1 (3.11.1) <EC0E69C8-A121-70E8-43CF-E6FC4C7779EC> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/SpeechRecognition.framework/Versions/A/SpeechRecognition
0x963b4000 - 0x963bdff7  com.apple.DiskArbitration 2.3 (2.3) <E9C40767-DA6A-6CCB-8B00-2D5706753000> /System/Library/Frameworks/DiskArbitration.framework/Versions/A/DiskArbitration
0x963be000 - 0x963d9ff7  libPng.dylib ??? (???) <05445692-8AF7-CAB6-EBF5-1F7B3A906CCB> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources/libPng.dylib
0x96491000 - 0x964d5ff3  com.apple.coreui 2 (114) <29F8F1A4-1C96-6A0F-4CC2-9B85CF83209F> /System/Library/PrivateFrameworks/CoreUI.framework/Versions/A/CoreUI
0x964d6000 - 0x964f8fef  com.apple.DirectoryService.Framework 3.6 (621.11) <CA979EAC-9537-43B6-CD69-C144ACB75E09> /System/Library/Frameworks/DirectoryService.framework/Versions/A/DirectoryService
0x964f9000 - 0x9654cff7  com.apple.HIServices 1.8.3 (???) <1D3C4587-6318-C339-BD0F-1988F246BE2E> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/HIServices.framework/Versions/A/HIServices
0x9654d000 - 0x96561ffb  com.apple.speech.synthesis.framework 3.10.35 (3.10.35) <57DD5458-4F24-DA7D-0927-C3321A65D743> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/SpeechSynthesis.framework/Versions/A/SpeechSynthesis
0x96776000 - 0x96777ff7  com.apple.TrustEvaluationAgent 1.1 (1) <6C04C4C5-667E-2EBE-EB96-5B67BD4B2185> /System/Library/PrivateFrameworks/TrustEvaluationAgent.framework/Versions/A/TrustEvaluationAgent
0x96778000 - 0x96834fff  com.apple.ColorSync 4.6.8 (4.6.8) <920DD017-8B41-7334-E554-A85DB99EBD5A> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ColorSync.framework/Versions/A/ColorSync
0x96835000 - 0x96837ff7  libRadiance.dylib ??? (???) <41E5C5F4-A4C6-0416-08D0-422C88088558> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources/libRadiance.dylib
0x96838000 - 0x96838ff7  com.apple.vecLib 3.6 (vecLib 3.6) <7362077A-890F-3AEF-A8AB-22247B10E106> /System/Library/Frameworks/vecLib.framework/Versions/A/vecLib
0x96839000 - 0x96839ff7  liblangid.dylib ??? (???) <B99607FC-5646-32C8-2C16-AFB5EA9097C2> /usr/lib/liblangid.dylib
0x968fc000 - 0x9695dfe7  com.apple.CoreText 151.12 (???) <98F53C15-1D29-A2B3-0717-5A26A2699163> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/CoreText.framework/Versions/A/CoreText
0x9695e000 - 0x96a6afe7  libGLProgrammability.dylib ??? (???) <6167CEB0-D8D6-C4D9-DD74-49755ADB540F> /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGLProgrammability.dylib
0x96a6b000 - 0x96aacff7  libRIP.A.dylib 545.0.0 (compatibility 64.0.0) <80998F66-0AD7-AD12-B9AF-3E8D2CE6DE05> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/CoreGraphics.framework/Versions/A/Resources/libRIP.A.dylib
0x96aad000 - 0x97390ff7  com.apple.AppKit 6.6.8 (1038.36) <A353465E-CFC9-CB75-949D-786F6F7732F6> /System/Library/Frameworks/AppKit.framework/Versions/C/AppKit
0x97391000 - 0x97396ff7  com.apple.OpenDirectory 10.6 (10.6) <C1B46982-7D3B-3CC4-3BC2-3E4B595F0231> /System/Library/Frameworks/OpenDirectory.framework/Versions/A/OpenDirectory
0x97397000 - 0x97419ffb  SecurityFoundation ??? (???) <3670AE8B-06DA-C447-EB14-79423DB9C474> /System/Library/Frameworks/SecurityFoundation.framework/Versions/A/SecurityFoundation
0x9741a000 - 0x974f4fff  com.apple.DesktopServices 1.5.11 (1.5.11) <800F2040-9211-81A7-B438-7712BF51DEE3> /System/Library/PrivateFrameworks/DesktopServicesPriv.framework/Versions/A/DesktopServicesPriv
0x97588000 - 0x9770afe7  libicucore.A.dylib 40.0.0 (compatibility 1.0.0) <D5980817-6D19-9636-51C3-E82BAE26776B> /usr/lib/libicucore.A.dylib
0x9770b000 - 0x97748ff7  com.apple.SystemConfiguration 1.10.8 (1.10.2) <50E4D49B-4F61-446F-1C21-1B2BA814713D> /System/Library/Frameworks/SystemConfiguration.framework/Versions/A/SystemConfiguration
0x977bb000 - 0x977bbff7  com.apple.Accelerate 1.6 (Accelerate 1.6) <BC501C9F-7C20-961A-B135-0A457667D03C> /System/Library/Frameworks/Accelerate.framework/Versions/A/Accelerate
0x977dc000 - 0x977e0ff7  IOSurface ??? (???) <D849E1A5-6B0C-2A05-2765-850EC39BA2FF> /System/Library/Frameworks/IOSurface.framework/Versions/A/IOSurface
0x977e1000 - 0x97824ff7  libGLU.dylib ??? (???) <6CC3CE6A-7024-C685-EADA-7F9DC27128E2> /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGLU.dylib
0x97825000 - 0x97b49fef  com.apple.HIToolbox 1.6.5 (???) <21164164-41CE-61DE-C567-32E89755CB34> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/HIToolbox.framework/Versions/A/HIToolbox
0x97b8b000 - 0x97b96ff7  libGL.dylib ??? (???) <3E34468F-E9A7-8EFB-FF66-5204BD5B4E21> /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib
0x97be7000 - 0x97ffdff7  libBLAS.dylib 219.0.0 (compatibility 1.0.0) <C4FB303A-DB4D-F9E8-181C-129585E59603> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
0x982d6000 - 0x982d6ff7  com.apple.ApplicationServices 38 (38) <8012B504-3D83-BFBB-DA65-065E061CFE03> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/ApplicationServices
0x984d9000 - 0x984dcfe7  libmathCommon.A.dylib 315.0.0 (compatibility 1.0.0) <1622A54F-1A98-2CBE-B6A4-2122981A500E> /usr/lib/system/libmathCommon.A.dylib
0x984dd000 - 0x9850eff7  libGLImage.dylib ??? (???) <D18E2E76-DBF4-6930-039A-F66CA0D120B3> /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGLImage.dylib
0x9850f000 - 0x9855cfeb  com.apple.DirectoryService.PasswordServerFramework 6.1 (6.1) <136BFA48-D456-B677-3B5D-40A6946C3A09> /System/Library/PrivateFrameworks/PasswordServer.framework/Versions/A/PasswordServer
0x9855d000 - 0x9856fff7  com.apple.MultitouchSupport.framework 207.11 (207.11) <6FF4F2D6-B8CD-AE13-56CB-17437EE5B741> /System/Library/PrivateFrameworks/MultitouchSupport.framework/Versions/A/MultitouchSupport
0x989ee000 - 0x98a89fe7  com.apple.ApplicationServices.ATS 275.19 (???) <2E83B3E9-AF39-36FC-5D05-CC1E952098AB> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ATS.framework/Versions/A/ATS
0x98a8a000 - 0x98acefe7  com.apple.Metadata 10.6.3 (507.15) <74F05E64-2A68-BA10-CCD4-128D164E5A0F> /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/Metadata.framework/Versions/A/Metadata
0x98acf000 - 0x98acfff7  com.apple.CoreServices 44 (44) <51CFA89A-33DB-90ED-26A8-67D461718A4A> /System/Library/Frameworks/CoreServices.framework/Versions/A/CoreServices
0x98ad0000 - 0x98ae4fe7  libbsm.0.dylib ??? (???) <14CB053A-7C47-96DA-E415-0906BA1B78C9> /usr/lib/libbsm.0.dylib
0x98b96000 - 0x98b99ff7  libCoreVMClient.dylib ??? (???) <37F56237-4ABA-E5B5-968D-70FFE357E8E0> /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libCoreVMClient.dylib
0x98b9a000 - 0x98e0bfef  com.apple.Foundation 6.6.8 (751.63) <69B3441C-B196-F2AD-07F8-D8DD24E4CD8C> /System/Library/Frameworks/Foundation.framework/Versions/C/Foundation
0x98e0c000 - 0x99177ff7  com.apple.QuartzCore 1.6.3 (227.37) <E323A5CC-499E-CA9E-9BC3-537231449CAA> /System/Library/Frameworks/QuartzCore.framework/Versions/A/QuartzCore
0x99183000 - 0x99263fe7  com.apple.vImage 4.1 (4.1) <D029C515-08E1-93A6-3705-DD062A3A672C> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vImage.framework/Versions/A/vImage
0x99273000 - 0x9932bfeb  libFontParser.dylib ??? (???) <D2D0C922-5ED1-3AE9-6F99-707C74DF3E62> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ATS.framework/Versions/A/Resources/libFontParser.dylib
0x9932c000 - 0x9932eff7  com.apple.securityhi 4.0 (36638) <38D36D4D-C798-6ACE-5FA8-5C001993AD6B> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/SecurityHI.framework/Versions/A/SecurityHI
0x9932f000 - 0x9937fff7  com.apple.framework.familycontrols 2.0.2 (2020) <C96C8A99-A40C-8B9C-1FBA-A0F46AC92F17> /System/Library/PrivateFrameworks/FamilyControls.framework/Versions/A/FamilyControls
0x99508000 - 0x99645fe7  com.apple.audio.toolbox.AudioToolbox 1.6.7 (1.6.7) <423BDE4D-5082-B6CA-BB2C-E22A037235A4> /System/Library/Frameworks/AudioToolbox.framework/Versions/A/AudioToolbox
0x998ed000 - 0x998f3fe7  com.apple.CommerceCore 1.0 (9.1) <521D067B-3BDA-D04E-E1FA-CFA526C87EB5> /System/Library/PrivateFrameworks/CommerceKit.framework/Versions/A/Frameworks/CommerceCore.framework/Versions/A/CommerceCore
0x998f4000 - 0x99927ff7  com.apple.AE 496.5 (496.5) <BF9673D5-2419-7120-26A3-83D264C75222> /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/AE.framework/Versions/A/AE
0x99928000 - 0x99929ff7  com.apple.audio.units.AudioUnit 1.6.7 (1.6.7) <93EC71F1-4D4E-F456-8EFE-32E7EFD7A064> /System/Library/Frameworks/AudioUnit.framework/Versions/A/AudioUnit
0x9992a000 - 0x99950ffb  com.apple.DictionaryServices 1.1.2 (1.1.2) <43E1D565-6E01-3681-F2E5-72AE4C3A097A> /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/DictionaryServices.framework/Versions/A/DictionaryServices
0x99951000 - 0x99958ff3  com.apple.print.framework.Print 6.1 (237.1) <F5AAE53D-5530-9004-A9E3-2C1690C5328E> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/Print.framework/Versions/A/Print
0x99959000 - 0x999bdffb  com.apple.htmlrendering 72 (1.1.4) <4D451A35-FAB6-1288-71F6-F24A4B6E2371> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/HTMLRendering.framework/Versions/A/HTMLRendering
0x999be000 - 0x999beff7  com.apple.Cocoa 6.6 (???) <EA27B428-5904-B00B-397A-185588698BCC> /System/Library/Frameworks/Cocoa.framework/Versions/A/Cocoa
0x999bf000 - 0x999e3ff7  libJPEG.dylib ??? (???) <7EBC924F-B2EE-68B0-4EA0-F99EF54F0306> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources/libJPEG.dylib
0x99a53000 - 0x99a61fe7  libz.1.dylib 1.2.3 (compatibility 1.0.0) <3CE8AA79-F077-F1B0-A039-9103A4A02E92> /usr/lib/libz.1.dylib
0x99a72000 - 0x99b20ff3  com.apple.ink.framework 1.3.3 (107) <57B54F6F-CE35-D546-C7EC-DBC5FDC79938> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/Ink.framework/Versions/A/Ink
0x99b21000 - 0x99d87ff7  com.apple.security 6.1.2 (55002) <A476227B-409D-A457-7D4D-A631A0B4AFDB> /System/Library/Frameworks/Security.framework/Versions/A/Security
0x99eeb000 - 0x99eeeff7  libCGXType.A.dylib 545.0.0 (compatibility 64.0.0) <4D766435-EB76-C384-0127-1D20ACD74076> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/CoreGraphics.framework/Versions/A/Resources/libCGXType.A.dylib
0x99fa9000 - 0x9a150ff7  libSystem.B.dylib 125.2.11 (compatibility 1.0.0) <2DCD13E3-1BD1-6F25-119A-3863A3848B90> /usr/lib/libSystem.B.dylib
0x9a151000 - 0x9a252fe7  libxml2.2.dylib 10.3.0 (compatibility 10.0.0) <C75F921C-F027-6372-A0A1-EDB8A6234331> /usr/lib/libxml2.2.dylib
0x9a253000 - 0x9a28effb  libFontRegistry.dylib ??? (???) <19ED5DE0-D3AF-B229-9193-35D58FE377E5> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ATS.framework/Versions/A/Resources/libFontRegistry.dylib
0x9a28f000 - 0x9a2d8fe7  libTIFF.dylib ??? (???) <4A3EF156-D4FE-95E2-FA05-7BD76FF27CEC> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources/libTIFF.dylib
0x9a4e8000 - 0x9a508fe7  libresolv.9.dylib 41.1.0 (compatibility 1.0.0) <8C2B5FA8-2469-21C7-D297-F95A0FFE5F19> /usr/lib/libresolv.9.dylib
0x9a509000 - 0x9a5b6fe7  libobjc.A.dylib 227.0.0 (compatibility 1.0.0) <9F8413A6-736D-37D9-8EB3-7986D4699957> /usr/lib/libobjc.A.dylib
0x9a5b7000 - 0x9a5c2ff7  libCSync.A.dylib 545.0.0 (compatibility 64.0.0) <287DECA3-7821-32B6-724D-AE03A9A350F9> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/CoreGraphics.framework/Versions/A/Resources/libCSync.A.dylib
0x9a5c3000 - 0x9a5c3ff7  com.apple.Accelerate.vecLib 3.6 (vecLib 3.6) <1DEC639C-173D-F808-DE0D-4070CC6F5BC7> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/vecLib
0x9a772000 - 0x9a77eff7  libkxld.dylib ??? (???) <9A441C48-2D18-E716-5F38-CBEAE6A0BB3E> /usr/lib/system/libkxld.dylib
0x9a77f000 - 0x9a7b2fff  libTrueTypeScaler.dylib ??? (???) <8ADB7D19-413E-4499-C874-13C383F97685> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ATS.framework/Versions/A/Resources/libTrueTypeScaler.dylib
0x9a7b3000 - 0x9abe8ff7  libLAPACK.dylib 219.0.0 (compatibility 1.0.0) <5E2D2283-57DE-9A49-1DB0-CD027FEFA6C2> /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libLAPACK.dylib
0xffff0000 - 0xffff1fff  libSystem.B.dylib ??? (???) <2DCD13E3-1BD1-6F25-119A-3863A3848B90> /usr/lib/libSystem.B.dylib

Model: iMac9,1, BootROM IM91.008D.B08, 2 processors, Intel Core 2 Duo, 3.06 GHz, 8 GB, SMC 1.45f0
Graphics: ATI Radeon HD 4850, ATI Radeon HD 4850, PCIe, 512 MB
Memory Module: global_name
AirPort: spairport_wireless_card_type_airport_extreme (0x14E4, 0x8E), Broadcom BCM43xx 1.0 (5.10.131.42.4)
Bluetooth: Version 2.4.5f3, 2 service, 12 devices, 1 incoming serial ports
Network Service: Ethernet, Ethernet, en0
Serial ATA Device: ST31000342ASQ, 931.51 GB
Serial ATA Device: OPTIARC DVD RW AD-5670S
USB Device: Built-in iSight, 0x05ac  (Apple Inc.), 0x8502, 0x24400000 / 3
USB Device: USB2.0 Hub, 0x05e3  (Genesys Logic, Inc.), 0x0608, 0x24300000 / 2
USB Device: LaCie Desktop Hard Drive, 0x059f  (LaCie), 0x1010, 0x24320000 / 4
USB Device: Keyboard Hub, 0x05ac  (Apple Inc.), 0x1006, 0x26400000 / 2
USB Device: Apple Keyboard, 0x05ac  (Apple Inc.), 0x0220, 0x26420000 / 3
USB Device: IR Receiver, 0x05ac  (Apple Inc.), 0x8242, 0x04500000 / 3
USB Device: Microsoft Wireless Optical Mouse® 1.00, 0x045e  (Microsoft Corporation), 0x00e1, 0x04100000 / 2
USB Device: PTK-640, 0x056a  (WACOM Co., Ltd.), 0x00b9, 0x06200000 / 3
USB Device: BRCM2046 Hub, 0x0a5c  (Broadcom Corp.), 0x4500, 0x06100000 / 2
USB Device: Bluetooth USB Host Controller, 0x05ac  (Apple Inc.), 0x8215, 0x06110000 / 6
If you try the game you will notice I'm using a narrow rectangle for the player character's collision shape which doesn't cover the sprite. I intend to have the rectangle and two circles covering the sprite to give it a capsule shape (though there will still be space at the top of the sprite so that it may overlap with some walls to give perspective). Using a single circle works fine. Using two circles causes a bus error though.

P.S. You will have to search for a key a bit.
Attachments
shootron.love
(125.31 KiB) Downloaded 73 times
User avatar
kikito
Inner party member
Posts: 3153
Joined: Sat Oct 03, 2009 5:22 pm
Location: Madrid, Spain
Contact:

Re: Bus error when colliding with sensor

Post by kikito »

If I remember correctly, removing shapes during collisions tends to mean trouble, at least in 0.7.2. I don't know its state in 0.8.x .

The workaround seemed to involve "marking" the removed shape with a boolean or storing it in a "to-be-deleted" table, making it completely un-touchable (for example with masks or groups) so that it didn't interact with any other object on that frame and then removing it outside of the world.update() call. But this is from the top of my head, I could be wrong.
When I write def I mean function.
User avatar
AaronWizard
Citizen
Posts: 68
Joined: Sun Nov 06, 2011 2:45 pm
Location: Canada

Re: Bus error when colliding with sensor

Post by AaronWizard »

I've tried adding bodies and shapes meant to be deleted to a list that I can clear later, instead of destroying the bodies and shapes immediately.

This gets rid of the crash, but I have discovered that the callbacks for player/key collision and player/door collision seem to be getting called twice. And it doesn't seem to be the case of it calling (key, actor) then (actor, key); it's always [(key, actor), (key, actor)] and [(door, actor), (door, actor)]. This has the side effect of giving me two keys of the same colour whenever I pick up one.
double_keys.png
double_keys.png (40.59 KiB) Viewed 2067 times
Attachments
shootron.love
At least the crashes are gone
(125.85 KiB) Downloaded 64 times
meoiswa
Prole
Posts: 48
Joined: Wed Mar 14, 2012 8:13 pm
Location: Venezuela

Re: Bus error when colliding with sensor

Post by meoiswa »

AFAIK this is completelly normal, those triggers always return the shapes in a "random, but orderly" manner. What I mean is that when two shapes collide, you get the hook called for shapes a and b without knowing which is which, however, every time this two shapes collide, the hook is called in the same order.

For your problem of having two keys, try this:

Set the shape's "data" to point to the object that owns this shape (For example, the player's shape has the data field pointing to the player). This way, when two shapes collide you can always access their data, and through it the object, and then maybe read the "will delete on next update" variable which you set to "true" to avoid crashing when deleting a colliding shape. If that variable is false, then give the player the key (or whatever) and mark the object for deletion, else, do nothing.

You can also avoid the crash when objects are colliding by setting the shape's "mask" to all possible values, and then deleting it on the very next frame.

TL;DR: set the shapes data to point to the parent object, then do magic.
Write the ö of Löve with Alt+numPad(148) or Alt+numPad(153)
User avatar
AaronWizard
Citizen
Posts: 68
Joined: Sun Nov 06, 2011 2:45 pm
Location: Canada

Re: Bus error when colliding with sensor

Post by AaronWizard »

meoiswa wrote:AFAIK this is completelly normal, those triggers always return the shapes in a "random, but orderly" manner. What I mean is that when two shapes collide, you get the hook called for shapes a and b without knowing which is which, however, every time this two shapes collide, the hook is called in the same order.
OK, though this doesn't explain why the callback gets called twice when the two shapes collide.
meoiswa
Prole
Posts: 48
Joined: Wed Mar 14, 2012 8:13 pm
Location: Venezuela

Re: Bus error when colliding with sensor

Post by meoiswa »

There's a callback for "a colliding with b" and "b colliding with a". There's also no reliable way to predict which shape will be "a" and which will be "b", that's why I suggest adding a reference to the object in the shape's data, so you can do conditionals for testing which is what .

... I just realized i'm talking about Box2D and not Hardon. Might still be the same issue.

For example, in Box2d::

Code: Select all

function add(a, b, coll)
        --If player and sensor shape for the base collide, you can dock
	if (a.class=="player" and b.class=="base") then
        -- If we do something like: 
        --    if (a.class == "player" and b.class=="base") or (a.class =="base" and b.class == "player") then
        --    We end up running the code twice because of the collision "between a and b" and "between b and a"
		player.canDock = player.canDock+1
		player.dockID = b.id
	end
        --if player and debris collide, destroy debris safely, by masking it entirely and then deleting the object that holds it.
	if (a.class=="player" and b.class=="debris") then
		for k,v in pairs(game.objects) do
			if v==b.object then
				--Remove the shape's collisions so that they don't collide until the garbace collector
				--gets rid of them
				b.object.shape:setMask(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15, 16)		
				--Remove the object from the game's physics pool
				table.remove(game.objects,k)
			end
		end
	end
end
Write the ö of Löve with Alt+numPad(148) or Alt+numPad(153)
Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 148 guests