• 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 /
  • Help Room /
avatar image
0
Question by HackTheREALITY · Mar 05, 2017 at 02:35 PM · freezewhilefreezingwhile-loopwhile loop

While loop freeze

Unity freezes in this while loop: FireBall: using UnityEngine; using System.Collections; public class FireBall : MonoBehaviour { %|573926749_1|% %|-2048041834_2|% %|1978211612_3|% %|1179226318_4|% %|-476071733_5|% %|-892526441_6|% %|-1917508315_7|% void Update () { do %|1123891018_10|% %|1433030293_11|% %|-239679391_12|% %|-1433463061_13|% { %|1772615627_15|% %|-194981275_16|% %|1397317542_17|% } Magic: using UnityEngine; using System.Collections; public class Magic : MonoBehaviour { %|-92300221_18|% %|325405269_19|% %|1310312523_20|% void Start() { anim = GetComponent<Animator>(); %|1773566917_24|% %|46792965_25|% %|1044305088_26|% %|1690007293_27|% { %|-1015671306_29|% %|1142991838_30|% %|-186610250_31|% %|1593146160_32|% %|987449748_33|% %|1204561605_34|% %|835711649_35|% %|2109767193_36|% %|2024749496_37|% %|1012098576_38|% %|1389978564_39|% %|433787792_40|% { %|-860804713_42|% } %|-1601839631_44|% IEnumerator attack() { anim.SetTrigger("MagicAttack"); %|974319347_48|% %|1513188435_49|% %|-1295570364_50|% %|-1436183689_51|% %|-896386294_52|% %|-1611585242_53|% %|679778346_54|% %|-1965708210_55|% }

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 alexanderameye · Mar 05, 2017 at 03:18 PM 0
Share

You should provide us the code of that while loop.

0 Replies

· Add your reply
  • Sort: 

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.

Welcome to Unity Answers

The best place to ask and answer questions about development with Unity.

To help users navigate the site we have posted a site navigation guide.

If you are a new user to Unity Answers, check out our FAQ for more information.

Make sure to check out our Knowledge Base for commonly asked Unity questions.

If you are a moderator, see our Moderator Guidelines page.

We are making improvements to UA, see the list of changes.



Follow this Question

Answers Answers and Comments

93 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 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 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 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 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 avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

[Solved]Cant Find loop that freezes Unity 2 Answers

Why does this while loop freeze unity? 1 Answer

NEED HELP PLEASE: When i kill a one of the three limited "mobSpawned" the "while (true)" don't work and don't spawn a new object. Anyone have a solution for this. Thanks. 1 Answer

While loop causing Unity to hang up? 1 Answer

Why is this Do/While loop hanging Unity? 1 Answer

  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges