Quantcast
Channel: Questions in topic: "clone"
Browsing all 508 articles
Browse latest View live
↧

How to make changes to a copied object

Hi, I have copied an object in the editor and I make some changes on the Texture and the changes applied automatically on the object that i copied from. How can i make changes only on the cloned object?

View Article


I want to only destroy 3 of the clone prefabs that appear how would I do this?

if((b==h)&&(h==y)){ Destroy(GameObject.Find("BlueCube(Clone)"),3); }

View Article


How could I save all cloned objects in a scene, and load them back up on start?

I've been having trouble figuring out this for weeks now. Lets say I enter a scene and instantiate a block and then leave the scene. How could I make it to where whenever I re-enter the scene, the...

View Article

Untouchable clone object of doom

Hello. I've encountered a problem that I don't understand in the slightest. I have a 3rd person player character, called "player", and several attackable NPCs. The NPCs are programmed to turn and move...

View Article

Clone wants a Parent (c#)?

How would you go about moving a clone to the main camera parent. Or should I say how would you turn the new clone into a child of the new Parent (Main Camera). It's a c# script. // Start Cloning...

View Article


Switch camera to cloned object.

Hello again. I have a problem with my camera, it follows a player like a 3rd person camera, it is fine but when my player dies an instantiated ragdoll is cloned and player object is destroyed. So I...

View Article

How to delete instantiated GameObject

I have a simple question , how can I delete a cloned or instantiated object after 1 second without deleting the original. The GameObject is just a 3d object with no scripts attached. All I want to do...

View Article

set the cloned prefab as target ????????

well, in the hierarchy i have a camera with smoothFollowTarget.js , in my project i have a Cube-Prefab which cloned during the game ... is there any way to assign the Cube-Prefab as camera target when...

View Article


Auto Translate after cloning gameobject using Instantiate()

I want to create drag and drop functionality for a gameObject. When user touches the object it creates a duplicate and the duplicate supports drag and drop features when the original object remains in...

View Article


Clone Objects treating static variables strangly

Hey guys! I have an enemy that will duplicate itself every now and then. Whenever one is created I have a static variable "DupeMobCount" that increases by 1, and when they are destroyed, it decreases...

View Article

error in destroying bullet prefab

hi, i want to destroy bullet prefab when it is instantiated after 2 seconds and i wrote this code, but it doesn't working, and during playing mode the cloned prefabs doesn't destroyed var seconds :...

View Article

save/load cloned game object

i've googled a lot but no good answers , i'm trying to save cloned object with position in the scene then load it next time (like strategy games). hope someone can help me ,sorry with my english .

View Article

After Destroy clone, Spawn a prefab in its location?

How would you spawn a prefab after the clone was destroyed in its place. When the asteroid hits Jupiter I would like the have a explosion effect after the collision. Here's my script. using...

View Article


Enemy prefab not keeping transform

var target : Transform; //the enemy's target var moveSpeed = 3; //move speed var rotationSpeed = 3; //speed of turning var respawn : Transform; var dead : boolean = false; var myTransform : Transform;...

View Article

Adjusting Rotation of Instantiated Objects

I have a sword in a game. When you click on the sword, it deletes and creates another one in your hand. It does this correctly but with a random rotation. How do I fix this? #pragma strict var hand :...

View Article


Instantiate Not Working - Boo Script

I'm not sure whats wrong, as far as I'm concerned I'm using this correctly. In fact, I've copied the instantiate "function" from another script that returns no errors. But when i try to launch, I get...

View Article

Question about instantiate AI

In our game we have several "spawners" that spawn Capsules that act as enemy AI. Whenever we have tried to add a health and damage script, though, and have tried to kill the AI, all AI clones from the...

View Article


Creating a new game object with the same renderer as an existing object.

I want to use a script to creates a new game object that contains only the clone a gameobject's renderer. Ideally this would be something simple along the lines of: GameObject RenderClone = new...

View Article

I AM UNABLE TO DESTROY THE CLONE OF THE GAMEOBJECT I AM INSTANTIATING

I AM CREATING A NUMBER OF CLONES OF THE GAMEOBJECT FOR MY GAME.THE MOTTO OF MY GAME IS TO GENERATE A NUMBER OF THE GAMEOBJECT (CLONE) AND I AM SUCCESSFULLY DOING THIS BUT WHEN I AM TRYING TO DESTROY...

View Article

How to instantiate from prefab, not from instance?

I'm instantiating a game object from a reference to a prefab, like this: var starSystem : GameObject; function OnTriggerExit2D (other: Collider2D) { var newSystem : GameObject = Instantiate(starSystem,...

View Article
Browsing all 508 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>