WB Coding How to spawn the player character in multiplayer ?

正在查看此主题的用户

I would like to know how can I spawn the player character in multiplayer.

I've created a new game mode where the player can spawn by pressing a button in a menu but I don't know which operation I should use to spawn the player.
I've already try the operation player_spawn_new_agent but nothing happen (I've probably do something wrong).

Any ideas how to do it ?
 
解决方案
I've found how to do it:
Python:
# Pseudo code example:

(player_set_team_no, ":wanted_plr", ":wanted_team"), #you need to set the player team
(player_set_troop_id, ":wanted_plr", ":wanted_troop"), #you need to set the player troop too, however I recommend to not use trp_multiplayer_profile_...
(player_spawn_new_agent, ":wanted_plr", ":wanted_entry_point"), #finally

I've found how to do it thanks to open source code: https://github.com/OutlawByteStudios/Persistent-Kingdoms
I've found how to do it:
Python:
# Pseudo code example:

(player_set_team_no, ":wanted_plr", ":wanted_team"), #you need to set the player team
(player_set_troop_id, ":wanted_plr", ":wanted_troop"), #you need to set the player troop too, however I recommend to not use trp_multiplayer_profile_...
(player_spawn_new_agent, ":wanted_plr", ":wanted_entry_point"), #finally

I've found how to do it thanks to open source code: https://github.com/OutlawByteStudios/Persistent-Kingdoms
 
点赞 0
解决方案
后退
顶部 底部