how to add static vehicles in server
#1

hello all here is my bikes i want to add in my server but i dont knwon how i addd it ongamemodeinit plz help me
pawn Код:
{ 1556.8648, -2210.5359, 13.215, 0 },
    { 1555.6101, -2210.4856, 13.215, 0 },
    { 1554.3394, -2210.628, 13.215, 0 },
    { 1552.9766, -2210.5638, 13.215, 0 },
    { 1551.7001, -2210.4612, 13.215, 0 },
    { 1550.616, -2210.5738, 13.215, 0 },
    { 1549.466, -2210.4854, 13.215, 0 },
    { 1548.2786, -2210.2972, 13.215, 0 },
    { 1547.1319, -2210.3528, 13.215, 0 },
    { 1545.9468, -2210.2127, 13.215, 0 },
    { 1544.7711, -2210.2637, 13.215, 0 },
    { 1543.5631, -2210.3099, 13.215, 0 },
    { 1542.4444, -2210.4122, 13.215, 0 },
    { 1541.2023, -2210.3587, 13.215, 0 },
    { 1539.8802, -2210.2488, 13.215, 0 },
    { 1538.6206, -2210.4241, 13.215, 0 },
    { 1537.4075, -2210.6473, 13.215, 0 },
    { 1536.2493, -2210.5103, 13.215, 0 },
    { 1534.9628, -2210.4944, 13.215, 0 },
    { 1533.7521, -2210.5772, 13.215, 0 },
    { 1532.4832, -2210.472, 13.215, 0 },
    { 1531.2486, -2210.5499, 13.215, 0 },
    { 1529.9106, -2210.4363, 13.215, 0 },
    { 1528.5383, -2210.4959, 13.215, 0 },
    { 1527.2882, -2210.5245, 13.215, 0 },
    { 1556.523, -2213.939, 13.215, 0 },
    { 1555.3096, -2214.0586, 13.215, 0 },
    { 1554.3267, -2213.9424, 13.215, 0 },
    { 1552.9656, -2213.7813, 13.215, 0 },
    { 1551.7031, -2213.9795, 13.215, 0 },
    { 1550.4174, -2213.9568, 13.215, 0 },
    { 1549.408, -2214.0516, 13.215, 0 },
    { 1548.3344, -2214.0098, 13.215, 0 },
    { 1547.0528, -2213.9009, 13.215, 0 },
    { 1545.9104, -2213.8506, 13.215, 0 },
    { 1544.7601, -2213.8416, 13.215, 0 },
    { 1543.5676, -2213.8689, 13.215, 0 },
    { 1542.5019, -2213.8685, 13.215, 0 },
    { 1541.2645, -2213.8057, 13.215, 0 },
    { 1540.0742, -2213.9139, 13.215, 0 },
    { 1538.8103, -2213.847, 13.215, 0 },
    { 1537.5327, -2213.9012, 13.215, 0 },
    { 1536.4976, -2213.8606, 13.215, 0 },
    { 1535.2664, -2213.959, 13.215, 0 },
    { 1533.9891, -2213.8484, 13.215, 0 },
    { 1532.6678, -2213.8936, 13.215, 0 },
    { 1531.4608, -2214.0306, 13.215, 0 },
    { 1530.0869, -2214.0665, 13.215, 0 },
    { 1528.8653, -2214.0794, 13.215, 0 },
    { 1527.5039, -2213.9576, 13.215, 0 }
Reply
#2

plz help me here
Reply
#3

https://sampforum.blast.hk/showthread.php?tid=92
https://sampwiki.blast.hk/wiki/AddStaticVehicle
Reply
#4

This forum is for helping pepole if they have errors, etc, not scripting for them.
Reply
#5

Quote:
Originally Posted by Darnell
Посмотреть сообщение
This forum is for helping pepole if they have errors, etc, not scripting for them.
Did Sacha give him a script ? No directed him to wiki.
Reply
#6

its not scripting lol plz tell me how i use these bikes with a code lol
Reply
#7

How to use these bikes with a code ?
You want us to do,
pawn Код:
AddStaticVehicle(Modelid, X, Y, Z, Angle, color1, color2);
It's up to you, not up to us.
As I told, it's for helping pepole with errors, not scripting for.
Reply
#8

Look
native:

AddStaticVehicle(520, 2109.1763, 1503.0453, 32.2887, 82.2873, 0, 1)

Some of your script:

1537.5327, -2213.9012, 13.215, 0
-------

X Coord Y Coord Z Coord Color1

So replace them in the correct fields and add one more colour
at the end, after 0.

so like

AddStaticVehicle(520, 1537.5327, -2213.9012, 13.215, 0, 1);

Quote:

It's up to you, not up to us.
As I told, it's for helping pepole with errors, not scripting for.

Oh no... We have alot of that.
Reply
#9

no not this oper my code how i use this in my script
like for new 0:< blah blah plz
Reply
#10

Quote:
Originally Posted by Jay.
Посмотреть сообщение
Look
native:

AddStaticVehicle(520, 2109.1763, 1503.0453, 32.2887, 82.2873, 0, 1)

Some of your script:

1537.5327, -2213.9012, 13.215, 0
-------
^ ^ ^ ^
X Coord Y Coord Z Coord Color1

So replace them in the correct fields and add one more colour
at the end near 0
little addition:
AddStatVehicle(520, 2109.1763, 1503.0453, 32.2887, 82.2873, 0, 1);
-----
520 = Vehicle model
2109.1763 = X Position
1503.0453 = Y Position
32.2887 = Z Position
82.2873 = ZA Position
0 = Color1
1 = Color2


edit:
pawn Код:
new Float:VPosition[][4] =
{
 { 1556.8648, -2210.5359, 13.215, 0 },
    { 1555.6101, -2210.4856, 13.215, 0 },
    { 1554.3394, -2210.628, 13.215, 0 },
    { 1552.9766, -2210.5638, 13.215, 0 },
    { 1551.7001, -2210.4612, 13.215, 0 },
    { 1550.616, -2210.5738, 13.215, 0 },
    { 1549.466, -2210.4854, 13.215, 0 },
    { 1548.2786, -2210.2972, 13.215, 0 },
    { 1547.1319, -2210.3528, 13.215, 0 },
    { 1545.9468, -2210.2127, 13.215, 0 },
    { 1544.7711, -2210.2637, 13.215, 0 },
    { 1543.5631, -2210.3099, 13.215, 0 },
    { 1542.4444, -2210.4122, 13.215, 0 },
    { 1541.2023, -2210.3587, 13.215, 0 },
    { 1539.8802, -2210.2488, 13.215, 0 },
    { 1538.6206, -2210.4241, 13.215, 0 },
    { 1537.4075, -2210.6473, 13.215, 0 },
    { 1536.2493, -2210.5103, 13.215, 0 },
    { 1534.9628, -2210.4944, 13.215, 0 },
    { 1533.7521, -2210.5772, 13.215, 0 },
    { 1532.4832, -2210.472, 13.215, 0 },
    { 1531.2486, -2210.5499, 13.215, 0 },
    { 1529.9106, -2210.4363, 13.215, 0 },
    { 1528.5383, -2210.4959, 13.215, 0 },
    { 1527.2882, -2210.5245, 13.215, 0 },
    { 1556.523, -2213.939, 13.215, 0 },
    { 1555.3096, -2214.0586, 13.215, 0 },
    { 1554.3267, -2213.9424, 13.215, 0 },
    { 1552.9656, -2213.7813, 13.215, 0 },
    { 1551.7031, -2213.9795, 13.215, 0 },
    { 1550.4174, -2213.9568, 13.215, 0 },
    { 1549.408, -2214.0516, 13.215, 0 },
    { 1548.3344, -2214.0098, 13.215, 0 },
    { 1547.0528, -2213.9009, 13.215, 0 },
    { 1545.9104, -2213.8506, 13.215, 0 },
    { 1544.7601, -2213.8416, 13.215, 0 },
    { 1543.5676, -2213.8689, 13.215, 0 },
    { 1542.5019, -2213.8685, 13.215, 0 },
    { 1541.2645, -2213.8057, 13.215, 0 },
    { 1540.0742, -2213.9139, 13.215, 0 },
    { 1538.8103, -2213.847, 13.215, 0 },
    { 1537.5327, -2213.9012, 13.215, 0 },
    { 1536.4976, -2213.8606, 13.215, 0 },
    { 1535.2664, -2213.959, 13.215, 0 },
    { 1533.9891, -2213.8484, 13.215, 0 },
    { 1532.6678, -2213.8936, 13.215, 0 },
    { 1531.4608, -2214.0306, 13.215, 0 },
    { 1530.0869, -2214.0665, 13.215, 0 },
    { 1528.8653, -2214.0794, 13.215, 0 },
    { 1527.5039, -2213.9576, 13.215, 0 }
};
pawn Код:
public OnGameModeInit()
{
  for(new v=0; v<MAX_VEHICLES; v++)
  {
    AddStaticVechile(520, VPosition[v][0], VPosition[v][1], VPosition[v][2], vPosition[v][3], 0, 0);
  }
}
small example...
Reply
#11

Quote:
Originally Posted by Honest_Player
Посмотреть сообщение
no not this oper my code how i use this in my script
like for new 0:< blah blah plz
what? Your not making any sense.
Reply
#12

Quote:
Originally Posted by Jay.
Посмотреть сообщение
what? Your not making any sense.
he means using a loop to read them from an array I suppose..
I edited my post above and posted a rough example
Reply
#13

Example :
pawn Код:
public OnGameModeInit()
{
    AddStatVehicle(520, 2109.1763, 1503.0453, 32.2887, 82.2873, 0, 1);
        AddStatVehicle(modelid, X, Y, Z, Float:angle, color1, color2)
        return 1;
}
And just continue.
Reply
#14

yes i want same thanks
Reply
#15

Well, I will not do it for free, I would like something in return .
Reply
#16

Quote:
Originally Posted by Darnell
Посмотреть сообщение
Well, I will not do it for free, I would like something in return .
for just repeating what was said 1 page before?... pfft tehe
Reply
#17

Quote:
Originally Posted by Sascha
Посмотреть сообщение
for just repeating what was said 1 page before?... pfft tehe
And replacing the positions, his choice
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)