Revision: 2779
          http://rigsofrods.svn.sourceforge.net/rigsofrods/?rev=2779&view=rev
Author:   rorthomas
Date:     2012-06-05 11:39:03 +0000 (Tue, 05 Jun 2012)
Log Message:
-----------
configurator unpacking skeleton zip also when running from the sources

Modified Paths:
--------------
    trunk/source/configurator/Configurator.cpp

Modified: trunk/source/configurator/Configurator.cpp
===================================================================
--- trunk/source/configurator/Configurator.cpp  2012-06-05 10:52:11 UTC (rev 
2778)
+++ trunk/source/configurator/Configurator.cpp  2012-06-05 11:39:03 UTC (rev 
2779)
@@ -719,8 +719,18 @@
 
                if(!wxFileName::FileExists(skeletonZipFile))
                {
+                       // try the dev dir as well
+                       skeletonZip = wxFileName(ProgramPath, wxEmptyString);
+                       skeletonZip.RemoveLastDir();
+                       skeletonZip.AppendDir(wxT("resources"));
+                       skeletonZip.SetFullName(wxT("skeleton.zip"));
+                       skeletonZipFile = skeletonZip.GetFullPath();
+               }
+
+               if(!wxFileName::FileExists(skeletonZipFile))
+               {
                        // tell the user
-                       wxString warning = wxString::Format(_("Rigs of Rods 
User directory missing:\n%s\n\nit could not be created since skeleton.zip was 
not found"), UserPath.c_str());
+                       wxString warning = wxString::Format(_("Rigs of Rods 
User directory missing:\n%s\n\nit could not be created since skeleton.zip was 
not found in\n %s"), UserPath.c_str(), skeletonZipFile.c_str());
                        wxString caption = _("error upon loading RoR user 
directory");
                        wxMessageDialog *w = new wxMessageDialog(NULL, warning, 
caption, wxOK|wxICON_ERROR|wxSTAY_ON_TOP, wxDefaultPosition);
                        w->ShowModal();

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Rigsofrods-devel mailing list
Rigsofrods-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rigsofrods-devel

Reply via email to