SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Reply
 
Thread Tools Display Modes
Old 31/07/2015, 01:40 AM   #1
Dragonic
Big Clucker
 
Join Date: Jul 2015
Location: Brazil
Posts: 94
Reputation: 1
Exclamation [Help] How to create races?

So, how can I create races with checkpoints? Like if a player type /race, he'll be teleported to a specific location and then the checkpoints will be shown for him and all that stuff, when he pass through one CP another will appear (hope you get the point).
Dragonic is offline   Reply With Quote
Old 31/07/2015, 01:45 AM   #2
!damo!spiderman
Huge Clucker
 
!damo!spiderman's Avatar
 
Join Date: Oct 2006
Posts: 244
Reputation: 160
Default Re: [Help] How to create races?

http://wiki.sa-mp.com/wiki/OnPlayerCommandText
http://wiki.sa-mp.com/wiki/SetVehiclePos
http://wiki.sa-mp.com/wiki/Function:SetPlayerCheckpoint
http://wiki.sa-mp.com/wiki/OnPlayerEnterCheckpoint
__________________
!damo!spiderman is offline   Reply With Quote
Old 31/07/2015, 02:04 AM   #3
Dragonic
Big Clucker
 
Join Date: Jul 2015
Location: Brazil
Posts: 94
Reputation: 1
Default Re: [Help] How to create races?

Can you give me an example on how to put this together?
Dragonic is offline   Reply With Quote
Old 31/07/2015, 03:42 AM   #4
!damo!spiderman
Huge Clucker
 
!damo!spiderman's Avatar
 
Join Date: Oct 2006
Posts: 244
Reputation: 160
Default Re: [Help] How to create races?

Do you know any scripting at all?

Basically have an array of your points for the checkpoints, have a variable which tracks each players checkpoint id. When the player enters the command set their vehicle position to where the race is, then set the first checkpoint. When they go through a checkpoint the function OnPlayerEnterCheckpoint will be called, just increase their checkpoint id by 1 then set their new checkpoint and so on until the end
__________________
!damo!spiderman is offline   Reply With Quote
Old 31/07/2015, 09:29 AM   #5
Dragonic
Big Clucker
 
Join Date: Jul 2015
Location: Brazil
Posts: 94
Reputation: 1
Default Re: [Help] How to create races?

Quote:
Do you know any scripting at all?
Yes, a bit... I'm trying to learn. About the teleport and stuff its fine, but I don't know how to make the lines for when a player enters the first CP it starts to show the second...
Dragonic is offline   Reply With Quote
Old 31/07/2015, 09:54 AM   #6
ognyanov
Big Clucker
 
ognyanov's Avatar
 
Join Date: Apr 2015
Posts: 111
Reputation: 0
Default Re: [Help] How to create races?

pff you can use filterscripts for races,just search and you will find some.Good luck!!!..
ognyanov is offline   Reply With Quote
Old 31/07/2015, 11:32 AM   #7
Dragonic
Big Clucker
 
Join Date: Jul 2015
Location: Brazil
Posts: 94
Reputation: 1
Default Re: [Help] How to create races?

I tried a few, none worked... I'm trying something else
Dragonic is offline   Reply With Quote
Old 31/07/2015, 01:43 PM   #8
PMH
Huge Clucker
 
Join Date: Jun 2014
Location: Pakistan
Posts: 216
Reputation: 24
Default Re: [Help] How to create races?

Quote:
Originally Posted by Dragonic View Post
I tried a few, none worked... I'm trying something else
Use Rryder's racing filterscript. Its the best one out there wothout any bigs. U gotta search it though
PMH is offline   Reply With Quote
Old 31/07/2015, 02:32 PM   #9
Dragonic
Big Clucker
 
Join Date: Jul 2015
Location: Brazil
Posts: 94
Reputation: 1
Default Re: [Help] How to create races?

I tried! But when I downloaded it only gave me .pwn and when I tried to compile it I received 2 errors
Dragonic is offline   Reply With Quote
Old 31/07/2015, 06:08 PM   #10
Dragonic
Big Clucker
 
Join Date: Jul 2015
Location: Brazil
Posts: 94
Reputation: 1
Default Re: [Help] How to create races?

Tried Ryder's once again... Dunno what happend but it don't create the race...
Can someone please give me an example on how to when the player go through one CP, another will appear..
Dragonic is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[FilterScript] Random Race Generator (RouteConnector Contest) --- Create randomized races dynamically! Basssiiie Filterscripts 122 30/12/2016 10:07 PM
How To Create Races? misho1 Scripting Help 2 28/06/2012 04:17 AM
[FilterScript] Create races Ingame [Simple] - With GUI denNorske Filterscripts 13 28/04/2012 09:31 PM
HELP - races deather Help Archive 2 17/01/2010 10:49 AM


All times are GMT. The time now is 12:21 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.