# SpawnActor use a ROLE\_SimulatedProxy actor as template will be crash

**URL:** <https://forums.unrealengine.com/t/spawnactor-use-a-role-simulatedproxy-actor-as-template-will-be-crash/389795>\
**Category:** Multiplayer & Networking\
**Tags:** spawnactor, unreal-engine, question\
**Created:** [April 3, 2017, 6:44am UTC](https://forums.unrealengine.com/t/spawnactor-use-a-role-simulatedproxy-actor-as-template-will-be-crash/389795 "2017-04-03T06:44:17Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![windywang](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@windywang](https://forums.unrealengine.com/u/windywang)\
**Post date:** [April 3, 2017, 6:44am UTC](https://forums.unrealengine.com/t/spawnactor-use-a-role-simulatedproxy-actor-as-template-will-be-crash/389795/1 "2017-04-03T06:44:17Z")

</div>

FActorSpawnParameters SpawnInfo;  
SpawnInfo.Template = RemoteActor; //ROLE\_SimulatedProxy  
SpawnInfo.SpawnCollisionHandlingOverride = ESpawnActorCollisionHandlingMethod::AlwaysSpawn;  
SpawnInfo.bNoFail = true;  
SpawnInfo.ObjectFlags = RF\_Transient;  
NewActor = GetWorld()-\>SpawnActor(RemoteActor-\>GetClass(), SpawnInfo);

there will be crash at AActor::PostSpawnInitialize, line 2746:  
check(Role == ROLE\_Authority);

---

<div class="post-metadata">

**Author:** ![Sean\_Flint](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Sean\_Flint](https://forums.unrealengine.com/u/Sean_Flint)\
**Post date:** [April 3, 2017, 1:05pm UTC](https://forums.unrealengine.com/t/spawnactor-use-a-role-simulatedproxy-actor-as-template-will-be-crash/389795/2 "2017-04-03T13:05:26Z")

</div>

Hey windywang,

How are you initializing your RemoteActor template? Could you provide that code as well?

---

<div class="post-metadata">

**Author:** ![windywang](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@windywang](https://forums.unrealengine.com/u/windywang)\
**Post date:** [April 4, 2017, 7:58am UTC](https://forums.unrealengine.com/t/spawnactor-use-a-role-simulatedproxy-actor-as-template-will-be-crash/389795/3 "2017-04-04T07:58:23Z")

</div>

in a multiplayer game, “remote player” is another player in local client

---

<div class="post-metadata">

**Author:** ![Sean\_Flint](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Sean\_Flint](https://forums.unrealengine.com/u/Sean_Flint)\
**Post date:** [April 6, 2017, 12:04pm UTC](https://forums.unrealengine.com/t/spawnactor-use-a-role-simulatedproxy-actor-as-template-will-be-crash/389795/4 "2017-04-06T12:04:05Z")

</div>

Could you please provide some additional information regarding your crash:

- Are you getting a crash reporter window? If so, please provide your LoginID and ensure to hit **Send & Close** on the report.
- Could you please provide logs from your project’s Saved-\>Logs folder from after the crash occurs?
- Could you please provide your full code for this issue so we can ensure we are following your repro?

Thanks

---

<div class="post-metadata">

**Author:** ![windywang](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@windywang](https://forums.unrealengine.com/u/windywang)\
**Post date:** [April 7, 2017, 6:22am UTC](https://forums.unrealengine.com/t/spawnactor-use-a-role-simulatedproxy-actor-as-template-will-be-crash/389795/5 "2017-04-07T06:22:56Z")

</div>

Assertion failed: Role == ROLE\_Authority [File:UnrealEngine4.15\Engine\Source\Runtime\Engine\Private\Actor.cpp] [Line: 2746]

that’s because the “Template” of FActorSpawnParameters is ROLE\_SimulatedProxy, and the “Role” property value is copied to the new spawned actor.  
you can ask your engineer, it is very easy to understand

---

<div class="post-metadata">

**Author:** ![Sean\_Flint](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Sean\_Flint](https://forums.unrealengine.com/u/Sean_Flint)\
**Post date:** [April 10, 2017, 6:27pm UTC](https://forums.unrealengine.com/t/spawnactor-use-a-role-simulatedproxy-actor-as-template-will-be-crash/389795/6 "2017-04-10T18:27:13Z")

</div>

Hey windywang,

After further investigation, it appears this crash is occurring because you are attempting to spawn an actor on the server that is something other than ROLE\_Authority. All actors on the server must be authoritative, otherwise this check will fail. As a result, I do not believe that this is a bug. I was able to replicate the crash, but it seems like intended behavior based on the current documentation and my understanding of Actor Roles: [Actor Role and RemoteRole | Unreal Engine Documentation](https://docs.unrealengine.com/latest/INT/Gameplay/Networking/Actors/Roles/)

Let me know if you have further questions or comments regarding this.

Have a great day
