[PROBLEM] Car selling at dealerships - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: [PROBLEM] Car selling at dealerships (
/showthread.php?tid=252241)
[PROBLEM] Car selling at dealerships -
vicesource - 30.04.2011
I can't make my vehicles dealerships working. It has some bugs:
- When I try to sell a car, it says I'm not in a dealership. Although I think I edited the dealership coordenates. (I'll put my pawn code in the end)
- Some cars don't appear, just appears the car's shadow. (Screenshot after this)
- Some cars don't let me stay in: I sit, and then I am "expeled".
- I don't know how to edit vehicles' prices.
Link to the code:
Pastebin - http://pastebin.com/5kY2vQy4
OnPlayerEnterVehicle :
http://pastebin.com/9YGjB0tu
IfPlayerStateChange :
http://pastebin.com/PS2WPM2m
All the code of car dealerships (I've searched for the word "dealership") :
http://pastebin.com/Q1e8upu0
I'm using
Night Life's Roleplay GM
If you need more code or informations, feel free to ask for.
A reply is urgent.
Thanks
Re: [PROBLEM] Car selling at dealerships -
Tommy_Mandaz - 30.04.2011
This might be the dealership problem:
pawn Код:
public IsAtDealership(playerid)
{
if(IsPlayerConnected(playerid))
{
if(PlayerToPoint(5,playerid,114.9868, 1063.8870, 18.8080))
{
return 1;
}
}
return 0;
}
Make the range bigger because this is saying that the person has to be near one spot to be at the dealership so make it in the center of the place you want and make it around 50 radius.
Also change the createvehicle to AddstaticvehicleEx since you want everyone to see them at all times.
Thats all I can tell from the code you put in pastebin for the others, I dont see any code so I wont answer those.
Re: [PROBLEM] Car selling at dealerships -
vicesource - 30.04.2011
Quote:
Originally Posted by Tommy_Mandaz
This might be the dealership problem:
pawn Код:
public IsAtDealership(playerid) { if(IsPlayerConnected(playerid)) { if(PlayerToPoint(5,playerid,114.9868, 1063.8870, 18.8080)) { return 1; } } return 0; }
Make the range bigger because this is saying that the person has to be near one spot to be at the dealership so make it in the center of the place you want and make it around 50 radius.
Also change the createvehicle to AddstaticvehicleEx since you want everyone to see them at all times.
Thats all I can tell from the code you put in pastebin for the others, I dont see any code so I wont answer those.
|
Thanks for the help, I will try to make the radius bigger and then I will post results.
EDIT: It didn't change anything. Cars are still invisible, and bikes are impossible to enter and stay. And I don't know how to edit prices.
Re: [PROBLEM] Car selling at dealerships -
vicesource - 30.04.2011
For moments, I saw all cars. But then, I turn off the server and the cars went transparent again (only 2 cars and 3 bikes didn't go transparent)
Re: [PROBLEM] Car selling at dealerships -
Tommy_Mandaz - 01.05.2011
Okay umm... Show me your onplayerstatechange and onplayerentervehicle... One of those probably has the bike problem.
Re: [PROBLEM] Car selling at dealerships -
vicesource - 01.05.2011
Quote:
Originally Posted by Tommy_Mandaz
Okay umm... Show me your onplayerstatechange and onplayerentervehicle... One of those probably has the bike problem.
|
OnPlayerEnterVehicle :
http://pastebin.com/9YGjB0tu
IfPlayerStateChange :
http://pastebin.com/PS2WPM2m
All the code of car dealerships (I've searched for the word "dealership") :
http://pastebin.com/Q1e8upu0