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 Cyanide · Mar 24, 2013 at 08:01 PM · guitimeenemieskill

Enemy kill counter and time limit.

I'm making a game about killing sentry turrets around the world, and there are a few things i'km not sure how to do...

-If you kill all 15 enemies, you advance to the end game level

-You have a GUI counter at the top of your screen that shows how many are dead, and how many there are in total I.E. 6/15 sentries.

-You have a 15 minute time limit and then your death animation plays

-when you die, 2 3d textures show up (restart and exit)

Thank you.

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 robertbu · Mar 24, 2013 at 08:10 PM 0
Share

Lot of separate question here that will take separate answers. I recommending editing this question down to a single question and posting the others as their own question. Taking a shot at writing your own script to solve the problem first will often get you quicker and more accurate answers.

1 Reply

· Add your reply
  • Sort: 
avatar image
0
Best Answer

Answer by Tim-A · Mar 24, 2013 at 08:29 PM

I can help you with the first two.

  1. You would have a 2 scripts,The first one would go on the enemy and have it send 1 death to the other script which counts it. Then you can have, if(enemiesDead == 15) Application.LoadLevel("End Of Game");

  2. Have a script that counts enemies death, and have it say, GUI.Label (Rect (10, 10, 100, 20), enemiesDead + "/15"); it would loom like the amount of enemies dead and "/15".

I hope that helps you. If you have any questions comment please.

Comment
Add comment · Show 4 · 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 Cyanide · Mar 24, 2013 at 09:37 PM 0
Share

I'm confused on your second bit, I don't know how to write a script that counts enemy deaths or what to attach it to.

avatar image Tim-A · Mar 24, 2013 at 09:44 PM 0
Share

Ok, do you have a script that makes the enemies health go down and die?

avatar image Cyanide · Mar 24, 2013 at 09:59 PM 0
Share

yes I do. Do I attach that code to the script, or directly to the enemy?

avatar image Tim-A · Mar 24, 2013 at 10:40 PM 0
Share

E-mail me the script. unity3dnovice@gmail.com

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

12 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

Related Questions

Removing a GUITexture a set amount of time after it has been enabled. 1 Answer

how to make a highlight gui ?? 1 Answer

How to draw GUI Text from code 1 Answer

Count the Score 1 Answer

Minute Timer Issue 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