SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Reply
 
Thread Tools Display Modes
Old 19/05/2020, 12:17 AM   #1
Zekiloni
Little Clucker
 
Join Date: Dec 2013
Posts: 47
Reputation: 4
Default Problem with vehicles..

Hi i have problem with vehicles, after entering and exiting interiors (businesses, houses, custom entrances) vehicles doesn't load to players, Player Virtual World and Player Interior is good and vehicles interiors / viruatl worlds are good too but it doesn't load to players, can someone help me ?
Zekiloni is offline   Reply With Quote
Old 19/05/2020, 06:41 AM   #2
GameOvr
Huge Clucker
 
GameOvr's Avatar
 
Join Date: Jun 2018
Posts: 296
Reputation: 9
Default Re: Problem with vehicles..

well there's a bug in samp with these interiors & vehicles! Try adding this,
Code:
public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
{
	if(newinteriorid == 0)
	{
		SetPlayerVirtualWorld(playerid, 0);
	}
	else
	{
		SetPlayerVirtualWorld(playerid, 1);
	}
}
__________________
GameOvr is offline   Reply With Quote
Old 19/05/2020, 09:13 AM   #3
StevenLV
Big Clucker
 
StevenLV's Avatar
 
Join Date: Apr 2017
Location: Pakistan
Posts: 144
Reputation: 11
Default Re: Problem with vehicles..

Well, When you are entering a house so you must be setting their interiors as well. so player interior id and virtual world might be changed to other value than 0. SO when you exit you have to set them back to what it was beforehand, probably zero.
__________________
Quote:
Eternal Life Roleplay - An upcoming unique RP server based in Palomino Creek
https://discord.gg/JWzE78r
Quote:
Originally Posted by !damo!spiderman View Post
You're pathetic. Stand for something that's going to help the world rather than fill it with more hate. Give someone a hug, tell someone you care... Do something, do anything but do it with love not hate.
StevenLV is offline   Reply With Quote
Old 19/05/2020, 01:26 PM   #4
Zekiloni
Little Clucker
 
Join Date: Dec 2013
Posts: 47
Reputation: 4
Default Re: Problem with vehicles..

Quote:
Originally Posted by StevenLV View Post
Well, When you are entering a house so you must be setting their interiors as well. so player interior id and virtual world might be changed to other value than 0. SO when you exit you have to set them back to what it was beforehand, probably zero.

Yeh, code is like thath but doesnt work but i eill with onplayerinterior chamge
Zekiloni is offline   Reply With Quote
Old 19/05/2020, 03:35 PM   #5
Zekiloni
Little Clucker
 
Join Date: Dec 2013
Posts: 47
Reputation: 4
Default Re: Problem with vehicles..

Quote:
Originally Posted by GameOvr View Post
well there's a bug in samp with these interiors & vehicles! Try adding this,
Code:
public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
{
	if(newinteriorid == 0)
	{
		SetPlayerVirtualWorld(playerid, 0);
	}
	else
	{
		SetPlayerVirtualWorld(playerid, 1);
	}
}
doesnt work
Zekiloni is offline   Reply With Quote
Old 19/05/2020, 11:43 PM   #6
Grim_
High-roller
 
Grim_'s Avatar
 
Join Date: Sep 2008
Location: United States
Posts: 2,896
Reputation: 118
Default Re: Problem with vehicles..

We cannot help you without some code to look at.
Grim_ is offline   Reply With Quote
Old 20/05/2020, 02:31 PM   #7
Zekiloni
Little Clucker
 
Join Date: Dec 2013
Posts: 47
Reputation: 4
Default Re: Problem with vehicles..

Quote:
Originally Posted by Grim_ View Post
We cannot help you without some code to look at.
can you add me on discord and help me ? zekiloni#2982
Zekiloni is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem with vehicles buburuzu19 Scripting Help 5 02/09/2015 09:51 AM
Problem on vehicles NoNamed Scripting Help 2 25/07/2015 04:31 PM
RC Vehicles problem! Marios Help Archive 2 02/01/2011 08:25 PM
problem with vehicles [IL]HeHu Help Archive 0 19/09/2010 10:24 AM
Problem with vehicles Dj_maryo1993 Help Archive 4 02/08/2009 09:13 PM


All times are GMT. The time now is 02:22 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.