Gamestudio Links
Zorro Links
Newest Posts
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
2 registered members (AndrewAMD, degenerate_762), 1,309 guests, and 1 spider.
Key: Admin, Global Mod, Mod
Newest Members
Hanky27, firatv, wandaluciaia, Mega_Rod, EternallyCurious
19051 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Any guides on coding player car race position #223438
08/24/08 08:54
08/24/08 08:54
Joined: Jun 2008
Posts: 5
C
calz054 Offline OP
Newbie
calz054  Offline OP
Newbie
C

Joined: Jun 2008
Posts: 5
Hi, do anybody has any guides or tutorials on how to go about coding a player car positioning in a the race? Player's car current standing in a race with many AI cars.

Re: Any guides on coding player car race position [Re: calz054] #223447
08/24/08 10:37
08/24/08 10:37

M
mercuryus
Unregistered
mercuryus
Unregistered
M



place some (invisible/passable) checkpoints (path?) on the track.
Get the last passed checkpoint for each car.
Each position can be calculated by:

* round
* last passed checkpoint
* distance to last passed chackpoint

(the more checkpoints the more accurate is the calculatiuon)

mercuryus



Re: Any guides on coding player car race position [Re: ] #223491
08/24/08 16:29
08/24/08 16:29
Joined: Mar 2008
Posts: 67
crumply Offline
Junior Member
crumply  Offline
Junior Member

Joined: Mar 2008
Posts: 67
If you just drew that diagram to help explain you are a v helpful member of this forum smile

Re: Any guides on coding player car race position [Re: ] #223500
08/24/08 17:26
08/24/08 17:26
Joined: Jun 2008
Posts: 5
C
calz054 Offline OP
Newbie
calz054  Offline OP
Newbie
C

Joined: Jun 2008
Posts: 5
Thanks a lot mercuryus, I managed to get the logic and it seems like the more AI cars I have, the more conditions and checking i need to consider to get the player's position. I am now trying to code the whole thing and it was really a pain. crazy


Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1