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
Pages: [1] 2 3 4
1  Scripting / Script Help / Re: Object dissapear on a specific command on: October 24, 2011, 06:07:15 pm
try this:

Code: (GeSHi) [Select]
function onScriptLoad()
{
CreateSphere( Vector( 194.33, -1195.3, 26.16 ), 3.0, Colour( 0, 136, 255 ) )
oFence <- CreateObject( 1281, Vector( 844.1, -419.5, 14.97 ) )
return 1;
}

function onPlayerEnterSphere( player, sphere )
 if ( sphere.ID == 12 )
 {
  MessagePlayer( "Anticefur CENTER:", player, 0, 136, 255 );
  MessagePlayer( "Owner: xXxMDjxXx", player, 0, 136, 255 );
  MessagePlayer( "Odkup: NONE", player, 0, 136, 255 );
  MessagePlayer( "Najem: NONE", player, 0, 136, 255 );
  MessagePlayer( "Vsebuje: orozja, vozila, parkirna hisa, ograja", player, 0, 136, 255 );
  return 1;
 }

function onPlayerCommand( player, cmd )
{
if ( cmd == "accso" )
{
 oFence.VirtualWorld = 2;
 return 1;
}

else if ( cmd == "accsz" )
{
 oFence.VirtualWorld = 0;
 return 1;
}


Actualy now i get an error ...:

Code: [Select]
COMMAND: xxxmdjxxx: accso

AN ERROR HAS OCCURED [wrong number of parameters]

CALLSTACK

LOCALS
COMMAND: xxxmdjxxx: accsz

AN ERROR HAS OCCURED [wrong number of parameters]

CALLSTACK

LOCALS


the script
Code: [Select]
function onScriptLoad()
{
CreateSphere( Vector( 194.33, -1195.3, 26.16 ), 3.0, Colour( 0, 136, 255 ) )
oFence <- CreateObject( 1289, Vector( 844.1, -419.5, 14.97 ) )
return 1;
}

function onPlayerEnterSphere( player, sphere )
 if ( sphere.ID == 12 )
 {
  MessagePlayer( "Anticefur CENTER:", player, 0, 136, 255 );
  MessagePlayer( "Owner: xXxMDjxXx", player, 0, 136, 255 );
  MessagePlayer( "Odkup: 100€", player, 0, 136, 255 );
  MessagePlayer( "Najem: 1€", player, 0, 136, 255 );
  MessagePlayer( "Vsebuje: orozja, vozila, parkirna hisa, ograja", player, 0, 136, 255 );
  return 1;
 }

function onPlayerCommand( player, cmd )
{
if ( cmd == "accso" )
{
 oFence.VirtualWorld = 2;
 return 1;
}

else if ( cmd == "accsz" )
{
 oFence.VirtualWorld = 1;
 return 1;
}}


PS. Ja sam iz SLO, lijep pozdrav D.Mandi?
2  Off Topic / General Chat / Yugo or zastava koral 45 for GTA3? on: October 24, 2011, 01:13:36 am
Does anyone know if this model car exists for GTA3???
Or, could maybe someone convert one from San andreas???
3  Scripting / Script Help / Re: Object dissapear on a specific command on: October 24, 2011, 01:11:46 am
try this:

Nope, now the fence doesent even isnt showing up, no sphere too... Idk. what the hell is wrong with this script, i thought it could be done... No errors in the conslole eather...
4  Scripting / Script Help / Re: Object dissapear on a specific command on: October 22, 2011, 10:56:06 am
"not really working..." wtf does that support to mean?
Give us some more details! Does it give any error, what did you try to fix it.
With a reply "its not working" we can't do much..

Hehe, sorry...
Well the object is shown, but it doesent "dissapear"...
There are no errors in the server window.

the code is:

Code: [Select]
function onScriptLoad()
{
CreateSphere( Vector( 194.33, -1195.3, 26.16 ), 3.0, Colour( 0, 136, 255 ) )
oFence <- CreateObject( 1281, Vector( 844.1, -419.5, 14.97 ) )
return 1;
}

function onPlayerEnterSphere( player, sphere )
 if ( sphere.ID == 12 )
 {
  MessagePlayer( "Anticefur CENTER:", player, 0, 136, 255 );
  MessagePlayer( "Owner: xXxMDjxXx", player, 0, 136, 255 );
  MessagePlayer( "Odkup: NONE", player, 0, 136, 255 );
  MessagePlayer( "Najem: NONE", player, 0, 136, 255 );
  MessagePlayer( "Vsebuje: orozja, vozila, parkirna hisa, ograja", player, 0, 136, 255 );
  return 1;
 }

else if ( cmd == "accso" )
{
 oFence.VirtualWorld = 2;
 return 1;
}

else if ( cmd == "accsz" )
{
 oFence.VirtualWorld = 0;
 return 1;
}

I made a property on my server, so when someone walks over the sphere they see the text (owner, cost, cars etc...)
And to prevent my cars from being stolen i wanted to make a gate, which would be "remote controled" so only people with the code could open the gates and dive with my cars...
5  Scripting / Script Help / Re: Object dissapear on a specific command on: October 20, 2011, 08:36:11 pm
hmm.. not realy working...
6  Scripting / Script Help / Object dissapear on a specific command on: October 16, 2011, 10:21:23 am
Hm, how could i make a object, lets say a fence and put it in front a driveway of a house, and make it dissapear with a command like /open and when i send /close the fence will apear again?
I would put a gate at the enterance to a mansion..
7  Scripting / Scripting Discussion / Re: Spawn point by player name? on: October 16, 2011, 10:10:03 am
no erors in the console...
8  Scripting / Scripting Discussion / Re: Spawn point by player name? on: October 15, 2011, 07:58:33 pm
Err yes..

Code: [Select]
function onPlayerSpawn( player, spawn )
{
if ( player.Name.tolower() == "xxxmdjxxx" ) player.Pos = Vector( 0.0, 0.0, 0.0 );
return 1;
}


hmm, still not working, changed my name to xxxmdjxxx and still nothing.
9  Scripting / Scripting Discussion / Re: Spawn point by player name? on: October 15, 2011, 03:35:17 pm
You can check the player name with player.Name;
So on spawn you could do this:
Code: [Select]
function onPlayerSpawn( player, spawn )
{
if ( player.Name == "testplayer123" ) player.Pos = Vector( x, y, z );
}


The code is not working...

Code: [Select]
function onPlayerSpawn( player, spawn )
 if ( player.Name == "xXxMDjxXx" )
 {
  player.Pos = Vector( -812.2, 355.7, 51.32 );
  return 1;
 }

Have i done something wrong?
10  Scripting / Script Help / Re: Spheres problem... on: October 14, 2011, 08:03:55 pm
WORKS! ooooh thanx man you are the greatest!  ;D
11  Scripting / Script Help / Re: Spheres problem... on: October 14, 2011, 05:44:53 pm
Ok, well sorry, but i was not being rude to him... I am yust a beginer with ideas and want to make stuff. The weird non existing
event is something i found on the forum and tried it, but the correct event isnot helping me to...

the code looks like this:
Code: [Select]
function onScriptLoad()
{
 CreateSphere( Vector( -368, 245.84, 61.02 ), 3.0, Colour( 0, 0, 255 ) )

 return 1;
}

function onPlayerEnterSphere( player, sphere )
{
 if ( sphere.ID == 0 )
 {
  MessagePlayer( "Vila Janeza tretjega:", player, RED );
 }
return 1;
}

function onPlayerSpawn( player, spawn )
{
 if ( player.Name == "xXxMDjxXx" )
 {
  player.Pos = Vector( -368, 245.84, 61.02 );
 }
 return 1;
}


and the code onPlayerSpawn, doesent spawn me on that spot eather... idk what am i doing wrong...
And for the sphere, could it be the problem that i have more spheres in other scripts like fuelscript and car respray script, so that the id of this sphere is not 0, or is the sphere id defined for every script itself?


Modified--:

So now, the server gives an error :

AN ERROR HAS OCCURED [getVarInfo: Could not retrieve UserData]

CALLSTACK
*FUNCTION [onPlayerEnterSphere()] Scripts/hise/hise.nut line [10]

LOCALS
[sphere] INSTANCE
[player] INSTANCE
[this] TABLE

AN ERROR HAS OCCURED [getVarInfo: Could not retrieve UserData]

CALLSTACK
*FUNCTION [onPlayerEnterSphere()] Scripts/hise/hise.nut line [10]

LOCALS
[sphere] INSTANCE
[player] INSTANCE
[this] TABLE
12  Scripting / Script Help / Re: Spheres problem... on: October 13, 2011, 06:54:06 pm
The signal you're using does not exist. Check the wiki for the right signal.

???Signal??? What???
13  Scripting / Script Help / Spheres problem... on: October 12, 2011, 06:56:54 pm
Hi, i cannot make this script to work:

Code: [Select]
function onScriptLoad()
{
CreateSphere( Vector( -368, 245.84, 61.02 ), 3.0, Colour( 0, 0, 255 ) )

return 1;
}

function onPlayerFootSphereHit( player, sphere )
{
if ( sphere.ID == 0 )

MessagePlayer( "Vila Janeza tretjega:", player, RED );

return 1;
}

function onPlayerSpawn( player, spawn )
{

if ( player.Name == "xXxMDjxXx" ) player.Pos = Vector( -368, 245.84, 61.02 );

return 1;
}

What is the problem? I can see the sphere, but when i walk into it nothing happens..
14  Scripting / Scripting Discussion / Spawn point by player name? on: October 10, 2011, 06:00:42 pm
How could i make a player always spawn at a certain coordinate?

Lets say there is a player with a name "testplayer123"

So when this player joins the server or dies, he will spawn at a certain coordinate?

Other players will spawn at default spawnpoints...
15  Scripting / Scripting Discussion / Re: View a html document while playing? on: October 08, 2011, 06:23:12 pm
Think this has gone out of topic... So mainly, i wanted to make a script that when a player enters a car, a html document is "shown" (0px 0px) and the document haves an iframe to a flash radio player (link : http://93.103.70.151/deltasiska/racs/radio.htm ).

So even knowing its impossible i tried to open "radioframe.htm" as a sprite :p
And nothing happined, hehe LoL idk why i tried to open it like that :p
Pages: [1] 2 3 4
© Liberty Unleashed Team.