Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 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 TheEveknight · Oct 15, 2018 at 12:19 PM · instantiateglitchhierarchy

Enemies instantiate, in the wrong place, and don't show up in the Hierarchy

So I'm trying this again, I'm having an issue with a project I'm working on, where enemies are supposed to spawn at predetermined Spawn points using the transforms form empty gameObjects, up until 2 days ago this worked fine, but suddenly now my NPCs, and even some Level elements are instantiating in random places, and all of their transforms read that they are at location 0,0,0 despite the fact that they have no parent. as if this wasn't confusing enough, whenever I select the GameObjects they seem to not exist in the hierarchy, and when I've searched the hierarchy to see where these things are I find no trace.

this started with enemies not spawning where I told them to, and has suddenly moved on to half of the levels doing the same thing, I'm not sure what I could have changed.

unity version 2017.1.5f

Comment
Add comment · Show 3
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 tormentoarmagedoom · Oct 15, 2018 at 02:13 PM 0
Share

If all you say its true, there are 2 options. You loaded some addon to unity that is corrupted, or Unity itself is corrupted.

TRy to reinstall Unity.

avatar image TheEveknight tormentoarmagedoom · Oct 15, 2018 at 02:38 PM 0
Share

ok, thanks! I'll give this a try and see if that fixes the issue.

avatar image TheEveknight TheEveknight · Oct 16, 2018 at 11:45 PM 0
Share

@tormentoarmagedoom You were 100% Correct, reinstalling unity seems to have fixed the issue, it seems that some crucial things were corrupted, Thanks!

2 Replies

· Add your reply
  • Sort: 
avatar image
1

Answer by GamitusLabs · Oct 15, 2018 at 04:03 PM

What I have found in my projects is when you instantiate objects their positions are relative to their parents transform. So, if they aren't instantiated parented 0,0,0 would be at the worlds origin, vs being centered on its parent (spawner, presumably) object. Can't really be sure of anything without some code (pseudo or actual) to reference.

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

Answer by TheEveknight · Oct 16, 2018 at 07:01 PM

right, the thing is, that they have no parent object, because i was testing to see if that was the problem in the first place, And i would post some code, but i'm away from that computer for most of the day today. The thing that confused me most was that they on't even show up in the object hierarchy at all, and i sifted through there pretty intensely.

i'm in the process of reinstalling unity 2017.1.5f too see if maybe something was indeed corrupted.

The issue is primarily that the objects are SUPPOSED to spawn at their respective spawn points as a child of the spawn point. they just arent, the weirdest thing that i actually noticed about this, is that they spawn in a pattern as though they would be spawning at the correct location, but at an incorrect location, i'm not sure how to explain this any way other than that

alt text

Both the enemies and the objectives are spawning as if the should be on the ship, but this is a LOOOOOONG way from where they should be


ex.png (99.6 kB)
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 TheEveknight · Oct 16, 2018 at 11:45 PM 0
Share

@tormentoarmagedoom You were 100% Correct, reinstalling unity seems to have fixed the issue, it seems that some crucial things were corrupted, Thanks!

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

112 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 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

Instantiate script for randomly selecting sound is suddenly creating New Game Object in hierarcy?? 2 Answers

game glitches on play 1 Answer

How to make instantiated buttons permanent in hierarchy? 1 Answer

how to make a Portal 2-esque laser beam "redirection" system? 0 Answers

Instantiate a prefab inside a hiearcy 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