Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to make the player spawn at random locations? #428

Closed
HadiSDev opened this issue Jan 30, 2020 · 1 comment
Closed

How to make the player spawn at random locations? #428

HadiSDev opened this issue Jan 30, 2020 · 1 comment

Comments

@HadiSDev
Copy link

HadiSDev commented Jan 30, 2020

Issues

  • description of an issue,
    I am new to VizDoom so please excuse my noobness, but how do I make the player spawn at random locations instead of just the middle of the room if we take the basic scenario as an example. Thanks in advance.
  • ViZDoom version you are using,
    1.7
  • information about your OS platform, distribution and environment (GCC, Python, Java, Lua versions etc.),
    Ubuntu 18.4 Python 3.6
@Miffyli
Copy link
Collaborator

Miffyli commented Jan 30, 2020

You need to modify scenario files (.wad) to achieve this. I have detailed instructions written here.

For random spawn locations you can take a look at health_gathering_supreme.wad (open it and see how random spawning is done there). The technique used there is to place Things (markers) on the map where player can spawn, and then in the ACS script you randomly pick one of those markers and move the player there (See health_gathering_supreme.wad SCRIPT entry at the bottom). If "+deathmatch" game argument is provided, player will be spawned to one of the PlayerSpawn markers randomly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants