Questions tagged [spawning]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
0 answers
25 views

UE4: Does SpawnActor load assets from disk in runtime? Is it possible to cache it on load?

How does the SpawnActor work? If actor has meshes or sounds will it be loaded in runtime? Or will it load them on start? If it loads in runtime, how can we prevent it? (for i.e. cache all assets when ...
user avatar
  • 231
1 vote
2 answers
691 views

how do i NOT let this object spawn at a certain area?

...
user avatar
0 votes
0 answers
33 views

transform.localPosition does not wok in Unity

When im breaking fence GameObject there should pop up scores, so it works fine. But position of pop up scores is too low, im trying to raise it by ...
user avatar
  • 1
0 votes
1 answer
136 views

Spawn crops/3D game objects randomly on a mesh/plane surface

I am stuck on a problem that might be quite simple yet it's getting on my nerves. I want to spawn crops on different plane shapes like in the attached screenshot. So far my progress is that I am able ...
user avatar
0 votes
2 answers
366 views

How to Spawn GameObjects at Random Positions in Unity? [closed]

Hello GameDev Community, I have a problem with this pice of code. If I start the "Game", it crashes right away. Probably is its the list of GameObjects or the foreach loop. I have no idea ...
user avatar
  • 3
0 votes
1 answer
58 views

Recycling bullets versus spawning them on demand

Until now, I know 2 bullets' algorithms/configurations : (I mean 2 ways of logically creating a bullet class) Make a bullet class and create only one instance from it that represents the bullet. The ...
user avatar
  • 216
1 vote
1 answer
78 views

Ensure that random enemies don't spawn just near the player

I need to find a method using which I can ensure that random enemies and objects don't spawn just near the player. In fact, if they do, the player will be more likely to collide with them and lose. ...
user avatar
  • 216
0 votes
0 answers
43 views

Platforms are gradually being spawned further and further away in the Z-axis in a 2D Endless runner game, until they spawn behind the camera

I am creating a 2D endless runner game, where new platforms get spawned when the player reaches a certain distance to the last platform spawned. The issue that I found was that after the player ...
user avatar
0 votes
1 answer
54 views

Why does my spawner spawn multiple times at start-up, only in build?

I'm making a small game similar to Super Hexagon. I've recently asked a question about making the game harder as the player progresses by increasing the obstacles' spawn rate. I was able to implement ...
user avatar
  • 71
0 votes
1 answer
51 views

Random Spawning Traffic at Pace Fitting "Frogger"-style Gameplay

In my game level, you have to cross a busy road to buy something and then cross back again. The general gameplay mechanics are now set up and playable. But I wanted to know if this routine I used to ...
user avatar
0 votes
0 answers
100 views

How can I improve the current enemy spawning system for my strategy game

I'm currently making an RTS game for mobile where mini battles would take place on tiny battlegrounds. The problem is that currently the player is spawning its units based on a currency system, ...
user avatar
0 votes
2 answers
52 views

Spawning a customized sprite with text

I'm making a game where I have circles filed with words or pictures drop from the top of the screen to the bottom. they should spawn right above and then drop. I just started using unity a couple days ...
user avatar
0 votes
0 answers
77 views

Spawning projectile: it's there but does not show

Here is the code and very simple. I can see the object in the blue print and has nothing except the object itself. so all the issue should be on the C++ code. ...
user avatar
1 vote
2 answers
1k views

Unity 3D mirror, sync player spawn name

I am using Mirror for doing my little multi-player car racing project which I want to rename the game object automatically after the NetworkManager auto create the game object. Here is my ...
user avatar
  • 11
0 votes
2 answers
134 views

Spawning prefab on touch after previous spawn(s) had been destroyed

I wrote a script which pawns an object (instantiated prefab) each time the player touches the screen. The maximum number of these spawned objects active in the scene at once is 3, and when they are ...
user avatar
0 votes
1 answer
28 views

Attach movement to each list object

How would i move every sphere that gets spawned every 2 seconds ? Basically i want every sphere to follow the previous spawned sphere or even all N-1 spheres should follow the first spawned sphere ...
user avatar
  • 51
0 votes
1 answer
303 views

Tetris block kinematic rigidbodies pass through one another with Transform.Translate

I am trying to build a Tetris 3D game in Unity but I am stuck at getting the different blocks to interact (to detect each other, to sit one on top of the other rather than going through each other). I ...
user avatar
  • 51
1 vote
1 answer
753 views

UE4 Blueprint Multiplayer Spawning Issue

I'm attempting to copy/modify the MultiplayerShootout project's multiplayer functionality for my own project. I'm running into issues when Player 2 joins a running session though. Finding it very hard ...
user avatar
0 votes
1 answer
137 views

Unity 3D platform spawning problems

I'm making an infinite runner game in Unity 3D. I have it so that platforms spawn and move backwards toward the player and they are destroyed once past the player. Over time when the platforms are ...
user avatar
0 votes
1 answer
125 views

Increasing spawn difficulty

I'm trying to increase the difficulty of the game over time. I'm using InvokeRepeating to spawn enemies and in the update function I calculate the next spawn time using the following code: ...
user avatar
0 votes
1 answer
196 views

How to manage network spawning?

I'm developing an multiplayer game "from scratch" (not using a big Engine-Suite like Unity but the lower-level libgdx). Currently I've got a NetworkManager which handles the sending of messages on ...
user avatar
0 votes
0 answers
29 views

How can I spawn and drag 2d object from a Canvas button?

I want to create and drag an object from canvas button to scene. How can I do this?
user avatar
0 votes
1 answer
328 views

Spawn Array of GameObjects to Array of Transforms

I have a question regarding spawning an array of GameObjects in Unity. What I want to happen is that when a big enemy dies, it will spawn enemies into their respective Transform positions (i.e., Enemy ...
user avatar
0 votes
0 answers
36 views

Why does my "spawnedEnemies" variable not update when enemies are destroyed?

I'm creating a shooter game and I'm trying to update the current count of enemies on screen. When the laser hits an enemy, it is supposed to subtract 1 from the "spawnedEnemies" and then destroy the ...
user avatar
1 vote
1 answer
4k views

Issues using NetworkServer.Spawn with Unity and Mirror-Networking

I am using Mirror to handle the networking aspect When I spawn an object on the network, I Instantiate it on the server and then use NetworkServer.Spawn to notify all clients to spawn the object. ...
user avatar
  • 11
0 votes
1 answer
123 views

How to implement arcade-style spawning?

In many arcade-style games with a horizontally scrolling camera, enemies spawn offscreen, either left or right, and traverse the screen in the opposite direction. Spawning enemies is easy enough, but ...
user avatar
  • 1,297
0 votes
1 answer
229 views

How can I add a delay to my enemy spawning in Greenfoot?

How can I add a delay between spawning my enemies in Greenfoot? I'm doing it from a class that is neither a world nor an actor, its made totally by me. I need to it spawn 3 enemies, 3 times, with a 1-...
user avatar
0 votes
0 answers
51 views

How can I spawn objects in a volume without intersection?

I am generating a 3D scene that involves spawning lots of 3D objects in a finite volume. I need to avoid intersection of objects.
user avatar
  • 113
0 votes
2 answers
138 views

My GameObject keeps spawning when it shouldn't

I'm trying to instantiate a new gameObject when the current gameObject gets to a select point. The problem comes when the program gets to the second if() statement. It sets the floorsSpawned to 1 and ...
user avatar
0 votes
2 answers
204 views

How can a variable have two values at the same time?

Just to clarify, I do not want to know how to make a variable display 2 values ​​at the same time. I want to know how this is happening in my project. In the Level Blueprint I have a timer that ...
user avatar
0 votes
0 answers
130 views

How to spawn objects and control the content in each spawn

I'm using unreal engine and would like to spawn multiple actors and control the text in each spawned actor. How can this be achieved in unreal engine?
user avatar
0 votes
1 answer
231 views

Actor does not perform action when spawned?

In the level blueprint I made a code so that after 5 seconds an NPC was spawned, it happens that it does nothing. Only the NPC I added by the level editor acts correctly. Image of what happens: ...
user avatar
0 votes
1 answer
4k views

How to Destroy an Instance of a Prefab Without Removing the Prefab?

I'm making a simple runner game where obstacles spawn off in the distance and move towards the player. I want to remove them after they're invisible to the player. I made an ...
user avatar
0 votes
0 answers
22 views

Spawn a gameobject from list when grip button is clicked? [duplicate]

I wanted to spawn gameobjects from the list one by one when the grip button in the controller is clicked. I have attached my code and the inspector which contains the list of gameobject but the code ...
user avatar
3 votes
1 answer
246 views

Instantiate object with spawn time?

I have script that makes waves of enemies. It selects enemy from array randomly. I want to add function allow me to select any object in my array and instantiating it for number of times. In wave 1, ...
user avatar
  • 214
0 votes
1 answer
192 views

Rotate object to closest clone?

I'm working on a tower defense game. I'm trying to make my gun object rotate and shoot the nearest instance of the "enemy" object. My problem here is my gun script rotates only to the main enemy ...
user avatar
  • 214
0 votes
1 answer
568 views

How do open world games handle efficiently enemy respawn?

I'm currently working on a 2D open world game loaded in chunks, initially I thought It would be sufficient to spawn entities randomly in a specific "radius" close to the player, and periodically ...
user avatar
0 votes
2 answers
980 views

How do I respawn a prefab that matches the name of the game object I just destroyed?

In my game the player can interact with certain objects like coins, clouds and springs. After these interactions the game objects are destroyed. All of these game objects have their own properties, ...
user avatar
5 votes
1 answer
3k views

Unity: Player Gets Stuck Between Tiles

I am creating an endless game, which constantly spawns tiles. The problem is that after a few tiles the player gets stuck on random tile and stops moving. I noticed this problem even when i was ...
user avatar
2 votes
4 answers
6k views

How can I spawn items based on probabilities?

I'm working on a game where I want to choose which object to spawn based on probabilities. Assuming the decision to spawn the object has been done by some other process, I'd like the object with the ...
user avatar
  • 23
-3 votes
1 answer
768 views

Game maker studio 2 Random spawn locations are not random [duplicate]

This is a redo of another question I asked. First I want to clarify that I am indeed using drag and drop. So saying something like "maybe switching to gml will fix your problem" is appreciated, but ...
user avatar
-1 votes
1 answer
341 views

How to limit where an object spawns GameMaker Studio 2

When the game starts, I am trying to generate an object in a random area. It's working, but sometimes the object spawns in the players view. How to have an object that generates in a random location, ...
user avatar
4 votes
1 answer
3k views

Why does UE crash when I spawn a tile actor like this?

I'm trying to replicate a version of "Paper.io" using Unreal Engine and C++ as an exercise. My idea is to have an instance of an Actor (that is my "Grid class" in this case), and another Actor acting ...
user avatar
0 votes
1 answer
149 views

Make enemy disappear after spawn

I have enemies that spawn in different positions but what I want to do is that if you don't kill it after three seconds, the enemy disappears (but the spawning keeps happening of course, the enemy ...
user avatar
0 votes
1 answer
421 views

Animation after enemy spawns

right now in my game, four enemies spawn in four spawn points with a delay, but what I want to do is that if you don't kill the enemy after a couple seconds, an animation (it's an animation of a ...
user avatar
1 vote
2 answers
98 views

Display image a couple seconds after an enemy spawns?

So right now I have enemies that spawn behind objects with a delay. What I need is to display an image on the screen 5 seconds after each enemy spawns (it's to show the player it has been "attacked")...
user avatar
1 vote
1 answer
123 views

How to synchronize the speed of spawned object and spawning time interval?

I want a stream of enemies coming from the top of the screen one behind other in a line, with their speed (speed of the whole stream i.e. every enemy) increased over time. When I simply increased ...
user avatar
6 votes
1 answer
327 views

How to make sure that the set of randomly spawning obstacles is passable?

Prompt Suppose we have a little mini-game where you have to avoid incoming obstacles by moving the blob up and down at a constant speed. The blob's x coordinate is fixed and the obstacles will spawn ...
user avatar
2 votes
3 answers
94 views

Spawn rates and variable time steps

How would I work a spawning algorithm into a sim engine with variable time steps? If each engine step is, say, 1/30 of a second and I have some event occur with a 0.001 probability each step, how do ...
user avatar
  • 279
0 votes
1 answer
255 views

Object array in unity not instantiating properly

I'm trying to instantiate my CarMovement class with my population class for a Genetic Algorithm, but when i run the project, the car prefab doesnt spawn. Everything is wired up in the inspector ...
user avatar