Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by Nexonity · Aug 06, 2013 at 05:05 PM · editorstandalonezip

Working in the editor but not standalone?

Hey there, I´m using a plugin to unity called DotNetZip (Ionic.Zip.dll) wich allows me to decompress .zip files in C#. Everything is working just as expected in the editor but when i build it to standalone it freezes at the line 54, where the decompressing begins. I´m running on Windows.

 using UnityEngine;
 using System.Collections;
 using System.Diagnostics;
 using System.Net;
 using System.IO;
 using Ionic.Zip;
 
 public class Updater2 : MonoBehaviour {
 
 
     public GUIText info;
     
     void Start ()
     {
         StartCoroutine(Wait());
     }
     
     
     IEnumerator Wait() 
     {
         string latest = "http://www.nexonity.com/data/check.txt";
         WWW latest2 = new WWW(latest);
         yield return latest2;
         
         if (File.Exists(@"C:\Windows\Temp\FinalWorldWindows\version.txt"))
         {
             string current =  System.IO.File.ReadAllText(@"C:\Windows\Temp\FinalWorldWindows\version.txt");
             
             if (latest2.text == current)
             {
                 StartCoroutine(Wait2());
             }
             else
             {
                 WebClient webClient = new WebClient();
                 webClient.DownloadFile("http://nexonity.com/data/FinalWorldWindows.zip", @"C:\Windows\Temp\FinalWorldWindows.zip");
                 Decompress();
             }
         }
         else
         {
             WebClient webClient = new WebClient();
             webClient.DownloadFile("http://nexonity.com/data/FinalWorldWindows.zip", @"C:\Windows\Temp\FinalWorldWindows.zip");
             Decompress();
         }
     }
         
     
     void Decompress()
     {
         string zipToUnpack = @"C:\Windows\Temp\FinalWorldWindows.zip";
         string unpackDirectory = @"C:\Windows\Temp";
         info.text = "Decompressing";
         using (ZipFile zip1 = ZipFile.Read(zipToUnpack))
         {
             foreach (ZipEntry e in zip1)
             {
                 info.text = "Decompressing 2";
                 e.Extract(unpackDirectory, ExtractExistingFileAction.OverwriteSilently);
                 info.text = "Decompressing done";
             }
         }
         
         StartCoroutine(Wait2());
     }
     
     IEnumerator Wait2()
     {
         yield return new WaitForSeconds(2);
         System.Diagnostics.Process.Start(@"C:\Windows\Temp\FinalWorldWindows\FinalWorld.exe");
         yield return new WaitForSeconds(2);
         Application.Quit();
     }
     
 }
 
Comment
Add comment · Show 1
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Veldars · Jun 01, 2015 at 09:47 AM 0
Share

Did you found a solution ?

2 Replies

· Add your reply
  • Sort: 
avatar image
0

Answer by sparkzbarca · Aug 06, 2013 at 05:13 PM

is the standalone build then running in administrator mode I'd be almost positive windows is not cool with you extracting stuff without administrative priv.

my guess is unity is running in admin and allowed to do that stuff adn the standalone isn't

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Nexonity · Aug 06, 2013 at 05:22 PM 0
Share

I tried to run it as ad$$anonymous$$ but i still got the same thing :/

avatar image
0

Answer by gull · Nov 18, 2014 at 06:33 AM

it is because some dependency dll files are missing from unity's build. Navigate to: C:Program Files (x86)/Unity/Editor/Data/Mono/lib/mono/unity and copy all of the I18N.dlls. This will fix any incompatability issues

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

17 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Standalone build doesn't create gameobjects properly 1 Answer

Low FPS in editor, but normal FPS in standalone 0 Answers

Works in the editor, but not when I publish it.. what's wrong..? 0 Answers

Different behavior between editor and standalone changing time step 0 Answers

Unity VR (XR) enable/disable VR on startup in Editor and as standalone. 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges