Author Topic: Help in script  (Read 12547 times)

0 Members and 3 Guests are viewing this topic.

Offline Cristian

  • Wiseguy
  • **
  • Posts: 63
    • View Profile
Re: Help in script
« Reply #15 on: August 10, 2008, 03:34:43 pm »
Yeah, seems you hasnt got buycar etc command in your script.
So put it on first.

critian you change whats !! in commands !car  ???

TaNaX01:

1? my name not is Critian my name is Cristian

2? I want to switch to command !Car so that you will find another way rather than this:


Code: [Select]
<~Cristian_08> !car Shadow
<&ArgentinaSpoon> ** Shadow is driving a Hunter. (id: 171 - type: 155)

and change this, example:

Code: [Select]
<~Cristian_08> !car Shadow
<&ArgentinaSpoon> Shadow - Vehicle Status: Model:[ Hunter ] ID:[ 171 ]  Hp:[ %28 ] Owner:[ Cristian_08 ] Price:[ $150.000 ] Share:[ Shadow ]

sorry for my english  ;)


Offline thijn

  • LU testers
  • VC:MP Veteran
  • *
  • Posts: 667
  • Im proud to be pro.
    • View Profile
    • Vice Underdogs
Re: Help in script
« Reply #16 on: August 10, 2008, 05:19:55 pm »
Do you have a buycar script?

Offline Cristian

  • Wiseguy
  • **
  • Posts: 63
    • View Profile
Re: Help in script
« Reply #17 on: August 10, 2008, 05:32:55 pm »
Do you have a buycar script?


yes, is :

Quote
     elseif ($2 == !getcar) {
      if ($vcmp.hgetcarid(%id) != 0) vcmp.adminmsg %id You must be on foot to use the <!Getcar> Command.
      elseif (!$3) vcmp.adminmsg %id Error - Missing Information, $2 <ID>
      elseif ($3 !isnum) vcmp.adminmsg %id $2 $+ , Invalid Vehicle ID.
      elseif (. isin $3) vcmp.adminmsg %id $2 $+ , Invalid Vehicle ID.
      elseif ($3 > 140) || ($3 < 0) vcmp.adminmsg %id Error: Invalid Vehicle ID.
      elseif (+ isin $3) || (- isin $3) vcmp.adminmsg %id $2 $+ , Invalid Vehicle ID.
      elseif ( $vcmp.carsowners($3) != $vcmp.hgetname(%id)) vcmp.adminmsg %id Error - You Dont have Keys To this Vehicle.
      else {
        vcmp.setcarloc $3 $calc($vcmp.hgetpos.x(%id) + 2) $calc($vcmp.hgetpos.y(%id) + 2) $calc($vcmp.hgetpos.z(%id) - 1) 
        vcmp.adminmsg %id Spawning Car:[ $3 $+ ]
      }
      if ($vcmp.hgetcarid(%id) != 0) vcmp.adminmsg %id You must be on foot to use the <!Getcar> Command.
      elseif (!$3) vcmp.adminmsg %id Error - Missing Information, $2 <ID>
      elseif ($3 !isnum) vcmp.adminmsg %id $2 $+ , Invalid Vehicle ID.
      elseif (. isin $3) vcmp.adminmsg %id $2 $+ , Invalid Vehicle ID.
      elseif ($3 > 140) || ($3 < 0) vcmp.adminmsg %id Error: Invalid Vehicle ID.
      elseif (+ isin $3) || (- isin $3) vcmp.adminmsg %id $2 $+ , Invalid Vehicle ID.
      elseif ( $vcmp.carsshares($3) != $vcmp.hgetname(%id)) vcmp.adminmsg %id Error - You Dont have Keys To this Vehicle.
      else {
        vcmp.setcarloc $3 $calc($vcmp.hgetpos.x(%id) + 2) $calc($vcmp.hgetpos.y(%id) + 2) $calc($vcmp.hgetpos.z(%id) - 1) 
        vcmp.adminmsg %id Spawning Car:[ $3 $+ ]
      }
    } 


Offline thijn

  • LU testers
  • VC:MP Veteran
  • *
  • Posts: 667
  • Im proud to be pro.
    • View Profile
    • Vice Underdogs
Re: Help in script
« Reply #18 on: August 10, 2008, 10:02:53 pm »
plz post ur alias for cost

EDIT:
try this:
Code: [Select]
alias vcmp.playervehicle {
!return $vcmp.name($vcmp.getid($1)) - Vehicle Status: Model: $chr(91) $vcmp.carname($3) $chr(93) ID: $chr(91) $2 $chr(93) Owner: $chr(91) $vcmp.carsowners($3) $chr(93) Share: $chr(91) $vcmp.carsshares($3) $chr(93)
}
« Last Edit: August 10, 2008, 10:10:52 pm by thijn »

Offline Cristian

  • Wiseguy
  • **
  • Posts: 63
    • View Profile
Help in script
« Reply #19 on: August 11, 2008, 02:56:09 am »
Help in my !sethp for sansan is:

Quote
    elseif ($1 == !sethp) { vcmp.sethp $vcmp.nameid($2) $3- | vcmp.adminchat Admin:[ $nick ] Changed:[ $iif($vcmp.nameid($2) != $null,$vcmp.hgetname($vcmp.nameid($2)),$2) ] HP To:[ $4- ] }

say:

Code: [Select]
<~Cristian_08> !sethp shadow 100
<&ArgentinaSpoon> Admin:[ Cristian_08 ] Changed:[ shadow ] HP To:[ ]
<&ArgentinaSpoon>  >> shadow died.

help :(
 


Offline Mattz

  • VC:MP Lead Tester
  • Made Man
  • *
  • Posts: 192
  • BK-201
    • View Profile
Re: Help in script
« Reply #20 on: August 11, 2008, 07:33:35 am »
Its
Code: [Select]
HP To:[ $3- ]


Offline Cristian

  • Wiseguy
  • **
  • Posts: 63
    • View Profile
Re: Help in script
« Reply #21 on: August 11, 2008, 11:31:14 pm »


Offline Cristian

  • Wiseguy
  • **
  • Posts: 63
    • View Profile
Help in script
« Reply #22 on: August 13, 2008, 02:26:14 am »
help in script CHAT, say:

Quote
<&ArgentinaSpoon> [] [Silence]*JOSE**: *********
<&ArgentinaSpoon> [] Gral.: *********
<&ArgentinaSpoon> [] **Daemon**: *********
<&ArgentinaSpoon> [] [Silence]*JOSE**: *********
<&ArgentinaSpoon> [] **Daemon**: *********

my script is:

Code: [Select]
on *:SIGNAL:vcmp.event.chat:{
var %name = $left([ $1 ],-1),%id = $vcmp.nameid(%name), %team = $iif($vcmp.hgetteam(%id) != -1,$v1,255), %cname = $iif($vcmp.hgetteam(%id),$vcmp.nickcolor(%name $+ $par(%team)) $+ :,01 $+ $1 $+ )
  $iif($($+(%,antispam.,[ %name ]),2) == 5,vcmp.kicknow %id flooding,inc -u5 $+(%,antispam.,[ %name ]))
  vcmp.enforcelogin %id
  vcmp.enforcestfu %id
  vcmp.enforce.censor %id $2-
  if ($left($2,1) == !) {
    if ($($+(%,anticmdspam.,[ %name ]),2) > 0) { vcmp.adminmsg %id ** Error: You must use the commands between 4secs. }
    else { inc -u4 $+(%,anticmdspam.,[ %name ]) | .signal vcmp.event.gamecmd $1- } 
  }
  if (%echolevel > 2) vcmp.echo 2 $+ $+($chr(91),%id,$chr(93)) $+ 7 %name $+  $+ : $2-
}

:S HELP!


Offline Force

  • LU Developer
  • Made Man
  • *
  • Posts: 242
    • View Profile
Re: Help in script
« Reply #23 on: August 13, 2008, 11:39:08 am »
Try this :)

Code: [Select]
on *:SIGNAL:vcmp.event.chat:{
var %name = $left([ $1 ],-1),%id = $vcmp.nameid(%name), %team = $iif($vcmp.hgetteam(%id) != -1,$v1,255), %cname = $iif($vcmp.hgetteam(%id),$vcmp.nickcolor(%name $+ $par(%team)) $+ :,01 $+ $1 $+ )
  $iif($($+(%,antispam.,[ %name ]),2) == 5,vcmp.kicknow %id flooding,inc -u5 $+(%,antispam.,[ %name ]))
  vcmp.enforcelogin %id
  vcmp.enforcestfu %id
  vcmp.enforce.censor %id $2-
  if ($left($2,1) == !) {
    if ($($+(%,anticmdspam.,[ %name ]),2) > 0) { vcmp.adminmsg %id ** Error: You must use the commands between 4secs. }
    else { inc -u4 $+(%,anticmdspam.,[ %name ]) | .signal vcmp.event.gamecmd $1- } 
  }
  if (%echolevel > 2) vcmp.echo 2 $chr(91) $+ %id $+ $chr(93)7 %name $+ : $2-
}

Offline Cristian

  • Wiseguy
  • **
  • Posts: 63
    • View Profile
Help in script
« Reply #24 on: August 18, 2008, 06:42:04 pm »
Help in script !setcash for sansan, say :

Code: [Select]
<~Cristian_08> !setcash Shadow 10000
<&ArgentinaSpoon> Admin:[ Cristian_08 ] Player:[ Shadow ] Cash:[ $ 10000 ]
<~Cristian_08> !money 0
<&ArgentinaSpoon> Shadow Money: 0

my script is :

Quote
  if ($vcmp.ishop($nick)) {
    ;--- hop and higher commands
    elseif ($1 == !setcash) { vcmp.setcash $vcmp.nameid($2) $3- | vcmp.adminchat Admin:[ $nick ] Player:[ $iif($vcmp.nameid($2) != $null,$vcmp.hgetname($vcmp.nameid($2)),$2) ] Cash:[ $ $3- ] }

Help Please :(
« Last Edit: August 18, 2008, 07:07:31 pm by Cristian »


Offline Cristian

  • Wiseguy
  • **
  • Posts: 63
    • View Profile
Re: Help in script
« Reply #25 on: August 19, 2008, 11:14:50 pm »
please help!! :S :(:(:(


Offline Force

  • LU Developer
  • Made Man
  • *
  • Posts: 242
    • View Profile
Re: Help in script
« Reply #26 on: August 20, 2008, 12:34:16 am »
After having a quick look I have come up with this:

If you put the command directly under: ;-- hop and higher commands
Code: [Select]
  if ($1 == !setcash) {
    vcmp.setcash $2 $3
    vcmp.adminchat Admin:[ $nick ] Player:[ $vcmp.hgetname($2) ] Cash:[ $ $+ $3 ]
  }

If you put the command under another one e.g. under !say

Code: [Select]
  elseif ($1 == !setcash) {
    vcmp.setcash $2 $3
    vcmp.adminchat Admin:[ $nick ] Player:[ $vcmp.hgetname($2) ] Cash:[ $ $+ $3 ]
  }

Offline Cristian

  • Wiseguy
  • **
  • Posts: 63
    • View Profile
Re: Help in script
« Reply #27 on: August 21, 2008, 10:29:56 pm »
After having a quick look I have come up with this:

If you put the command directly under: ;-- hop and higher commands
Code: [Select]
  if ($1 == !setcash) {
    vcmp.setcash $2 $3
    vcmp.adminchat Admin:[ $nick ] Player:[ $vcmp.hgetname($2) ] Cash:[ $ $+ $3 ]
  }



FAILED :S

If you put the command under another one e.g. under !say

Code: [Select]
  elseif ($1 == !setcash) {
    vcmp.setcash $2 $3
    vcmp.adminchat Admin:[ $nick ] Player:[ $vcmp.hgetname($2) ] Cash:[ $ $+ $3 ]
  }