- Home /
Application crashes
Hey,
Strangely my application crashes when loading an additiv level. I only get the error when the application comes from the app store not when i just build it and run it on my device. I attached the crash log but I am not really able to read it myself. Would be great if somebody has a solution
Thread 3 Crashed: 0 libsystem_kernel.dylib 0x3bd0e1fc __pthread_kill + 8 1 libsystem_pthread.dylib 0x3bd75a4f pthread_kill + 55 2 libsystem_c.dylib 0x3bcbf029 abort + 73 3 myApp 0x01b03cf0 mono_handle_native_sigsegv + 312 4 myApp 0x01b20a28 sigabrt_signal_handler + 104 5 libsystem_platform.dylib 0x3bd70721 sigtramp + 41 6 libsystem_pthread.dylib 0x3bd75a4f pthread_kill + 55 7 libsystem_c.dylib 0x3bcbf029 abort + 73 8 libsystem_pthread.dylib 0x3bd768eb pthread_abort + 27 9 libsystem_pthread.dylib 0x3bd76907 pthread_abort_reason + 15 10 libsystem_pthread.dylib 0x3bd744df pthread_exit + 63 11 myApp 0x01be4830 thread_exit + 28 12 myApp 0x01be4858 ExitThread + 36 13 myApp 0x01bc7274 mono_thread_exit + 76 14 myApp 0x01af08e4 mono_thread_abort + 56 15 myApp 0x01af0978 mono_thread_abort_dummy + 36 16 myApp 0x01b03114 mono_handle_exception_internal + 1100 17 myApp 0x01b03918 mono_handle_exception + 64 18 myApp 0x01b1fd04 mono_arm_throw_exception + 184 19 myApp 0x014254cc throw_exception + 44 20 myApp 0x011a086c m_System_Reflection_MonoCMethod_Invoke_System_Reflection_BindingFlags_System_Reflection_Binder_objectSystem_Globalization_CultureInfo + 96 21 myApp 0x01190148 m_System_Reflection_ConstructorInfo_Invoke_object + 108 22 myApp 0x00bead28 m_U3DXT_iOS_Native_Internals_ObjectCacheCreate_System_Type_string + 296 23 myApp 0x00e34f34 m_U3DXT_iOS_Native_Accounts_ACAccountStorerequestAccessToAccountsWithType_options_completioncompletion_callback_System_Delegate_System_Collections_Generic_Dictionary_2_string_object + 348 24 myApp 0x00be9aec m_U3DXT_iOS_Native_InternalsCallbackCacheCallback_string_string + 456 25 myApp 0x00c3e15c m_wrapper_native_to_managed_U3DXT_iOS_Native_InternalsCallbackCache_Callback_intptr_intptr + 100 26 myApp 0x01c99d33 UP_callbackEvent (CallbackCache.m:63) 27 libdispatch.dylib 0x3bc430c1 _dispatch_call_block_and_release + 9 28 libdispatch.dylib 0x3bc474b3 _dispatch_async_redirect_invoke + 107 29 libdispatch.dylib 0x3bc487d5 _dispatch_root_queue_drain + 221 30 libdispatch.dylib 0x3bc489c1 _dispatch_worker_thread2 + 53 31 libsystem_pthread.dylib 0x3bd72dfd _pthread_wqthread + 297 32 libsystem_pthread.dylib 0x3bd72cc0 start_wqthread + 4
Answer by u3dxt · Jan 15, 2014 at 06:22 PM
Hi Fred'sIphone, what version of U3DXT are you using? Also, it seems that you are using the Social module's Twitter or Facebook class. Can you paste some code of how you are using them? Thanks.
Hi, I have simmilar issue. $$anonymous$$y app works well on my iphone and ipad, but it got rejected from app store with reason "crashing on ipad (while launching)". I use Soomla and "iOS Post to Twitter/Facebook/Activity/$$anonymous$$ail" asset, but i guess their code is invoked somewhat later... Please post here if you have found a solution, thanks.
Answer by fred_gds · Jan 15, 2014 at 08:59 PM
Hey,
I am using version 1.6.3.0.
Yes I use the social module but not in the scene in which the game crashes. There I use the webview and the mediaplayer.
So my social code is:
function Share() { var obj : Object[] = new Object[2];
var toPost : String;
toPost = "some kind of string.";
obj[0] = toPost as Object;
obj[1] = "some kind of link" as Object;
//obj[2] = logo as Object;
var str : String[] = new String[2];
str[0] = UIActivity.TypeAssignToContact;
str[1] = UIActivity.TypeCopyToPasteboard;
SocialXT.Share(obj, str);
}
And my web view code is:
public void CreateWebView() { UIView parentView = null; if ((UIApplication.deviceRootViewController != null) && (UIApplication.deviceRootViewController.view != null)) parentView = UIApplication.deviceRootViewController.view; else parentView = UIApplication.SharedApplication().keyWindow;
if ( fullScreen )
_webview = new UIWebView(parentView.bounds);
else
_webview = new UIWebView(locationAndSize);
parentView.AddSubview(_webview);
this.setURL(homeURL);
}
UIWebView getWebView()
{
return _webview;
}
void Update()
{
if(!hilfeAssigned)
{
if(Application.loadedLevel == 0)
{
hilfe = GameObject.Find("mission1").guiTexture;
hilfeAssigned = true;
hText = hilfe.gameObject.transform.FindChild("text").guiText;
}
if(Application.loadedLevel == 2)
{
hilfe = GameObject.Find("mission2").guiTexture;
hilfeAssigned = true;
hText = hilfe.gameObject.transform.FindChild("text").guiText;
}
}else
{
if(_webview != null)
{
if(transform.position.y == 1 && transform.position.y != oldPos)
{
_webview.hidden = false;
oldPos = transform.position.y;
}
if(transform.position.y == 0 && transform.position.y != oldPos)
{
_webview.hidden = true;
oldPos = transform.position.y;
}
}
if(IButton was pressed)
{
if(Application.loadedLevel == 2)
{
if(Time.timeScale == 0)
{
CreateWebView();
}
}else
{
CreateWebView();
}
}
}
}
..........
NSURLRequest _request = null; NSURL _url = null; public void setURL(string url) { lock(_webview){ _url = new NSURL(url); _request = new NSURLRequest( _url ); _webview.LoadRequest(_request); } }
and my media player is :
void Start ()
{
play.gameObject.SetActive(false);
if ( !CoreXT.IsDevice )
{
return;
}
musicPlayerController = new MPMusicPlayerController();
// whenever the now playing item changes, just play it
musicPlayerController.NowPlayingItemDidChange += delegate(object sender, U3DXT.iOS.Native.Foundation.NSNotificationEventArgs e)
{
musicPlayerController.Play();
};
MPMediaQuery query = new MPMediaQuery();
object[] items = query.items;
mediaItem = (MPMediaItem)items[Random.Range(0, items.Length)]; // randomly choose one to play
if ( mediaItem != null )
{
musicPlayerController.nowPlayingItem = mediaItem;
}
if(musicOn == 2)
{
musicPlayerController.Pause();
playing = false;
}else
{
playing = true;
}
}
void Update ()
{
if(Input.touchCount > 0 && Input.GetTouch(0).phase == TouchPhase.Began)
{
Vector2 hit = Input.GetTouch(0).position;
if(!playing)
{
if(play.HitTest(hit))
{
musicPlayerController.Play();
playing = true;
pause.gameObject.SetActive(true);
play.gameObject.SetActive(false);
}
}else
{
if(pause.HitTest(hit))
{
musicPlayerController.Pause();
playing = false;
play.gameObject.SetActive(true);
pause.gameObject.SetActive(false);
}
}
if(next.HitTest(hit))
{
MPMediaQuery query = new MPMediaQuery();
object[] items = query.items;
mediaItem = (MPMediaItem)items[Random.Range(0, items.Length)]; // randomly choose one to play
if ( mediaItem != null )
{
musicPlayerController.nowPlayingItem = mediaItem;
}
}
}
}
so that's all i use. well i have imported all the stuff from you package in my project as I plan on using other content in future. And I kind of don't have the comment button on here so I can't answer a second time here, except if somebody makes this post a comment
We don't see anything wrong with those uses. However, the crash call stack shows a callback to Twitter's or Facebook's Init(). If you have included all the stuff from our package, but you are not using them now, you can safely delete the Assets/U3DXT/Examples folder. And after that, maybe do a search in your code for "Twitter" and "Facebook" to see if you are using them anywhere.
Your answer
Follow this Question
Related Questions
Terminated due to memory issue at start - in Xcode 7 running iOS 2 Answers
Several Memory Optimization Questions 0 Answers
iOS build of game crashes on splash screen after a few days 3 Answers
WWW IOS Crash 0 Answers
[U3DXT] Bug? SocialXT.PostCompleted called with completed=true even if posting was unsuccessful 1 Answer