[HELP] streamer-object fall through -
Matthew_Murdoch - 07.12.2009
I'm currently using a streamer for my objects.
2 problems are really getting to me.
1. Prison out at sea used for faction spawn point and vehicles for the faction.
When i initially spawn there, i fall through the objects, (due to streamed objects use view distance) and vehicles fall through aswell into the sea, requiring me to tele again and to type /respawnvehicles
2. Basically the same as 1 but a shamal interior, when "g" is pressed, 50% of the time i fall through objects down to a impending d00m.
How do i fix this fallthrough effect.
Re: [HELP] streamer-object fall through -
dice7 - 07.12.2009
Create the objects on which you teleport with CreateObject() so they will be static
Re: [HELP] streamer-object fall through -
Matthew_Murdoch - 07.12.2009
Quote:
Originally Posted by dice7
Create the objects on which you teleport with CreateObject() so they will be static
|
tried that, somehow conflicts with streamer and other objects don't appear
Re: [HELP] streamer-object fall through -
Goobiiify - 07.12.2009
I have same problem, I was thinking about higher the Z float 1-2 meters up on the sky so when someone goes there, They will fall down at the object. I have not tested it but it could work.
Re: [HELP] streamer-object fall through -
S1nn3r - 14.02.2010
This is what I use, it works for 95% of the time.
under OnGameModeInit() or OnFilterScriptInit()
Код:
forward loadobject(playerid);
At the bottom of the script (place under nothing)
Код:
public loadobject(playerid)
{
if IsPlayerInAnyVehicle(playerid)*then
{
new Float:minvx, Float:minvy, Float:minvz;
GetVehiclePos(GetPlayerVehicleID(playerid), minvx, minvy, minvz);
SetVehicleZAngle(GetPlayerVehicleID(playerid), 90);
SetVehiclePos(GetPlayerVehicleID(playerid), minvx, minvy, (minvz + 3));
RemovePlayerFromVehicle(playerid);
SendClientMessage(playerid, 0x33AA33AA, "[TELEPORT] You were ejected from your vehicle to allow objects to load");
return 1;
}
else
{
new Float:minpx, Float:minpy, Float:minpz;
GetPlayerPos(playerid, minpx, minpy, minpz);
SetPlayerPos(playerid, minpx, minpy, (minpz + 3));
}
return 1;
}
Example of a teleport, place this under OnPlayerCommandText()
Код:
new vehID = GetPlayerVehicleID(playerid);//Gets vehicle ID for teleport
if (strcmp("/10miledrag", cmdtext, true, 10) == 0 || strcmp(cmdtext, "/10md", true) == 0)
{
if(IsPlayerInAnyVehicle(playerid))
{
SetVehiclePos(vehID, 3087.39453125, -1427.994140625, 15.377157211304);//10miledrag Freeze Car
}
else//if they are not in a vehicle
{
SetPlayerPos(playerid, 3087.39453125, -1427.994140625, 15.377157211304);//10miledrag Freeze player
}
GameTextForPlayer(playerid, "~g~Welcome To~n~~b~ The DragStrip!", 5000, 5);
SetTimerEx("loadobject", 500, 0, "d", playerid);
SendClientMessage(playerid, 0x00f6f6AA, "Welcome to 10-Mile-Drag Strip!");
return 1;
}
Re: [HELP] streamer-object fall through -
kLx - 14.02.2010
I'm using this type on my server.
On teleport command I set
pawn Код:
TogglePlayerControllable( playerid, false );
SetTimerEx( "UnfreezePlayer", 5000, 0, "i", playerid );
GameTextForPlayer(playerid," Please wait 5 seconds... ",5000, 6);
And of course an UnfreezePlayer function.
pawn Код:
forward UnfreezePlayer( playerid );
public UnfreezePlayer( playerid )
{
TogglePlayerControllable( playerid, true );
return 1;
}
This will freeze player for five seconds in the air, till objects load. Works for me.
Cheers, kLx
Re: [HELP] streamer-object fall through -
S1nn3r - 14.02.2010
Quote:
Originally Posted by kLx
I'm using this type on my server.
On teleport command I set
pawn Код:
TogglePlayerControllable( playerid, false ); SetTimerEx( "UnfreezePlayer", 5000, 0, "i", playerid ); GameTextForPlayer(playerid," Please wait 5 seconds... ",5000, 6);
And of course an UnfreezePlayer function.
pawn Код:
forward UnfreezePlayer( playerid ); public UnfreezePlayer( playerid ) { TogglePlayerControllable( playerid, true ); return 1; }
This will freeze player for five seconds in the air, till objects load. Works for me.
Cheers, kLx ![cheesy](images/smilies/lol.gif)
|
That won't freeze the car, same problem.
Re: [HELP] streamer-object fall through -
jtweak - 07.12.2011
i suggest getting a new streamer :S im having this problem, im gonna try incognitos now wish me luck
Re: [HELP] streamer-object fall through -
Babul - 07.12.2011
using Incognito's streamer, the fall-thru problem can be solved by using
Код:
Streamer_Update(playerid);
directly before teleporting a player. another trick to speed it up, is to "prespawn" important objects (floor/ground) by letting the player see it after logging in. even a brief moment will cause the object being preloaded, this helps to prevent the missing-texture-bug for high placed objects aswell:
for spawning ON the cityhall stairs (inside, at the roof entrance), an additional (but not visible) stairs object placed outside the entrance forces the object getting streamed for any player who wants to enter. it uses just 1 more object, which is certainly no waste, using that awesome streamer
Re: [HELP] streamer-object fall through -
khimera - 20.09.2014
Quote:
Originally Posted by S1nn3r
This is what I use, it works for 95% of the time.
under OnGameModeInit() or OnFilterScriptInit()
Код:
forward loadobject(playerid);
At the bottom of the script (place under nothing)
Код:
public loadobject(playerid)
{
if IsPlayerInAnyVehicle(playerid)*then
{
new Float:minvx, Float:minvy, Float:minvz;
GetVehiclePos(GetPlayerVehicleID(playerid), minvx, minvy, minvz);
SetVehicleZAngle(GetPlayerVehicleID(playerid), 90);
SetVehiclePos(GetPlayerVehicleID(playerid), minvx, minvy, (minvz + 3));
RemovePlayerFromVehicle(playerid);
SendClientMessage(playerid, 0x33AA33AA, "[TELEPORT] You were ejected from your vehicle to allow objects to load");
return 1;
}
else
{
new Float:minpx, Float:minpy, Float:minpz;
GetPlayerPos(playerid, minpx, minpy, minpz);
SetPlayerPos(playerid, minpx, minpy, (minpz + 3));
}
return 1;
}
Example of a teleport, place this under OnPlayerCommandText()
Код:
new vehID = GetPlayerVehicleID(playerid);//Gets vehicle ID for teleport
if (strcmp("/10miledrag", cmdtext, true, 10) == 0 || strcmp(cmdtext, "/10md", true) == 0)
{
if(IsPlayerInAnyVehicle(playerid))
{
SetVehiclePos(vehID, 3087.39453125, -1427.994140625, 15.377157211304);//10miledrag Freeze Car
}
else//if they are not in a vehicle
{
SetPlayerPos(playerid, 3087.39453125, -1427.994140625, 15.377157211304);//10miledrag Freeze player
}
GameTextForPlayer(playerid, "~g~Welcome To~n~~b~ The DragStrip!", 5000, 5);
SetTimerEx("loadobject", 500, 0, "d", playerid);
SendClientMessage(playerid, 0x00f6f6AA, "Welcome to 10-Mile-Drag Strip!");
return 1;
}
|
Does this work guys? Is there any update for this type of problem? If someone knows something, please reply. Thank you