Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Topics - MEGAMIND
1
Script and Content Requests / Drift Counter
« on October 7th, 07:25 PM »
Hello everyone, can anyone make a drift counter?
Like samp + when a drift reaches to a specific drift score so an event happens to a car like if drift score reaches to 500 then car color changes..
Ty
2
Skin Showroom / New Tommy Model (CJ Styled)
« on October 3rd, 08:33 AM »
Content Type: Skin
Original Author: Megamind
Source Link: My own hands
Modifications:: A small replica near to CJ body layout for vcmp
Modified By: Megamind
Authorized By Original Author?: Megamind
Content Screenshots:


I was damn tired of Cj wearing a west and black color all the time, today i decided to do some major/minor updates to cj body with current tommy skin, used a dff editor to give a proper look to tommy outlooks, although some textures were not possible while desining this model as u can see his arms have sharp edges along with pants (legs), which i couldnt make it squeezed as like cj has

so below are the images, showing my work on it
CJS head tried my best to squeeze


side by side comparison


here u can see as i couldnt convert arms properly they have sharp edges but still looks better



Download:
3
Weapon Showroom / Wrench
« on October 3rd, 05:42 AM »
Content Type: Weapon
Original Author: Simba
Source Link: https://www.gtaall.com/gta-san-andreas/weapons/51490-wrench.html
Modifications:: Changed Textures/Converted To VC & Created XML Files
Modified By: Megamind
Authorized By Original Author?: (Couldn't get in touch with him!)
Content Screenshots:


Download:
4
Object Showroom / Stunt Tubes
« on October 2nd, 11:20 AM »
Content Type: Object
Original Author: therainycat (SA-MP)
Source Link: https://dev.prineside.com/en/gtasa_samp_model_id/category/stunt-tubes/
Modifications:: Changed Textures/Converted To VCMP & Created XML Files
Modified By: Megamind
Authorized By Original Author?: (Couldn't get in touch with him!)
Content Screenshots




store/objects/objects.xml
Code: [Select]
<?xml version="1.0" encoding="ASCII"?>
<objectlist>
<object id="12">
<model path="Tube50m90Bend1.dff" distance="300" />
<texture path="MatTextures.txd" />
<collision type="autogenerate" />
<flags value="0" />
</object>
<object id="13">
<model path="Tube100m2.dff" distance="300" />
<texture path="MatTextures.txd" />
<collision type="autogenerate" />
<flags value="0" />
</object>
<object id="14">
<model path="RB50mBend90Tube.dff" distance="300" />
<texture path="MickyTextures.txd" />
<collision type="autogenerate" />
<flags value="0" />
</object>
<object id="15">
<model path="RBFunnel.dff" distance="300" />
<texture path="MickyTextures.txd" />
<collision type="autogenerate" />
<flags value="0" />
</object>
<object id="16">
<model path="RT50mBend180Tube1.dff" distance="300" />
<texture path="MickyTextures.txd" />
<collision type="autogenerate" />
<flags value="0" />
</object>
<object id="17">
<model path="Tube50mGlassBulge1.dff" distance="300" />
<texture path="MatTextures.txd" />
<collision type="autogenerate" />
<flags value="0" />
</object>
</objectlist>


server/scripts/main.nut
Code: [Select]
function onScriptLoad()
{
    dofile("scripts/tubes.nut");
}


server/scripts/tubes.nut
Code: [Select]
//============================ Crazy tube ===================================
CreateObject(6013,1,Vector(-1736.63, -771.474, 18.868),255).RotateToEuler(Vector(0, 0, 0),1);
CreateObject(6013,1,Vector(-1736.7, -871.13, 21.2782),255).RotateToEuler(Vector(-0.00339236, -0.0498846, 8.46159e-05),1);
CreateObject(6013,1,Vector(-1736.62, -970.173, 28.7132),255).RotateToEuler(Vector(0.000867779, -0.0997809, 0.000120437),1);
CreateObject(6013,1,Vector(-1736.79, -1064.31, 52.5367),255).RotateToEuler(Vector(-0.0258391, -0.399074, 0.00522566),1);
CreateObject(6012,1,Vector(-1727.97, -1131.81, 72.1844),255).RotateToEuler(Vector(0.881488, 1.24671, 0.507345),1);
CreateObject(6012,1,Vector(-1692.31, -1156.65, 64.2484),255).RotateToEuler(Vector(-1.73378, -0.399427, 0.0750025),1);
CreateObject(6014,1,Vector(-1656.17, -1163.19, 90.8956),255).RotateToEuler(Vector(1.89521, -1.08779, 1.05909),1);
CreateObject(6013,1,Vector(-1622.74, -1099.13, 99.5885),255).RotateToEuler(Vector(0, 0, -0.4),1);
CreateObject(6016,1,Vector(-1586.55, -1040.94, 99.2485),255).RotateToEuler(Vector(2.62117, 0.975284, -1.44568),1);
CreateObject(6017,1,Vector(-1572.37, -1079.63, 104.805),255).RotateToEuler(Vector(0.00808995, 1.25003, 0.00621665),1);
CreateObject(6013,1,Vector(-1572.2, -1150.92, 127.314),255).RotateToEuler(Vector(0.00233752, -0.29999, -0.000353269),1);
CreateObject(6014,1,Vector(-1564.94, -1220.38, 147.552),255).RotateToEuler(Vector(0.288838, 1.21894, 0.641443),1);
CreateObject(6015,1,Vector(-1501.64, -1238.56, 132.177),255).RotateToEuler(Vector(0, 0, 0),1);
CreateObject(6014,1,Vector(-1493.2, -1239.17, 98.3727),255).RotateToEuler(Vector(-0.749423, -0.0249137, 0.00979856),1);
CreateObject(6013,1,Vector(-1421.34, -1238.71, 88.2757),255).RotateToEuler(Vector(0, 0, -1.55),1);
CreateObject(6017,1,Vector(-1347.46, -1236.9, 83.8218),255).RotateToEuler(Vector(-1.39895, 0.0337192, -0.0283715),1);
CreateObject(6016,1,Vector(-1309.85, -1236.09, 77.6991),255).RotateToEuler(Vector(2.44814, -0.00746748, -0.0352396),1);
CreateObject(6017,1,Vector(-1333.84, -1236.38, 55.9735),255).RotateToEuler(Vector(1.54996, 0.00658971, 0.00645413),1);
CreateObject(6017,1,Vector(-1382.77, -1234.78, 49.6675),255).RotateToEuler(Vector(-1.79273, -0.0585342, 0.128975),1);
CreateObject(6016,1,Vector(-1423.29, -1246.4, 45.9716),255).RotateToEuler(Vector(0.191935, -1.46532, -0.172786),1);
CreateObject(6013,1,Vector(-1365.21, -1277.91, 42.102),255).RotateToEuler(Vector(3.14159, 3.14159, -1.29159),1);
CreateObject(6013,1,Vector(-1268.86, -1302.35, 36.963),255).RotateToEuler(Vector(0.0132791, 0.0870008, 1.35013),1);
CreateObject(6017,1,Vector(-1197.15, -1310.46, 31.3525),255).RotateToEuler(Vector(1.58583, -0.0973558, -0.0901966),1);
CreateObject(6013,1,Vector(-1123.65, -1304.52, 23.1159),255).RotateToEuler(Vector(0.0820606, -0.0680322, -1.5002),1);
CreateObject(6014,1,Vector(-1056.47, -1300.32, 29.1329),255).RotateToEuler(Vector(-2.54095, -3.1267, -0.0538024),1);
CreateObject(6012,1,Vector(-1070.38, -1303.94, 63.5125),255).RotateToEuler(Vector(1.87052, -0.185655, -0.104672),1);
CreateObject(6017,1,Vector(-1115.05, -1310.08, 64.1291),255).RotateToEuler(Vector(-1.65225, 0.0811583, -0.0492312),1);
CreateObject(6013,1,Vector(-1188.56, -1318.05, 61.9588),255).RotateToEuler(Vector(0, 0, -1.45),1);
CreateObject(6013,1,Vector(-1287.15, -1322.51, 61.8223),255).RotateToEuler(Vector(3.14159, 3.14159, -1.5416),1);
CreateObject(6012,1,Vector(-1354.79, -1308.26, 62.1545),255).RotateToEuler(Vector(-0.217251, -1.36477, 0.733058),1);
CreateObject(6017,1,Vector(-1366, -1263.77, 64.6008),255).RotateToEuler(Vector(0.007288, -1.5499, -0.00854527),1);
CreateObject(6013,1,Vector(-1365.7, -1189.14, 65.0555),255).RotateToEuler(Vector(0, 0, 0),1);
CreateObject(6013,1,Vector(-1365.61, -1090.6, 72.4774),255).RotateToEuler(Vector(0.0133786, 0.149393, 0.00100122),1);
CreateObject(6012,1,Vector(-1352.69, -1019.91, 85.4313),255).RotateToEuler(Vector(0.226591, -1.27598, -0.511771),1);
CreateObject(310,1,Vector(-1363.73, -1041.58, 75.0483),255).RotateToEuler(Vector(-1.53366, 0.129359, -0.124654),1);
CreateObject(310,1,Vector(-1375.19, -1041.23, 84.6394),255).RotateToEuler(Vector(1.59822, 0.0111175, 0.161289),1);
CreateObject(310,1,Vector(-1370.71, -1040.69, 75.4237),255).RotateToEuler(Vector(-1.52034, -0.214482, -0.101798),1);
CreateObject(310,1,Vector(-1355.22, -1039.21, 76.5612),255).RotateToEuler(Vector(-1.57943, 0.143588, -0.144829),1);
CreateObject(310,1,Vector(-1357.77, -1039.42, 75.6242),255).RotateToEuler(Vector(-1.54592, 0.390481, -0.137614),1);
CreateObject(6016,1,Vector(-1324.41, -984.508, 86.4134),255).RotateToEuler(Vector(-3.06592, -1.51221, -0.230613),1);
CreateObject(6016,1,Vector(-1415.43, -992.753, 87.3116),255).RotateToEuler(Vector(0.00126956, 1.6, 0.00130744),1);
CreateObject(6015,1,Vector(-1372.86, -974.95, 66.3932),255).RotateToEuler(Vector(0, 0, 0),1);
CreateObject(6014,1,Vector(-1381.13, -974.176, 33.2354),255).RotateToEuler(Vector(-2.37784, 3.04972, 0.131483),1);
CreateObject(6013,1,Vector(-1450.49, -964.945, 27.9704),255).RotateToEuler(Vector(3.09031, 2.99096, -1.44109),1);
CreateObject(6013,1,Vector(-1548.92, -946.943, 33.0642),255).RotateToEuler(Vector(3.14159, 3.14159, -1.34159),1);
CreateObject(6015,1,Vector(-1588.1, -938.062, 32.7163),255).RotateToEuler(Vector(1.52896, 0.269308, 0.263501),1);
CreateObject(6015,1,Vector(-1611.25, -931.69, 33.1052),255).RotateToEuler(Vector(1.6688, -2.83994, -0.251683),1);
CreateObject(6014,1,Vector(-1622.67, -922.865, 33.5135),255).RotateToEuler(Vector(0.0214364, -1.56102, 0.673423),1);
CreateObject(6013,1,Vector(-1629.31, -848.649, 31.2349),255).RotateToEuler(Vector(-0.0042261, -0.0498208, 0.000105288),1);
CreateObject(6013,1,Vector(-1629.29, -748.946, 26.2102),255).RotateToEuler(Vector(0.00233275, -0.0499455, -5.82636e-05),1);
CreateObject(6012,1,Vector(-1380.12, -1021.14, 83.8079),255).RotateToEuler(Vector(2.66119, 1.17715, -0.54691),1);
CreateObject(310,1,Vector(-1370.76, -1039.42, 74.3962),255).RotateToEuler(Vector(-1.49415, 0.300391, -0.241268),1);
CreateObject(310,1,Vector(-1378.12, -1040.46, 73.7759),255).RotateToEuler(Vector(0, 0, 0),1);
CreateObject(310,1,Vector(-1399.74, -1008.04, 81.5586),255).RotateToEuler(Vector(0.350515, -1.06228, -0.0386513),1);
CreateObject(310,1,Vector(-1396.03, -1001.23, 78.7681),255).RotateToEuler(Vector(-1.55905, 1.48579, -0.035627),1);
CreateObject(310,1,Vector(-1396.53, -1004.48, 81.7681),255).RotateToEuler(Vector(-1.50521, -0.0530895, 0.0174186),1);
CreateObject(310,1,Vector(-1399.44, -1005.93, 82.8063),255).RotateToEuler(Vector(0.381509, -0.956245, -0.0411209),1);
CreateObject(310,1,Vector(-1396.32, -1006.2, 78.2348),255).RotateToEuler(Vector(0, 0, 1.55),1);
CreateObject(310,1,Vector(-1396.33, -1006.55, 77.3269),255).RotateToEuler(Vector(-1.86721, -0.993057, -0.766526),1);
CreateObject(310,1,Vector(-1399.48, -1010.91, 82.6097),255).RotateToEuler(Vector(-1.47616, 1.31438, 0.00190103),1);


Download:

Goto airport and enjoy, or even create your own stunt / funland..!

Video: Clicky
5
Snippet Showroom / swim system
« on October 2nd, 04:08 AM »
A bit updated and better swim system then previous version

Code: [Select]
function onScriptLoad()
{
swimming <- array(100,false)
I <- BindKey(true, 0x49,0,0); // forward
J <- BindKey(true, 0x4A,0,0); // left
K <- BindKey(true, 0x4B,0,0); // back
L <- BindKey(true, 0x4C,0,0); //right
O <- BindKey(true, 0x4F,0,0); //jump
}

function onPlayerHealthChange( player, lastHP, newHP )
{
if ( (player.Pos.z <= GetWaterLevel()) && (swimming[player.ID] == false))
{
MessagePlayer( "[#ff00ff]=======(Jump in Water)=======", player );
MessagePlayer( "[#ffffff]USE I, J, K, L, O for movement in water", player );
swimming[player.ID] = true
return true;
}
player.Health = 100;
player.SetAnim(0,149);
local vector1 = Vector ( player.Pos.x+10, player.Pos.y, player.Pos.z+5 ), vector2 = Vector ( player.Pos.x, player.Pos.y, player.Pos.z );
player.SetCameraPos( vector1, vector2 );
}

function onKeyDown( player, key )
{
if( key == I )
{
if ( player.Pos.z <= GetWaterLevel() ) {
 player.Pos.x++;
       }
}
if( key == J )
{
if ( player.Pos.z <= GetWaterLevel() ) {
     player.Pos.y++;
       }
}
if( key == K )
{
if ( player.Pos.z <= GetWaterLevel() ) {
player.Pos.x--;
 }
}
if( key == L )
{
if ( player.Pos.z <= GetWaterLevel() ) {
 player.Pos.y--;
       }
}

//==jump out of water and change directions==============
if( key == O )
{
if ( player.Pos.z <= GetWaterLevel() ) {
 player.Pos.z++;
player.RestoreCamera();
}
}
}
Features:
1.Everything is same (swimstyle , movement keys).
2.While swimming Screen camera moves like as if ur being spectated.
3.Players Glitching into falls and other stuff is fixed.

Credits: @UrbanY
Quote
To avoid the abuse of players like evade among other things (Glitching everywhere..)
6
Snippet Showroom / Vehicles Neons
« on September 30th, 09:46 AM »
Thanks to @Athanatos and @!
 
Vehicles Neons some how became possible, as i mentioned here about the details and some conversation along with few ppl
That this system is actually not that good as it looks like, we do need a proper neon system like the ones in samp (Only depends on Devs)

Dev's dont mind but ill like to have this feature like vcmp having its own custom objecs, pickups etc etc along with attach deattach stuff and proper sync btw it, IDK if its possible yet but who knows maybe one day we will have it too, so here it is how to do it

Code: [Select]
function onScriptLoad()
{
dofile("scripts/attach_sys.nut");
neon <- CreateObject( 338, 1, -426.066, 32.066, 26.5326 , 255);
neoncar <- CreateVehicle( 141, 1, -426.066, 32.066, 26.5326, 0, -1 , -1 );
}

function onPlayerCommand( player, cmd, text )
{
        if(cmd == "n") {
player.Pos =  Vector( -426.066, 32.066+5, 26.5326 );
}

else MessagePlayer( "Error - Unknown command !",player);
}


function onPlayerEnterVehicle( player, vehicle, door )
{
attachEntity( neon, neoncar, Vector(0,0,-1) );
}



you will need to have this snippet https://forum.vc-mp.org/?topic=6224.msg43116#msg43116 in order to make it work
7
General Discussion / Custom vehicle sound
« on September 30th, 08:28 AM »
As topic says sounds for custom vehicles, ive tried alot to do it like lw's the way how they did it here



but cant figure out how does it work,

i mean ic rc necessary to add cuz not bcz they just wrote it like that "rcengine", or is there specific something while adding a wav file to custom vehicles?
8
Bugs and Crashes / X2 grenades
« on September 27th, 10:04 AM »
Subject: [Bug] X2 Grenades throwing

What you were doing at the time of the crash
playing together

What you think caused the crash
IDK

Are you using the Steam version?
No.
https://streamable.com/tuwm5
9
General Discussion / help here if n else
« on September 22nd, 04:59 PM »
suppose i have a code

Code: [Select]
function onPlayerSpawn( player )
{

if ( player.World != 24) {
player.World = 1;
}
else
{
if(something == something) { player.Pos = Vector(  -1734.98,-1725.85,14.868 ); player.Colour = RGB(255, 0, 0); player.Skin = 73; }
else if (something == something) { player.Pos = Vector(-1099.68,1393.21,8.73682); player.Colour = RGB(0, 0, 255); player.Skin = 95; }
return;
}

 if ( player.World != 27 ) {
player.World = 1;
}

else {
if (something == something) { player.Pos = Vector( 605.065,-745.095,11.0712 ); player.Colour = RGB(255, 0,255);player.Skin = 90; }
else if (something == something) { player.Pos = Vector(600.586,-937.486,11.972);player.Colour = RGB(0, 255, 255);player.Skin = 145; }
return;
}
}

these both codes are same just world are different

am i using the statements correctly?
bcz they r not working as expected, for example if a player dies in world 24 he should spawn in same world and 27 world player should spawn in 27 but they dont
10
Script Showroom / Knsas race system (Modified-Drift version)
« on September 19th, 06:19 PM »
==========================Heres goes same script but a bit more modified============================
Details:
Ksna's  RACE SYSTEM modified using checkpoints

Original Post here
https://forum.vc-mp.org/?topic=1078.0

someone who tried to modify it using checkpoint but didnt worked as it was left abandoned
https://forum.vc-mp.org/?topic=1174.msg7890#msg7890

at the END MEGAMIND fixed it for newbiews
Features:
1. used ksna's race script
2. Added checkpoints and modifed it porperly
3. redesigned from scratch
4.Added Drift cars
5.race ends using checkpoint not a pickup

main.nut
Code: [Select]
//======================== TOP OF SCRIPT ============================

//================== Drift Race====================
class PlayerClass{
 raceplayer = false;
 check0 = false;
check1 = false;
check2 = false;
check3 = false;
check4 = false;
check5 = false;
check6 = false;
check7 = false;
check8 = false;
check9 = false;
check10 = false;
}


function onScriptLoad()
{
dofile( "scripts/Cmds.nut" );

pVehicle <- array( GetMaxPlayers(), null );
driftcarraceVeh <- array( GetMaxPlayers(), null );
driftcarraceVehLocationsIdx <- 0;
driftcarraceVehVectors <- [    Vector(-24.0036,973.773,10.9403), Vector(-24.9422,964.929,10.9403), Vector(-34.3871,966.302,10.9403), Vector(-33.1926,972.686,10.9403)];
driftcarraceVehAngles <- [    -1.7153,-1.7153,-1.7153,-1.7153,];

race <- false;
racecount <- 0;
racestart <- false;
 
stats <- array( GetMaxPlayers(), null );
print( "Drift Race System Loaded." );
}


function onPlayerJoin( player )
{
CreateCheckpoint( null, 26, false,Vector( 10.1409, 963.899, 10.9402 ), RGB(225, 0, 255), 6); //37
CreateCheckpoint( null, 26, false,Vector( -231.318, 1079.07, 20.147 ), RGB(225, 0, 255), 6);//38
CreateCheckpoint( null, 26, false,Vector( -397.966, 1067.51, 12.9971 ), RGB(225, 0, 255), 6);//39
CreateCheckpoint( null, 26, false,Vector( -488.76, 771.059, 10.3594 ), RGB(225, 0, 255), 6);//40
CreateCheckpoint( null, 26, false,Vector( -636.525, 548.756, 10.592 ), RGB(225, 0, 255), 6);//41
CreateCheckpoint( null, 26, false,Vector( -738.273, 158.318, 10.6376 ), RGB(225, 0, 255), 6);//42
CreateCheckpoint( null, 26, false,Vector( -843.745, -289.459, 10.4258 ), RGB(225, 0, 255), 6);//43
CreateCheckpoint( null, 26, false,Vector( -825.032, -774.582, 10.4491 ), RGB(225, 0, 255), 6);//44
CreateCheckpoint( null, 26, false,Vector( -971.792, -1073.91, 14.217 ), RGB(225, 0, 255), 6);//45
CreateCheckpoint( null, 26, false,Vector( -1200.94, -862.164, 14.2198 ), RGB(225, 0, 255), 6);//46
CreateCheckpoint( null, 26, false,Vector( -1247.47, -784.685, 14.217 ), RGB(225, 0, 255), 6);//47
CreateCheckpoint( null, 26, false,Vector( -1458.03,-783.488,14.6999 ), ARGB(255, 255, 0, 0), 6);//48 end drace

stats[ player.ID ] = PlayerClass( player.Name );
}

function onPlayerTeamKill( player, killer, reason, bodypart )
{
onPlayerKill( killer, killed, weapon, bodypart );
}

function onPlayerExitVehicle( player, vehicle )
{
  if ( stats[player.ID].raceplayer ){ vehicle.Locked = false; player.Vehicle = vehicle; vehicle.Locked = true; }
}

function onPlayerDeath( player, reason )
{
if ( stats[ player.ID ].raceplayer ) {
 racecount--;
 Message( ">> " + player.Name + " is out of the race." );
    if ( racecount == 0 ) closerace();
 stats[ player.ID ].raceplayer = false;
    }
}




function raceplayers()
{
     if ( racecount > 1 )
  {
  NewTimer( "Ann", 1000, 1, "3" );
  NewTimer( "Ann", 2000, 1, "2" );
  NewTimer( "Ann", 3000, 1, "1" );
  } else closerace();
}

function Ann( number )
{
       for( local i=0; i <= GetMaxPlayers(); i++ )
  {
   local plr = FindPlayer( i );
      if ( ( plr ) && ( stats[ plr.ID ].raceplayer ) )
                        {
      switch( number.tointeger() )
          {
       case 1:
       Announce( "1", plr );
       startrace();
       Announce( "Go!", plr );
       break;
       
       case 2:
       Announce( "2", plr );
       break;
       
       case 3:
       Announce( "3", plr );
       break;
          }
      }
  }
}


function startrace()
{
    racestart = true;
  CreatePickup(301, 26, 1, Vector(-1435.9, -790.299, 14.6437), 255, true);
 CreateMarker(26, Vector( -1435.9, -790.299, 14.6437  ), 5,RGB(255, 255, 0),2);
 local plr;
       for( local i=0; i <= GetMaxPlayers(); i++ )
  {
  {
      plr = FindPlayer( i );
      if ( ( plr ) && ( stats[ plr.ID ].raceplayer ) )
                {
                    plr.IsFrozen = false;
                }
        }
 }
}

function closerace() {
    Message( "Race cancelled!" );
    race = false;
 racestart = false;
    racecount = 0;
    local plr;
     for( local i=0; i <= GetMaxPlayers(); i++ ){
  {
      plr = FindPlayer( i );
      if ( plr )
            {
    if( stats[ plr.ID ].raceplayer )
    {
                    stats[ plr.ID ].raceplayer = false;
                    plr.IsFrozen = false;
                    plr.Pos = Vector( 496.26, -83.9443, 10.0302  );
    }
            }
        }
 }

}


function onCheckpointEntered( player, checkpoint )
     {
if ( checkpoint.ID == 0 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else if ( stats[ player.ID ].check0 == true ) PrivMessage( player, "You already pickup CheckPoint ID 0");
else
{
stats[ player.ID ].check0 = true;
PrivMessage( player, "Checkpoint 0 Pick Up Sucessfully 0/10");
}
}
if ( checkpoint.ID == 1 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else if ( stats[ player.ID ].check1 == true ) PrivMessage( player, "You already pickup CheckPoint ID 1");
else if ( stats[ player.ID ].check0 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 0");
else
{
stats[ player.ID ].check1 = true;
PrivMessage( player, "Checkpoint 1 Pick Up Sucessfully 1/10");
}
}
if ( checkpoint.ID == 2 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check2 == true ) PrivMessage( player, "You already pickup CheckPoint ID 2");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check2 = true;
PrivMessage( player, "Checkpoint 2 Pick Up Sucessfully 2/10");
}
}
if ( checkpoint.ID == 3 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check3 == true ) PrivMessage( player, "You already pickup CheckPoint ID 3");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 2");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check3 = true;
PrivMessage( player, "Checkpoint 3 Pick Up Sucessfully 3/10");
}
}
if ( checkpoint.ID == 4 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check4 == true ) PrivMessage( player, "You already pickup CheckPoint ID 4");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 2");
else if ( stats[ player.ID ].check3 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 3");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check4 = true;
PrivMessage( player, "Checkpoint 4 Pick Up Sucessfully 4/10");
}
}
if ( checkpoint.ID == 5 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check5 == true ) PrivMessage( player, "You already pickup CheckPoint ID 5");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 2");
else if ( stats[ player.ID ].check3 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 3");
else if ( stats[ player.ID ].check4 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 4");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check5 = true;
PrivMessage( player, "Checkpoint 5 Pick Up Sucessfully 5/10");
}
}
if ( checkpoint.ID == 6 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check6 == true ) PrivMessage( player, "You already pickup CheckPoint ID 6");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 2");
else if ( stats[ player.ID ].check3 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 3");
else if ( stats[ player.ID ].check4 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 4");
else if ( stats[ player.ID ].check5 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 5");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check6 = true;
PrivMessage( player, "Checkpoint 6 Pick Up Sucessfully 6/10");
}
}
if ( checkpoint.ID == 7 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check7 == true ) PrivMessage( player, "You already pickup CheckPoint ID 7");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 2");
else if ( stats[ player.ID ].check3 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 3");
else if ( stats[ player.ID ].check4 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 4");
else if ( stats[ player.ID ].check5 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 5");
else if ( stats[ player.ID ].check6 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 6");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check7 = true;
PrivMessage( player, "Checkpoint 7 Pick Up Sucessfully 7/10");
}
}
if ( checkpoint.ID == 8 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check8 == true ) PrivMessage( player, "You already pickup CheckPoint ID 8");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 2");
else if ( stats[ player.ID ].check3 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 3");
else if ( stats[ player.ID ].check4 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 4");
else if ( stats[ player.ID ].check5 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 5");
else if ( stats[ player.ID ].check6 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 6");
else if ( stats[ player.ID ].check7 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 7");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check8 = true;
PrivMessage( player, "Checkpoint 8 Pick Up Sucessfully 8/10");
}
}
if ( checkpoint.ID == 9 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check9 == true ) PrivMessage( player, "You already pickup CheckPoint ID 9");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 2");
else if ( stats[ player.ID ].check3 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 3");
else if ( stats[ player.ID ].check4 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 4");
else if ( stats[ player.ID ].check5 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 5");
else if ( stats[ player.ID ].check6 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 6");
else if ( stats[ player.ID ].check7 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 7");
else if ( stats[ player.ID ].check8 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 8");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check9 = true;
PrivMessage( player, "Checkpoint 9 Pick Up Sucessfully 9/10");
}
}
if ( checkpoint.ID == 10 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check10 == true ) PrivMessage( player, "You already pickup CheckPoint ID 10");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 2");
else if ( stats[ player.ID ].check3 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 3");
else if ( stats[ player.ID ].check4 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 4");
else if ( stats[ player.ID ].check5 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 5");
else if ( stats[ player.ID ].check6 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 6");
else if ( stats[ player.ID ].check7 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 7");
else if ( stats[ player.ID ].check8 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 8");
else if ( stats[ player.ID ].check9 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 9");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check10 = true;
PrivMessage( player, "Checkpoint 10 Pick Up Sucessfully 10/10");
PrivMessage( player, "Now Move to Airport for Win");
}
}

if ( checkpoint.ID == 11 )
{
 if ( !stats[ player.ID ].raceplayer ) PrivMessage( player, "You are not in race");
 else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check3 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check4 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check5 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check6 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check7 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check8 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check9 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check10 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else
{
player.Cash+=1000;
   Message( player.Name + " have got 1000$.");
   Message( ""+player.Name+" has won ." );
   closerace();
   player.World = 1;
}
}

}


Cmds.nut
Code: [Select]
function onPlayerCommand( player, cmd, text )
{
if ( cmd == "drace" ) {
        if ( driftcarraceVehLocationsIdx >= 4 ) {
            driftcarraceVehLocationsIdx = 0;
        }
       
        if ( driftcarraceVeh[ player.ID ] != null ) {
            driftcarraceVeh[ player.ID ].Remove();
            driftcarraceVeh[ player.ID ] = null;
        }
        player.World = 26;
        driftcarraceVeh[ player.ID ] = CreateVehicle( 6401, 26, driftcarraceVehVectors[ driftcarraceVehLocationsIdx ], driftcarraceVehAngles[ driftcarraceVehLocationsIdx ], -1, -1 );
        player.Vehicle = driftcarraceVeh[ player.ID ];
       driftcarraceVehLocationsIdx++;
  race = true;
   Message("Race is started by "+ player.Name +", to join the race [USAGE /drace].");
   MessagePlayer("type /draceready to prepare your self for drift race",player);
  Message("Film Studio to Airport race started.");
}

 else if( cmd == "draceready") {
 player.World = 26;
 if ( !player.Spawned )MessagePlayer("Spawn to use this command" player);
 else if ( !race ) MessagePlayer("Race is not started do /startdrace", player);
 else if ( stats[player.ID].raceplayer ) MessagePlayer("You already joined race.",player);
 else if ( racecount > 4 ) MessagePlayer("Too Late! Only 4 players can race at once", player);
 else if ( racestart ) MessagePlayer("Too Late!", player);
 else {
  racecount++;
  player.Frozen = true;
  stats[player.ID].raceplayer = true;
  Message(""+ player.Name +" has joined race.")
  NewTimer( "ClientMessageToAll", 15000, 1, "-----> (Anyone) /startdrace <------",1000, 1500, 300 );
 }
 }
 
 if(cmd == "startdrace"){
 player.World = 26;
NewTimer( "ClientMessageToAll", 1000, 1, "-> 3",28, 255, 11 );
        NewTimer( "ClientMessageToAll", 2000, 1, "-> 2",24, 255, 241 );
        NewTimer( "ClientMessageToAll", 3000, 1, "-> 1",249, 57, 56 );
        NewTimer( "ClientMessageToAll", 4000, 1, "-----> START <------",1000, 1500, 300 );
for (local i=0; i<GetMaxPlayers(); i++)
{
local p=FindPlayer(i);
if(p)
{
p.IsFrozen = false;
}
}
       

 }
 }


If still find any Bug do let me know,

Note: Pro scripters out there, pls stay away as we cant reach ur level, Secondly newbies if u guys have any issue do let me know!

Download
11
Script Showroom / Knsas race system (Modified)
« on September 19th, 06:09 PM »
Details:
Ksna's  RACE SYSTEM modified using checkpoints

Original Post here
https://forum.vc-mp.org/?topic=1078.0

someone who tried to modify it using checkpoint but didnt worked as it was left abandoned
https://forum.vc-mp.org/?topic=1174.msg7890#msg7890

at the END MEGAMIND fixed it for newbiews
Features:
1. used ksna's race script
2. Added checkpoints and modifed it

main.nut
Code: [Select]
class PlayerClass{
 raceplayer = false;
 check0 = false;
check1 = false;
check2 = false;
check3 = false;
check4 = false;
check5 = false;
check6 = false;
check7 = false;
check8 = false;
check9 = false;
check10 = false;
}

function onScriptLoad(){
CreateCheckpoint( null, 1, false,Vector( 10.1409, 963.899, 10.9402 ), RGB(225, 0, 255), 6);
CreateCheckpoint( null, 1, false,Vector( -231.318, 1079.07, 20.147 ), RGB(225, 0, 255), 6);
CreateCheckpoint( null, 1, false,Vector( -397.966, 1067.51, 12.9971 ), RGB(225, 0, 255), 6);
CreateCheckpoint( null, 1, false,Vector( -488.76, 771.059, 10.3594 ), RGB(225, 0, 255), 6);
CreateCheckpoint( null, 1, false,Vector( -636.525, 548.756, 10.592 ), RGB(225, 0, 255), 6);
CreateCheckpoint( null, 1, false,Vector( -738.273, 158.318, 10.6376 ), RGB(225, 0, 255), 6);
CreateCheckpoint( null, 1, false,Vector( -843.745, -289.459, 10.4258 ), RGB(225, 0, 255), 6);
CreateCheckpoint( null, 1, false,Vector( -825.032, -774.582, 10.4491 ), RGB(225, 0, 255), 6);
CreateCheckpoint( null, 1, false,Vector( -971.792, -1073.91, 14.217 ), RGB(225, 0, 255), 6);
CreateCheckpoint( null, 1, false,Vector( -1200.94, -862.164, 14.2198 ), RGB(225, 0, 255), 6);
CreateCheckpoint( null, 1, false,Vector( -1247.47, -784.685, 14.217 ), RGB(225, 0, 255), 6);
 race <- false;
 racecount <- 0;
 racestart <- false;
 
 stats <- array( GetMaxPlayers(), null );
 print( "Drift Race System Loaded." );
 
 driftcar1 <- CreateVehicle( 141, 1, -426.066, 32.066, 26.5326, 0, -1 , -1 );
 driftcar2 <- CreateVehicle( 141, 1, -426.066, 32.066, 26.5326, 0, -1 , -1 );
 driftcar3 <- CreateVehicle( 141, 1, -426.066, 32.066, 26.5326, 0, -1 , -1 );
 driftcar4 <- CreateVehicle( 141, 1, -426.066, 32.066, 26.5326, 0, -1 , -1 );
 print( "driftcar1 vehicle ID is : "+driftcar1.ID );
 print( "driftcar2 vehicle ID is : "+driftcar2.ID );
 print( "driftcar3 vehicle ID is : "+driftcar3.ID );
 print( "driftcar4 vehicle ID is : "+driftcar4.ID );
dofile("scripts/cmds.nut");
}

function onPlayerTeamKill( killer, killed, weapon, bodypart )
{
onPlayerKill( killer, killed, weapon, bodypart );
}

function onPlayerKill( killer, player, reason, bodypart )
{
if ( stats[ player.ID ].raceplayer ) {
 racecount--;
 Message( ">> " + player.Name + " is out of the race." );
    if ( racecount == 0 ) closerace();
 stats[ player.ID ].raceplayer = false;
    }
Message( ""+killer.Name + " has been drowned Reason: Stop killing racing players " );
  Killer.Pos = Vector( -597.7496,-1858.9531,28.1291 );

}

function onPlayerDeath( player, reason )
{
   if ( stats[ player.ID ].raceplayer ) {
 racecount--;
 Message( ">> " + player.Name + " is out of the race." );
    if ( racecount == 0 ) closerace();
 stats[ player.ID ].raceplayer = false;
    }
}


function onPlayerPart( player, reason )
{
 if ( stats[ player.ID ].raceplayer ) {
 racecount--;
 Message( ">> " + player.Name + " is out of the race." );
    if ( racecount == 0 ) closerace();
 stats[ player.ID ].raceplayer = false;
    }
}

function onPlayerJoin( player ){
 stats[ player.ID ] = PlayerClass( player.Name );
}

function onPlayerExitVehicle( player, vehicle ) {
 if ( stats[player.ID].raceplayer ){ vehicle.Locked = false; player.Vehicle = vehicle; vehicle.Locked = true; } // By Karan

}




function raceplayers()
{
     if ( racecount > 1 )
  {
  NewTimer( "Ann", 1000, 1, "3" );
  NewTimer( "Ann", 2000, 1, "2" );
  NewTimer( "Ann", 3000, 1, "1" );
  } else closerace();
}

function Ann( number )
{
       for( local i=0; i <= GetMaxPlayers(); i++ )
  {
   local plr = FindPlayer( i );
      if ( ( plr ) && ( stats[ plr.ID ].raceplayer ) )
                        {
      switch( number.tointeger() )
          {
       case 1:
       Announce( "1", plr );
       startrace();
       Announce( "Go!", plr );
       break;
       
       case 2:
       Announce( "2", plr );
       break;
       
       case 3:
       Announce( "3", plr );
       break;
          }
      }
  }
}


function startrace()
{
    racestart = true;
 CreatePickup( 382, Vector( -1435.9, -790.299, 14.6437 ) );
 CreateMarker(1, Vector( -1435.9, -790.299, 14.6437  ), 5,RGB(255, 255, 0),2);
 local plr;
       for( local i=0; i <= GetMaxPlayers(); i++ )
  {
  {
      plr = FindPlayer( i );
      if ( ( plr ) && ( stats[ plr.ID ].raceplayer ) )
                {
                    plr.IsFrozen = false;
                }
        }
 }
}

function closerace() {
    Message( "Race cancelled!" );
    race = false;
 racestart = false;
    racecount = 0;
    local plr;
     for( local i=0; i <= GetMaxPlayers(); i++ ){
  {
      plr = FindPlayer( i );
      if ( plr )
            {
    if( stats[ plr.ID ].raceplayer )
    {
                    stats[ plr.ID ].raceplayer = false;
                    plr.IsFrozen = false;
                    plr.Pos = Vector( 496.26, -83.9443, 10.0302  );
    }
            }
        }
 }

}


function onPickupPickedUp( player, pickup )
{   
   if ( pickup.Model == 382 )
 {
  if ( !stats[ player.ID ].raceplayer ) PrivMessage( player, "You are not in race");
  else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check3 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check4 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check5 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check6 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check7 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check8 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check9 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else if ( stats[ player.ID ].check10 == false ) PrivMessage( player, "You need to pickup last pickup to pickup this");
else
  {
  player.Cash+=1000;
   Message( player.Name + " have got 1000$.");
   pickup.Remove();
   Message( ""+player.Name+" has won ." );
   closerace();
  }
  }
}


function onCheckpointEntered(player, checkpoint)
{
if ( checkpoint.ID == 0 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else if ( stats[ player.ID ].check0 == true ) PrivMessage( player, "You already pickup CheckPoint ID 0");
else
{
stats[ player.ID ].check0 = true;
PrivMessage( player, "Checkpoint 0 Pick Up Sucessfully 0/10");
}
}
if ( checkpoint.ID == 1 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else if ( stats[ player.ID ].check1 == true ) PrivMessage( player, "You already pickup CheckPoint ID 1");
else if ( stats[ player.ID ].check0 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 0");
else
{
stats[ player.ID ].check1 = true;
PrivMessage( player, "Checkpoint 1 Pick Up Sucessfully 1/10");
}
}
if ( checkpoint.ID == 2 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check2 == true ) PrivMessage( player, "You already pickup CheckPoint ID 2");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check2 = true;
PrivMessage( player, "Checkpoint 2 Pick Up Sucessfully 2/10");
}
}
if ( checkpoint.ID == 3 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check3 == true ) PrivMessage( player, "You already pickup CheckPoint ID 3");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 2");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check3 = true;
PrivMessage( player, "Checkpoint 3 Pick Up Sucessfully 3/10");
}
}
if ( checkpoint.ID == 4 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check4 == true ) PrivMessage( player, "You already pickup CheckPoint ID 4");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 2");
else if ( stats[ player.ID ].check3 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 3");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check4 = true;
PrivMessage( player, "Checkpoint 4 Pick Up Sucessfully 4/10");
}
}
if ( checkpoint.ID == 5 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check5 == true ) PrivMessage( player, "You already pickup CheckPoint ID 5");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 2");
else if ( stats[ player.ID ].check3 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 3");
else if ( stats[ player.ID ].check4 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 4");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check5 = true;
PrivMessage( player, "Checkpoint 5 Pick Up Sucessfully 5/10");
}
}
if ( checkpoint.ID == 6 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check6 == true ) PrivMessage( player, "You already pickup CheckPoint ID 6");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 2");
else if ( stats[ player.ID ].check3 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 3");
else if ( stats[ player.ID ].check4 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 4");
else if ( stats[ player.ID ].check5 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 5");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check6 = true;
PrivMessage( player, "Checkpoint 6 Pick Up Sucessfully 6/10");
}
}
if ( checkpoint.ID == 7 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check7 == true ) PrivMessage( player, "You already pickup CheckPoint ID 7");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 2");
else if ( stats[ player.ID ].check3 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 3");
else if ( stats[ player.ID ].check4 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 4");
else if ( stats[ player.ID ].check5 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 5");
else if ( stats[ player.ID ].check6 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 6");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check7 = true;
PrivMessage( player, "Checkpoint 7 Pick Up Sucessfully 7/10");
}
}
if ( checkpoint.ID == 8 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check8 == true ) PrivMessage( player, "You already pickup CheckPoint ID 8");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 2");
else if ( stats[ player.ID ].check3 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 3");
else if ( stats[ player.ID ].check4 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 4");
else if ( stats[ player.ID ].check5 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 5");
else if ( stats[ player.ID ].check6 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 6");
else if ( stats[ player.ID ].check7 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 7");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check8 = true;
PrivMessage( player, "Checkpoint 8 Pick Up Sucessfully 8/10");
}
}
if ( checkpoint.ID == 9 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check9 == true ) PrivMessage( player, "You already pickup CheckPoint ID 9");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 2");
else if ( stats[ player.ID ].check3 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 3");
else if ( stats[ player.ID ].check4 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 4");
else if ( stats[ player.ID ].check5 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 5");
else if ( stats[ player.ID ].check6 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 6");
else if ( stats[ player.ID ].check7 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 7");
else if ( stats[ player.ID ].check8 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 8");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check9 = true;
PrivMessage( player, "Checkpoint 9 Pick Up Sucessfully 9/10");
}
}
if ( checkpoint.ID == 10 )
{
if ( !race ) PrivMessage( player, ":P Race is not started yet" );
else if ( stats[ player.ID ].check10 == true ) PrivMessage( player, "You already pickup CheckPoint ID 10");
else if ( stats[ player.ID ].check1 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 1");
else if ( stats[ player.ID ].check2 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 2");
else if ( stats[ player.ID ].check3 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 3");
else if ( stats[ player.ID ].check4 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 4");
else if ( stats[ player.ID ].check5 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 5");
else if ( stats[ player.ID ].check6 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 6");
else if ( stats[ player.ID ].check7 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 7");
else if ( stats[ player.ID ].check8 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 8");
else if ( stats[ player.ID ].check9 == false ) PrivMessage( player, "You didn't Pickup Checkpoint ID 9");
else if ( stats[ player.ID ].raceplayer == false ) PrivMessage( player, "You are not in any race");
else
{
stats[ player.ID ].check10 = true;
PrivMessage( player, "Checkpoint 10 Pick Up Sucessfully 10/10");
PrivMessage( player, "Now Move to Airport for Win");
}
}
}


cmds.nut
Code: [Select]
function onPlayerCommand( player, cmd, text ){
 
 if( cmd == "race") {
 if( race ) MessagePlayer("Race is already started.. ",player);
 else{
  race = true;
  Message("Race is started by "+ player.Name +", 20sec to join the race.");
  Message("Film Studio to Airport race started.");
  NewTimer( "raceplayers", 20000, 1);
  FindVehicle( 1 ).Pos = Vector( -54.2794, 966.151, 15.9403 );
  FindVehicle( 2 ).Pos = Vector( -54.2794, 956.151, 15.9403 );
  FindVehicle( 3 ).Pos = Vector( -54.2794, 946.151, 15.9403 );
  FindVehicle( 4 ).Pos = Vector( -54.2794, 936.151, 15.9403 );
 }
 }
 else if( cmd == "joinrace") {
 if ( !player.Spawned )MessagePlayer("Spawn to use this command" player);
 else if ( !race ) MessagePlayer("Race is not started do /race", player);
 else if ( stats[player.ID].raceplayer ) MessagePlayer("You already joined race.",player);
 else if ( racecount > 4 ) MessagePlayer("Too Late! Only 4 players can race at once", player);
 else if ( racestart ) MessagePlayer("Too Late!", player);
 else {
  racecount++;
   for( local i=0; i <= racecount; i++ )
  {
  local plr = FindPlayer( i );
   player.Vehicle = FindVehicle( i );
  }
  player.Frozen = true;
  stats[player.ID].raceplayer = true;
  Message(""+ player.Name +" has joined race.")
 }
 }
 
 }


If still find any Bug do let me know, This script aint mine, just was bored so was wandering scripts which were bugged a bit or were incompleted so thought of fixing this one ^^

Note: Pro scripters out there, pls sta away as we cant reach ur level, Secondly newbies if u guys have any issue do let me know!

Download
12
General Discussion / player move
« on September 17th, 06:13 PM »
Can we move a player using bindkeys?
What would be the function
13
General Discussion / car shade
« on September 17th, 01:37 PM »
hellow everyone can we implement car sahde below of a car like neons?
14
Support / Ann/MSG in a world
« on September 9th, 07:42 PM »
Hi everyone does anyone know how to announe or message everyone in a specific world for example

I want to announce or display a message to everyone in world 2, but it should not be displayed in world 1
15
Support / custom vehicle sound
« on August 26th, 07:20 PM »
How to have a custom vehicle sound means if ur in a sports car so that car can have a sound of a sportscar but not sound of vc default cars can we have something like sound.wav

If yes then how cuz ive never tried it, except just once heard the lw has it omehow