• Welcome to Vice City Multiplayer.
 
Menu

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.

Show posts Menu

Messages - Mex

#1
Script Showroom / Re: New VC-MP mIRC Admin
March 18, 2009, 10:59:57 PM
edit: nvm, didnt realise this was a topic in the script showroom
#2
Check this topic, it may help you
http://forum.vicecitymultiplayer.com/index.php?topic=1042.0

after learning how to script basic commands like !hp, you can move on to more advanced commands like !sus
#3
yo,

To retrieve all the servers on the server list, it uses the TCP protocol.
http://38.103.164.119/servers.php

(to query an individual server uses UDP)

the following should connect to the site and echo all the servers (including the headers received from the server)
(alot easier to read in the source as the servers are seperated by \n's)


<?php
$host "38.103.164.119";
$port 80;

$sock fsockopen($host$port$errorid$error30);
if (!$sock) die("Could not open socket to mast server list, errorid='$errorid' error='$error'");

$packet "GET /servers.php HTTP/1.1\r\n";
$packet .= "Content-Type: text/html\r\n";
$packet .= "Host: 38.103.164.119\r\n";
$packet .= "Accept: text/html, */*\r\n";
$packet .= "User-Agent: Mozilla/3.0 (compatible; VC:MP v0.3z BETA)\r\n";
$packet .= "\r\n";

fwrite($sock$packet);

while (!feof($sock)) {
echo fgets($sock128);
}

fclose($sock);
?>

#4
mIRC/pawn Scripting / Re: InVaLiD NiCk..
March 07, 2009, 03:58:44 PM
nice explanation man,

about what i said, i must have been thinking of a more advanced expression like the last one you posted
#5
mIRC/pawn Scripting / Re: InVaLiD NiCk..
March 04, 2009, 01:34:57 PM
Indeed we were.

I can remember along time ago when I was having problems with brackets,
and I tried all possible bracket solutions for the statement, and the only one which worked was when I added an extra pair of ( )

So from now on I've always added them when I have a statement with more than 1 condition, and it's never let me down.

So unless you know when to add them or not, in my opinion it's best to add them anyway.

I'm assuming you know when to add them, perhaps you could explain?
#6
mIRC/pawn Scripting / Re: InVaLiD NiCk..
March 03, 2009, 05:19:11 PM
Quote from: Windlord on March 03, 2009, 09:12:24 AM
lol you don't need that extra bracket.

Sometimes you do sometimes you dont.
#7
mIRC/pawn Scripting / Re: InVaLiD NiCk..
March 02, 2009, 06:45:11 PM
also you should put an extra pair of ( ) brackets around the massive conditional statement ;)


if (($len($3) < 3) || ($left($3,1) isnum) || ($chr(35) isin $3) || ($chr(36) isin $3) || ($chr(37) isin $3) || ($3 == none)) {
  vcmp.say *** $3 has been auto-kicked. [Invalid Nick]
  vcmp.announce %id ~y~Please change your nick-name..
  .timer 1 2 /vcmp.kick %id
}
#8
mIRC/pawn Scripting / Re: i can't load manhunt.mrc
February 25, 2009, 12:07:24 PM
Try loading the script this way:
open mirc
Tools > Scripts Editor
Remote tab
File > Load
* find the script * and click on it
Open
#9
mIRC/pawn Scripting / Re: Plz help my auto-drown!
February 22, 2009, 02:38:09 AM
You need to specify which player you want to set the location of.

If you want to drown the killer, change
vcmp.setlocation -485.562 -777.406 205.796
to
vcmp.setlocation %killer -485.562 -777.406 205.796
#10
mIRC/pawn Scripting / Re: help in "config of vehicles "
February 17, 2009, 03:38:05 AM
z_angle is the angle on the Z co ordinate in degrees (0 to 360) might be -180 to 180, cant remember..

basically it's the angle that the vehicle will be facing, eg. you may want it facing north or south etc
#11
Quote from: Zack on February 10, 2009, 06:17:44 PM
Is it maybe becouse i am the only one in the server?

That probably isn't the problem.


The reason it is always saying "Unknown" as the name is because in this line:
.timer 1 20 vcmp.cmdsay $2 %id The choosen player is: $vcmp.name($vcmp.randomid)

The $vcmp.randomid alias is not returning the correct value.

It may not be returning the correct value because it might not be finding the alias.
Make sure that you have a script loaded with the alias inside it.

Also try pressing 'Control' and 'h' in the mirc scripts editor, which will properly align all the code in that script with indentation, and inform you of any { and } bracket errors.

If it says you have bracket errors, then try placing the code in another blank script for the alias to work, or fix the bracket errors :p


Also it could be a bug in the vcmp.randomid alias i guess, but i cant see anything wrong with it :s
#12
Quote from: Zack on February 10, 2009, 03:48:47 PM
There's a problem with thijn's Alias.

Remove the last } ;)
#13
jus to confirm; the code thijn posted should be put inside the Remote tab in mirc, and outside the scope of any other alias's or events.

this error that your getting:
* /vcmp.check.ini: not connected to server (line 33, vcmp.mrc)
means that on line 33 in vcmp.mrc, mIRC attempted to call an alias called "vcmp.check.ini",
however it could not find the alias in any scripts that you have loaded.

possiby you have removed some code which contained this alias? or are missing an enite script?
#14
VC:MP Clans / Re: VC:MP clans
February 09, 2009, 08:57:18 AM
yo btw u can remove [NS] it was closed along time ago
#15
It needs to be added inside the vcmp.command signal if your using GUS 9.0.

try this

on *:SIGNAL:vcmp.command:{
  if ($2 == !badplayer) {
    var %a = 0, %b = $vcmp.maxplayers, %c, %randomid
    while (%a < %b) {
      if ($vcmp.name(%a) != Unknown) { %c = $addtok(%c, %a, 32) }
      !inc %a
    }
    if (%c == $null) { ;no players in server }
    else {
      %randomid = $gettok(%c, $rand(1, $numtok(%c, 32)), 32)
      ; the %randomid variable contains a random player id
    }
  }
}