Skip to content

Angle changes by executing certain commands #182

Closed

Description

@XinkeAE

Hi,

I'm wondering how many degrees does the agent rotate by executing commands:
"TURN_LEFT", "TURN_RIGHT", "LOOP_UP", and "LOOP_DOWN"?

Thanks!

Activity

  1. mwydmuch commented on Mar 29, 2017

    @mwydmuch
    Member

    It's interesting question. We haven't checked this before. When it comes to up and down axis, speed is ~2.5 degrees per tic. Turning speed is ~1.75 degrees in first few tics and accelerates to ~3.5.

    In addition, values change when SPEED button is active, look up and down accelerates to ~2.8 degrees and turning speed to ~7 degrees.

    This is the original Doom mechanics, we haven't changed anything in it.

    TURN_LEFT_RIGHT_DELTA and LOOK_UP_DOWN_DELTA buttons allows to use custom values, however, our api limits them to integer values - we should probably change that.

  2. XinkeAE commented on Mar 29, 2017

    @XinkeAE
    Author

    Thanks @mwydmuch for the explanation. It was helpful!

  3. XinkeAE commented on Apr 5, 2017

    @XinkeAE
    Author

    Hi @mwydmuch ,

    I have another question related to this. Obviously there is an upper bound and lower bound the the pitch angle (LOOK_UP and LOOK_DOWN). Could you please also let me know the exact value of it?

    Thank you so much!

  4. mwydmuch commented on Apr 6, 2017

    @mwydmuch
    Member

    Lower bound is exactly -56, upper is 32 degrees. Don't ask why :)

  5. XinkeAE commented on Apr 6, 2017

    @XinkeAE
    Author

    Hi @mwydmuch ,

    Thanks for the reply. I was doing some experiments based on the parameters you suggested and compute the heading of the agent accordingly, but i couldn't get the right heading. Here are some issues I'm still confused about:

    1. Every time we execute the command like "look up", how many tics does it corresponds to?

    2. In the customize key-binding, is there a way to bind "TURN_LEFT_RIGHT_DELTA" and "TURN_LEFT_RIGHT_DELTA" to a certain key?

    I really appreciated your tips!

  6. mwydmuch commented on Apr 6, 2017

    @mwydmuch
    Member
    1. You have a full control over the number of tics that agent performs in one action (second parameter of game.make_action -> https://github.com/mwydmuch/ViZDoom/blob/master/doc/DoomGame.md#makeAction). Active buttons are "pressed" during the entire duration of action. So if the action will last 4 ticks, "LOOK_UP" will change pitch by 4 * 2.5 degrees. Same in case of "DELTA" buttons, however, doing a quick test now I've discovered that they may be bugged.
      Please give me 2 days, I will investigate and add support for floating points variables.

    2. "DELTA" buttons corresponds to mouse movement, there is no way to bind it to a certain key right now.

    EDIT: No one used "DELTA" buttons in the last year competition.

  7. self-assigned this
    on Apr 6, 2017
  8. added this to the 1.1.2 milestone on Apr 6, 2017
  9. mwydmuch commented on Apr 24, 2017

    @mwydmuch
    Member

    I forgot to close this one, I've added support for floating point values and now everything works as described above.

  10. XinkeAE commented on Jun 11, 2017

    @XinkeAE
    Author

    Hi @mwydmuch , sorry for bothering you again,

    Regarding the MOVE_FORWARD AND MOVE_RIGHT buttons, I'm wondering how many units are these buttons corresponding to. Say if I use the MOVE_FORWARD for n tics, how much does the agent move forward?

    Thanks.

  11. mwydmuch commented on Jun 11, 2017

    @mwydmuch
    Member

    I don't know the exact mechanic of movement in the engine, but it implements some simple acceleration and momentum, so it's a little bit complicated.

    It looks like that default max walking speed is ~8 in-game unit. With SPEED button pressed max speed and acceleration is doubled.

    From ZDoom wiki:
    "Side movement running speed is actually 4/5ths forward running speed, and the side walk speed is 24/25ths forward walk."

    I think it's possible to combine forward and side movement to achieve greater speed, like in Quake.

    You can measure speed with help of POSITION_X, POSITION_Y, POSITION_Z game variables.

    In-game unit to real life unit translation: https://doomwiki.org/wiki/Map_unit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions