🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Questions about GDArena

Started by
59 comments, last by khawk 20 years, 10 months ago
quote: Original post by void2357
Hedos, you might want to try QueryPerformanceFrequency() and QueryPerformanceCounter().
timeGetTime() is less much less accurate, but if you really want to use it then you could link to winmm.lib
#pragma comment(lib, "winmm.lib")


You could also use the C Time Functions in time.h

Advertisement
quote: Original post by drreagan
are the object radii listed in the readme the collision radii, the LOS radii or both?


I have listed some of them somewhere on the forum, but I do not think they are in the readme (yet).

Admin for GameDev.net.

quote: Original post by d000hg
I mean what direction I''m hit from - if it''s 45 degrees (just out of vision) I''ll likely turn & shoot wheras if he''s directly behind me I''ll run away!


I''ve been considering it, but it''s very low priority, and I haven''t come up with a good enough solution. Right now I''m thinking that if it is implemented, then the direction will be a direction with +/-N degree error, or possible a relative direction (forward, left, right, behind). To tell the bot being hit exactly where the shot came from would be completely unrealistic.

quote:
1)How exactly is the wall thing working? My bot''ll turn until he''s almost running along the walls but still trying to run just outside them then seems to stop seeing the wall completely.


A perpendicular line is drawn (I''ve explained this several times) from your bot to the wall. If your FOV interesects this line, the bot sees the wall. I think it adds more challenge to wall detection, but alot of people are complaining about it.

quote:
2)When I run right into something I seem to stop detecting it - by bot stops trying to turn and tries to run straight through.


I have to look into it. I haven''t had this problem.

quote:
3)Do all the bool returning functions tell you anything? It would be really helpful if they passed/failed.


Yes. If they pass they return true, if they fail they return false.

quote:
4)Which methods can only be called once an update and which can be called multiple times successfully?


Get()''s can be called multiple times, but any Set()''s, Fire(), SelectWeapon(), etc can only be called once. In other words, you can only command your bot to do something once, but you can retrieve information about the arena as often as you''d like.

quote:
5)What are the delay times for firing/changing weapons & grenade timer please? Can they be put in the readme as ''official'' information rather than just word-of-mouth? (In fact all the info being set in stone would be nice).


Stuff like this hasn''t made it to the documentation yet. It''s a matter of priorities and time, and I''ve already said at the first release that the documentation would not be complete. I''ve also already answered this one somewhere.. 0.2 second reload for gun, 2.0 second reload for grenade. When you switch weapons, the reload time goes into effect.

quote:
6)Can you give us one Turn() method which includes both left and right, and one GetAmmo(int WeaponType) method which would be better if more weapons get included.


For the turns - I''ve thought about it, but I like how it is right now. For the ammo, it will probably evolve into that.

quote:
7)When we get the data on an object in sight, is it pointing at the centre, the nearest point to 0 degrees or the nearest point to me? Does it include my bot''s radius - ie does 0 mean we''re touching?


Direction is pointing to the center. Distance is the distance from your bot''s center to the center of the object. Radius is not taken into account.


Admin for GameDev.net.

That''s all most helpful, thanks. A few responses:

1)So if a large rock has it''s centre 41 degrees from my direction I can''t see it but can get stuck on it, is that correct?

2)If I try to move but am e.g stuck in a corner, will Move() pass or fail? The character''s legs still run but he stays still!

3)The rotation with one function I still think better - I at least just automatically write a wrapper function to do it anyway! You can even do this for us by giving us Turn(int TurnRate,bool Clockwise) which still allows the enum values to be used.

4)The wall detection currently seems deliberately complicated. Giving us minimal ifo to increase difficulty is one thing, but complete unrealism is another. If the bot is restricted to seeing in an 80degree arc, he can still see the edge of the level. Likewise he can tell if he''s unable to walk in a given direction. I suggest these data are made available.

5)The grenade lasts 4s before exploding, right?
quote: Original post by d000hg
That''s all most helpful, thanks. A few responses:

1)So if a large rock has it''s centre 41 degrees from my direction I can''t see it but can get stuck on it, is that correct?


Yes, as of right now. But I''m going to change that so if your FOV intersects the radius of the rock, you will see the rock.

quote:
2)If I try to move but am e.g stuck in a corner, will Move() pass or fail? The character''s legs still run but he stays still!


Getting stuck does not return false. It doesn''t mean the movement function failed (return false), it just means you have collided with an object, so it returns true.

quote:
3)The rotation with one function I still think better - I at least just automatically write a wrapper function to do it anyway! You can even do this for us by giving us Turn(int TurnRate,bool Clockwise) which still allows the enum values to be used.


Well, people will always have their opinions, but I''d need a good enough reason why and with proof of why it is better, along with drawbacks to each side. That''s just how I make decisions for software.

quote:
4)The wall detection currently seems deliberately complicated. Giving us minimal ifo to increase difficulty is one thing, but complete unrealism is another. If the bot is restricted to seeing in an 80degree arc, he can still see the edge of the level. Likewise he can tell if he''s unable to walk in a given direction. I suggest these data are made available.


I''ve explained why the walls were done this way in another thread. It''s not deliberately complicated with minmal information, and it has nothing to do with realism vs. non-realism. It has everything to do with the nature of the problem itself and the nature of the interface. Check the other thread for more explanation.

quote:
5)The grenade lasts 4s before exploding, right?


4 seconds from the time of fire.

Admin for GameDev.net.

quote: Original post by Khawk
quote: Original post by drreagan
are the object radii listed in the readme the collision radii, the LOS radii or both?


I have listed some of them somewhere on the forum, but I do not think they are in the readme (yet).



oh, i know that the radii of the objects are listed in the readme.
my question is: are the radii used to calculated Line-Of-Site the same as the radii used to determine collision?

A headache, ancillary; an hourglass auxiliary.

"something witty, blah, blah, blah"
--That One Witty Guy (remember? that one dude?)


------------------------------------------------------- A headache, ancillary; an hourglass auxiliary."something witty, blah, blah, blah" --That One Witty Guy (remember? that one dude?)(author of DustBot)
quote: Original post by drreagan
quote: Original post by Khawk
quote: Original post by drreagan
are the object radii listed in the readme the collision radii, the LOS radii or both?


I have listed some of them somewhere on the forum, but I do not think they are in the readme (yet).



oh, i know that the radii of the objects are listed in the readme.
my question is: are the radii used to calculated Line-Of-Site the same as the radii used to determine collision?


Yes.

Admin for GameDev.net.

Are the movement/turning commands executed in the same order as they are given?

For example, does:

TurnLeft(TURN_FAST);
SetSpeed(SET_HIGH_SPEED);


move the bot to the (exact) same place as:

SetSpeed(SET_HIGH_SPEED);
TurnLeft(TURN_FAST);


or not?

(Given that you don''t collide with anything.)

[How To Ask Questions|STL Programmer''s Guide|Bjarne FAQ|C++ FAQ Lite|C++ Reference|MSDN]
Arguing on the internet is like running in the Special Olympics: Even if you win, you're still retarded.[How To Ask Questions|STL Programmer's Guide|Bjarne FAQ|C++ FAQ Lite|C++ Reference|MSDN]
How are collisions calculated? Are the movement interrupted if a bot collide with anything, or is the direction of the movement altered somehow?

[How To Ask Questions|STL Programmer''s Guide|Bjarne FAQ|C++ FAQ Lite|C++ Reference|MSDN]
Arguing on the internet is like running in the Special Olympics: Even if you win, you're still retarded.[How To Ask Questions|STL Programmer's Guide|Bjarne FAQ|C++ FAQ Lite|C++ Reference|MSDN]
quote: Original post by dalleboy
Are the movement/turning commands executed in the same order as they are given?

For example, does:

TurnLeft(TURN_FAST);
SetSpeed(SET_HIGH_SPEED);


move the bot to the (exact) same place as:

SetSpeed(SET_HIGH_SPEED);
TurnLeft(TURN_FAST);


or not?

(Given that you don''t collide with anything.)


No. They are executed simultaneously.

Admin for GameDev.net.

This topic is closed to new replies.

Advertisement