Vice City: Multiplayer

Server Development => Scripting and Server Management => Topic started by: Spidey on Aug 21, 2015, 10:25 AM

Title: Collum problem
Post by: Spidey on Aug 21, 2015, 10:25 AM
the code
function createobjects(){
CreateObject(305,1,Vector(394.757, -504.813, 9.39561),255).RotateToEuler(Vector(0, 0, 0),1);
}


Screen Shot is down there


(https://forum.vc-mp.org/proxy.php?request=http%3A%2F%2Fs1.postimg.org%2Fv49ai5xfv%2Fbandicam_2000_11_04_00_35_22_281.jpg&hash=4702fc40f8a06ad866010b6aa1edabef595a9402) (http://postimg.org/image/v49ai5xfv/)
Title: Re: Collum problem
Post by: Spidey on Aug 21, 2015, 10:30 AM
the code picture


(https://forum.vc-mp.org/proxy.php?request=http%3A%2F%2Fs7.postimg.org%2Fkssimggp3%2Fbandicam_2000_11_04_00_43_08_546.jpg&hash=505bbf91cbbd0d00fbeaa1a4f80da0df22da8d11) (http://postimg.org/image/kssimggp3/)
Title: Re: Collum problem
Post by: Diego^ on Aug 21, 2015, 01:00 PM
function createobjects(){
CreateObject( 305, 1, 394.757, -504.813, 9.39561, 255 ).RotateToEuler(Vector(0, 0, 0),1);
}
Title: Re: Collum problem
Post by: KAKAN on Aug 21, 2015, 01:09 PM
was vector was the real problem? I don't think so
Title: Re: Collum problem
Post by: Diego^ on Aug 21, 2015, 03:00 PM
Quote from: KAKAN on Aug 21, 2015, 01:09 PMwas vector was the real problem? I don't think so

Tested his job, and worked properly.. The error is not in the Vector.
Spidey, i realized that the console displays a message:
"No Squirrel gamemode was especified" Try to fix this error in "server.cfg".. ::)
Title: Re: Collum problem
Post by: Spidey on Aug 21, 2015, 04:03 PM
 my game mode is vccnr

gamemode vccnr
Title: Re: Collum problem
Post by: Spidey on Aug 21, 2015, 04:09 PM
and see could not load script/main.nut
how fix it
Title: Re: Collum problem
Post by: Thijn on Aug 21, 2015, 06:54 PM
That no gamemode specified is thrown because your main.nut script failed to load because of this error. Fix the error and that notice will go away as well.



The code is fine. The error is thrown on the last line, which makes me believe the error is in a piece of code somewhere else in your file.
Try to check your brackets, and see if you've forgotten one or added one too many.
Title: Re: Collum problem
Post by: Spidey on Aug 22, 2015, 04:37 AM
and where should i add it to main.nut or server.cfg
Title: Re: Collum problem
Post by: Thijn on Aug 22, 2015, 09:05 AM
Quote from: Spidey on Aug 22, 2015, 04:37 AMand where should i add it to main.nut or server.cfg
Like I said, the server.cfg is not the problem. Check your main.nut for other scripting errors.
Title: Re: Collum problem
Post by: Spidey on Aug 22, 2015, 11:41 AM
Quote from: Diego^ on Aug 21, 2015, 01:00 PMfunction createobjects(){
CreateObject( 305, 1, 394.757, -504.813, 9.39561, 255 ).RotateToEuler(Vector(0, 0, 0),1);
}

} is  the problem
Title: Re: Collum problem
Post by: MatheuS on Aug 22, 2015, 03:52 PM
Quote from: Spidey on Aug 22, 2015, 11:41 AM
Quote from: Diego^ on Aug 21, 2015, 01:00 PMfunction createobjects(){
CreateObject( 305, 1, 394.757, -504.813, 9.39561, 255 ).RotateToEuler(Vector(0, 0, 0),1);
}


} is  the problem

lol?
Title: Re: Collum problem
Post by: Thijn on Aug 22, 2015, 04:19 PM
...

Like I said: Yes. A bracket is probably the problem, but not that one. Those 3 lines of code work.
So, test parts of your code until you find the actual problem.
Title: Re: Collum problem
Post by: Spidey on Aug 22, 2015, 08:00 PM
i tried it
}
is the problem
Title: Re: Collum problem
Post by: Thijn on Aug 23, 2015, 09:03 AM
Great, so you fixed it?
Title: Re: Collum problem
Post by: Spidey on Aug 23, 2015, 10:20 AM
just i said } is problem
Title: Re: Collum problem
Post by: Thijn on Aug 23, 2015, 10:28 AM
Yes you said that. Great you found the problem, now fix it.
Title: Re: Collum problem
Post by: KAKAN on Aug 23, 2015, 12:53 PM
Now delte that symbol } and then your script will work properly
Title: Re: Collum problem
Post by: Thijn on Aug 23, 2015, 01:09 PM
Quote from: KAKAN on Aug 23, 2015, 12:53 PMNow delte that symbol } and then your script will work properly
Lol, no.
It's not the last bracket that's the problem, like I have explained numerous times.
Title: Re: Collum problem
Post by: KAKAN on Aug 23, 2015, 05:03 PM
Oh i got it now
Title: Re: Collum problem
Post by: . on Aug 23, 2015, 05:32 PM
Quote from: KAKAN on Aug 23, 2015, 05:03 PMOh i got it now

No, you didn't!
Title: Re: Collum problem
Post by: FinchDon on Aug 24, 2015, 01:50 AM
it is problem in his main.nut any error and its showing last line that is ...
Title: Re: Collum problem
Post by: Spidey on Aug 24, 2015, 12:04 PM
yes u are right finch you are genius thijin now u understand?
Title: Re: Collum problem
Post by: Spidey on Aug 24, 2015, 12:05 PM
the problem is in last line
Title: Re: Collum problem
Post by: DizzasTeR on Aug 24, 2015, 12:30 PM
For the love of your error, the error is not on last line the error is anywhere or somewhere in your whole script! Which means if you did any mistake by not closing a bracket, adding useless brackets or stuff like that, the script breaks and ends up with a error on the last line. Check this example:
function onPlayerJoin( player )
{
{//EXTRA BRACKET

}

or

function onPlayerPart( player )
{

}// EXTRA BRACKET
}
Title: Re: Collum problem
Post by: Spidey on Aug 24, 2015, 05:23 PM
i checked and there is no extra bracket
Title: Re: Collum problem
Post by: Thijn on Aug 24, 2015, 05:27 PM
Then we're unable to help you, sorry.
Title: Re: Collum problem
Post by: Spidey on Aug 24, 2015, 05:28 PM
any vccnr main nut for me
Title: Re: Collum problem
Post by: MacTavish on Aug 24, 2015, 08:11 PM
Here it is

/* This is vccnr main.nut file code*/

function onScriptLoad()
{
print("vccnr main.nut loaded successfully");
}

function onPlayerJoin(player)
{
Message(player.Name+" Joined Vccnr");
}

function onPlayerPart(player, reason)
{
Message(player.Name+" left Vccnr");
}
Title: Re: Collum problem
Post by: MatheuS on Aug 25, 2015, 04:16 AM
Quote from: Kusanagi on Aug 24, 2015, 08:11 PMHere it is

/* This is vccnr main.nut file code*/

function onScriptLoad()
{
print("vccnr main.nut loaded successfully");
}

function onPlayerJoin(player)
{
Message(player.Name+" Joined Vccnr");
}

function onPlayerPart(player, reason)
{
Message(player.Name+" left Vccnr");
}

(https://forum.vc-mp.org/proxy.php?request=http%3A%2F%2Ffutirinhas.com%2Fwp-content%2Fuploads%2F2012%2F01%2Fpeter-parker-meme.jpg&hash=12099ae6584e25ab08ec19a79f74c66948fc2ed0)
Title: Re: Collum problem
Post by: Thijn on Aug 25, 2015, 05:44 AM
Locked.
If you can't find the faulty bracket we're sorry, but unable to help you.

(And obviously no one is going to give you a VCCNR script.)