Official Servers > XE Servers (Legacy)

Scripts Suggestions

(1/14) > >>

Tommis:
Hey,

Have suggestions for our scripts or server? Post them in here. Any suggestions would be greatly appreciated!

Regards,
Tommis

Mattz:
How about making !buycar and !sellcar script?  ;)

TanaX01:

--- Quote from: Mattz on August 02, 2008, 09:34:17 pm ---How about making !buycar and !sellcar script?  ;)

--- End quote ---

hey mattz nice suggestions plz tommis add buycar sellcar etc  ;)

Tommis:
Hey,

Alright, and what will happen when someone else gets into a car that they do not own? (Owned by someone else).

I am thinking that person will have to pay something, but hmm. I would like to hear what you would have to say.

:P

Regards,
Tommis

TanaX01:
Commands Buycar Sellcar Car Cardive Etc 100% Work  ;)


--- Code: ---  elseif ($2 == !car) || ($2 == !pmcar) {
    if ($vcmp.cmdcheck(!car,%id) == fail) !halt   
    elseif (%a == -1) vcmp.msg %id  Absent ID/Name
    elseif ($vcmp.vehicle(%a,id) == 0) vcmp.msg %id  $vcmp.name(%a) car is currently on foot!
    else vcmp.msg %id Vehicle - Name: $+($chr(91),$vcmp.carname($vcmp.vehicle(%a,id)),$chr(93)) ID: $+($chr(91),$vcmp.vehicle(%a,id),$chr(93)) Price: $+($chr(91),$vcmp.vehiclecost($vcmp.vehicle(%a,id)),$chr(93)) Owner: $+($chr(91),$vcmp.carowner($vcmp.vehicle(%a,id)),$chr(93))
  }
  elseif ($2 == !buycar) {
    if ($vcmp.cmdcheck(!buycar,%id) == fail) !halt
    elseif (Sunshine Autos !isin $vcmp.area(%b)) vcmp.msg %id  To Buy A Car Deves Be Sunshine In Cars!!
    elseif ($vcmp.vehicle(%a,id) == 0) vcmp.msg %id
    elseif ($vcmp.carowner($vcmp.vehicle(%a,id)) != Sunshine Autos) vcmp.msg %id This vehicle is owned by $vcmp.carowner($vcmp.vehicle(%a,id))
    elseif ($vcmp.vehiclecost($vcmp.vehicle(%a,id)) > $vcmp.cash(%id)) vcmp.msg %id You need atleast $ $+ $vcmp.vehiclecost($vcmp.vehicle(%a,id))
    else {
      vcmp.cash- %b $vcmp.vehiclecost($vcmp.vehicle(%a,id))
      !writeini -n vcmp.cars.ini OWNERS $vcmp.vehicle(%a,id) $vcmp.name(%id)
      vcmp.msg %id You have just bought $+($chr(91),$vcmp.carname($vcmp.vehicle(%a,id)),$chr(93)) ID: $+($chr(91),$vcmp.vehicle(%a,id),$chr(93)) Price: $+($chr(91),$vcmp.vehiclecost($vcmp.vehicle(%a,id)),$chr(93))
    }
  }
  elseif ($2 == !sellcar) {
    if ($vcmp.cmdcheck(!sellcar,%id) == fail) !halt
    elseif (Sunshine Autos !isin $vcmp.area(%b)) vcmp.msg %id To Sell A Must Be In Order To Sunshine Or Make One Admin The Leasehold Landlord
    elseif ($vcmp.vehicle(%a,id) == 0) vcmp.msg %id You Have No Car No!
    elseif ($vcmp.carowner($vcmp.vehicle(%a,id)) != %name) vcmp.msg %id You Can not Buy This Car Has Owner
    else {
      !writeini -n vcmp.cars.ini OWNERS $vcmp.vehicle(%a,id) Sunshine Autos
      vcmp.cash+ %b $calc($vcmp.vehiclecost($vcmp.vehicle(%a,id)) * 0.55)
      vcmp.msg %id You have sold your vehicle with price $ $+ $calc($vcmp.vehiclecost($vcmp.vehicle(%a,id)) * 0.55)
    }
  }
  elseif ($2 == !getcar) || ($2 == !pmgetcar) {
    if ($vcmp.cmdcheck(!getcar,%id) == fail) !halt
    elseif (!$3) vcmp.msg %id Error - Missing Information, $2 <car id>
    elseif ($3 !isnum) vcmp.msg %id Error - Invalid Vehicle ID, $2 <car id>
    elseif ($vcmp.carowner($3) != %name) vcmp.msg %id Your not the owner of this car!
    else {
      vcmp.setvehicleloc $3 $hget(vcmp,%id $+ .xyz)
      .timer -m 1 400 vcmp.setvehicle %id $3
    }
  }
  elseif ($2 == !cardive) || ($2 == !pmgetcar) {
    if ($vcmp.cmdcheck(cardivegetcar,%id) == fail) !halt
    elseif (!$3) vcmp.msg %id  Missing Information, $2 <car id>
    elseif ($3 !isnum) vcmp.msg %id  Invalid Vehicle ID, $2 <car id>
    elseif ($vcmp.carowner($3) != %name) vcmp.msg %id You are not the owner of this car, go and buy one!
    else {
      vcmp.msg %id
      vcmp.setvehicleloc $3 $hget(vcmp,%id $+ .x) $hget(vcmp,%id $+ .y) $calc($hget(vcmp,%id $+ .z) + 700)
      .timer -m 1 400 vcmp.set 9 %id $3
    }
  }
  elseif ($2 == !lockcar) || ($2 == !pmlockcar) {
    if ($vcmp.cmdcheck(!lockcar,%id) == fail) !halt
    elseif (!$3) vcmp.msg %id Error - Missing Information, $2 <car id>
    elseif ($3 !isnum) vcmp.msg %id Error - Invalid Vehicle ID, $2 <car id>
    elseif ($vcmp.carowner($3) != %name) vcmp.msg %id You are not the owner of this car
    else {
      vcmp.lockdoors $3 4
      vcmp.msg %id **Car Locked
    }
  }
  elseif ($2 == !unlockcar) || ($2 == !pmunlockcar) {
    if ($vcmp.cmdcheck(!unlockcar,%id) == fail) !halt
    elseif (!$3) vcmp.msg %id Error - Missing Information, $2 <car id>
    elseif ($3 !isnum) vcmp.msg %id Error - Invalid Vehicle ID, $2 <car id>
    elseif ($vcmp.carowner($3) != %name) vcmp.msg %id You are not the owner of this car
    else {
      vcmp.lockdoors $3 0
    vcmp.msg %id **Car Unlocked    }
  }
--- End code ---

tommi you server is cool more commands add buycar car sellcar etc..  :)

Navigation

[0] Message Index

[#] Next page

Go to full version