x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Spawn actor from class doesn't work in standalone game

when i use the spawn actor from class node in my blueprint it works fine with "play in editor mode" but doesn't spawn anything in standalone game or even when i package the gamealt text

Product Version: UE 4.12
Tags:
untitled.png (289.4 kB)
more ▼

asked Jun 30 '16 at 11:49 AM in Blueprint Scripting

avatar image

Banzuke
95 7 11 11

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

7 answers: sort voted first

figured it out! i just had to add a vector+vector node and add the target point locationalt text

untitled.png (411.0 kB)
more ▼

answered Aug 30 '16 at 03:59 PM

avatar image

Banzuke
95 7 11 11

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

Are you sure that map is the one that gets loaded by default in your standalone game? In project settings, check the Maps & Modes and be sure to load the proper one at game start.

more ▼

answered Jun 30 '16 at 01:22 PM

avatar image

keyle
1.8k 66 27 90

avatar image Banzuke Jun 30 '16 at 04:13 PM

yes it is and i have tried this over many new and old projects but still nothing

avatar image Banzuke Jun 30 '16 at 05:01 PM

also i opened my output log and there was an error "LogSpawn:Warning: SpawnActor failed because no class was specified" it works in the editor but not in standalone. i read somewhere that when you play in editor it overlooks some errors but anything outside the editor and it is more strict

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

Is your player start colliding with the level? Can you put it a bit up in the air and see if the player can spawn then?

more ▼

answered Jul 01 '16 at 01:48 AM

avatar image

keyle
1.8k 66 27 90

avatar image Banzuke Jul 01 '16 at 08:10 AM

no it doesn't help even if i lift up the player or the target point. i might just go back to ue 4.9 because it was way more stable and this just has too many issues for me

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

Is it not spawning at all or is it just invisible with no collision? You can check that by adding a debug message or an event in your spawned object (BeginPlay).

more ▼

answered Jul 01 '16 at 11:33 AM

avatar image

Niaphim
56 3 6 7

avatar image Banzuke Jul 07 '16 at 09:22 AM

I don't have access to my laptop now but it probably is invisible and/or spawning in the exact middle of my level because i have had this problem before when i played in editor. BTW i have no idea how to fixed it

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

seems like the spawn don t find your class, you may try to promote the class to a variable and plug it to the spawn node, that may avoid that bug

more ▼

answered Jul 07 '16 at 10:56 AM

avatar image

expose
769 26 6 43

avatar image Banzuke Jul 08 '16 at 09:23 AM

i tried it but it didn't work

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

What you are likely seeing here is a fault of replication. Try an actor class variable that is replicated and see if that resolves. Check the actor class that it spawns also has replication enabled.

more ▼

answered Jul 08 '16 at 01:12 PM

avatar image

TechnicallyLew
134 7 3 8

avatar image Banzuke Jul 29 '16 at 01:59 PM

no that didn't fix it

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

I narrowed it down even more and i see that the meshes spawn but are invisible because i have set it up to increase my health once i walk over them and when i walk in my level my health will randomly incerease

more ▼

answered Aug 03 '16 at 11:42 PM

avatar image

Banzuke
95 7 11 11

avatar image Banzuke Aug 07 '16 at 11:41 PM

and if i spawn them in one specific location (not with the random transform) it is visible

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question