[Plugin] Streamer Plugin

Do you know if it is possible to make a UpdateDynamicPickup?
For now we must Destroy and then Create, and it is not practical at all.

Thanks.
Reply

Does it works with 1000 players version of 0.3z R2-2?
Reply

Quote:
Originally Posted by Baltimore
Посмотреть сообщение
Do you know if it is possible to make a UpdateDynamicPickup?
For now we must Destroy and then Create, and it is not practical at all.

Thanks.
You can manipulate everything using Streamer_SetIntData or Streamer_SetFloatData.

Example for changing the position of a pickup:

pawn Код:
Streamer_SetFloatData(STREAMER_TYPE_PICKUP, pickupid, E_STREAMER_X, 0.0);
Streamer_SetFloatData(STREAMER_TYPE_PICKUP, pickupid, E_STREAMER_Y, 0.0);
Streamer_SetFloatData(STREAMER_TYPE_PICKUP, pickupid, E_STREAMER_Z, 0.0);
Look at the enumerations, you can change every attribute.
Reply

I'm making a petrol trucker job, am using CreateDynamicCP, however I have some problems. I can't see the red checkpoint (of the dynamiccp) on radar when I'm far from the checkpoint. I guess it means its local, how do I make it global? need quick reply asap
Reply

Could we get a way to check a player's LoS of a 3D Text Label with testlos on?

IsPlayerIn3DTextLabelLoS(playerid, Text3D:id);

Would be great for scripts that rely on checking a player's line of sight.
Reply

Well how to upgrade the streamer to the latest version?
Reply

download it from the ling at the first page of this topic,then compile your gamemode with the new plugins and includes,then upload the re-compiled script and the downloaded plugins and includes in your server's directory
Reply

Just a question: vehicle streamer in samp is in the client or server side?
Reply

Is there any possible way to detect model ID of an object you are shooting at? I tried to script this and it returned wrong IDs. I suspect it's caused by combining normal objects with dynamic objects... but I'm not sure.

Here's the code:

Код:
public OnPlayerWeaponShot(playerid, weaponid, hittype, hitid, Float:fX, Float:fY, Float:fZ)
{
	if (hittype == BULLET_HIT_TYPE_PLAYER_OBJECT)
	{
	    new string[50];
	    format(string, 50, "objectid: %d", hitid);
	    SendClientMessage(playerid, -1, string);

	    new model = Streamer_GetIntData(STREAMER_TYPE_OBJECT, hitid, E_STREAMER_MODEL_ID);
	    format(string, 50, "model: %d", model);
	    SendClientMessage(playerid, -1, string);
	}

    return 1;
}
Reply

Quote:
Originally Posted by _BuLLeT_
Посмотреть сообщение
Is there any possible way to detect model ID of an object you are shooting at? I tried to script this and it returned wrong IDs. I suspect it's caused by combining normal objects with dynamic objects... but I'm not sure.

Here's the code:

Код:
public OnPlayerWeaponShot(playerid, weaponid, hittype, hitid, Float:fX, Float:fY, Float:fZ)
{
	if (hittype == BULLET_HIT_TYPE_PLAYER_OBJECT)
	{
	    new string[50];
	    format(string, 50, "objectid: %d", hitid);
	    SendClientMessage(playerid, -1, string);

	    new model = Streamer_GetIntData(STREAMER_TYPE_OBJECT, hitid, E_STREAMER_MODEL_ID);
	    format(string, 50, "model: %d", model);
	    SendClientMessage(playerid, -1, string);
	}

    return 1;
}
This is used by:

Код:
OnPlayerShootDynamicObject(playerid, weaponid, objectid, Float:x, Float:y, Float:z);
Reply

Quote:
Originally Posted by Uberanwar
Посмотреть сообщение
I'm making a petrol trucker job, am using CreateDynamicCP, however I have some problems. I can't see the red checkpoint (of the dynamiccp) on radar when I'm far from the checkpoint. I guess it means its local, how do I make it global? need quick reply asap
Use the stream distance to adjust it. However, you can also create a MapIcon (type 0, color 0xFF0000FF) and set it to MAPICON_GLOBAL and a high stream distance (if streamed).

Quote:
Originally Posted by kurta999
Посмотреть сообщение
Just a question: vehicle streamer in samp is in the client or server side?
It's server sided, the client doesnt hold any information about vehicles that are not streamed in.
Reply

Quote:
Originally Posted by NaS
Посмотреть сообщение
It's server sided, the client doesnt hold any information about vehicles that are not streamed in.
Nice, thank you I'm started to work on vehicle streamer for this plugin, in future, then I can just reaplce default vehicle system which I'll add into streamer plugin. Bye 2000 vehicle limit.
Reply

Quote:
Originally Posted by d711728
Посмотреть сообщение
This is used by:

Код:
OnPlayerShootDynamicObject(playerid, weaponid, objectid, Float:x, Float:y, Float:z);
Oh, didn't know that... thanks
Reply

Quote:
Originally Posted by kurta999
Посмотреть сообщение
Nice, thank you I'm started to work on vehicle streamer for this plugin, in future, then I can just reaplce default vehicle system which I'll add into streamer plugin. Bye 2000 vehicle limit.
That would be nice. And also vehicle limit is 2048. (??)

Hope "Incognito" will support it!
Reply

Vehicle limit is 2000.
Reply

Quote:
Originally Posted by kurta999
Посмотреть сообщение
I'm started to work on vehicle streamer for this plugin, in future, then I can just reaplce default vehicle system which I'll add into streamer plugin. Bye 2000 vehicle limit.
I love you.

Pain123 aka madinator started a Vehicle Streamer Plugin, but he hasn't worked on it since few months ago (you can see it on his github account). It will be way better if the Streamer Plugin will have incorporated vehicles. It's a rough work, I hope you will successfully make it.
Reply

https://sampforum.blast.hk/showthread.php?tid=526467
Reply

Why OnPlayerEditObject isn't called on linux, but on Windows works?
OnPlayerEditDynamicObject works, but normal not.
Reply

....
Reply

Hello, I use this code to generate a random checkpoint from an SQL table:

Код:
RandomGenerateCP(playerid)
{
	new result[150], Float:x, Float:y, Float:z, streetname[50];
	mysql_query( "SELECT * FROM  `streetcorners` ORDER BY RAND( ) LIMIT 1;" );
	mysql_store_result();

	if(mysql_fetch_row_format(result))
	{
		sscanf( result, "p<|>{i}fffs[50]", x, y, z, streetname );
		DestroyDynamicRaceCP(MissionCPMapicon[playerid][0]);
		DestroyDynamicMapIcon(MissionCPMapicon[playerid][1]);
        MissionCPMapicon[playerid][0] = CreateDynamicRaceCP(2, x, y, z, -2000.0, 2000.0, 0.0, 3.0, _, _, playerid );
        MissionCPMapicon[playerid][1] = CreateDynamicMapIcon(x, y, z, 0, 0xFF0000FF, _, _, playerid, 2000.0, MAPICON_GLOBAL);
	}
	mysql_free_result();
	return streetname;
}
Unfortunately, whenever this script runs with two or more players, their checkpoints (and sometimes their mapicons) seem to get destroyed as well.

For example: RandomGenerateCP(1) gets called when player #1 does some action. At the same time, all the other players who got a CP using this function have their CPs removed. What can be done to prevent this or what am I doing wrong?
Reply


Forum Jump:


Users browsing this thread: 7 Guest(s)