CreateDynamicObject not work
#1

Well i have problem when i add object to interior with CreateDynamicObject ,that is not work please help me this is my pawn code
Код:
#include < a_samp >
new hq;
native CreateDynamicObject(modelid, Float:x, Float:y, Float:z, Float:rx, Float:ry, Float:rz, worldid = -1, interiorid = -1, playerid = -1, Float:distance = 200.0);
native DestroyDynamicObject(objectid);
native IsValidDynamicObject(objectid);
native SetDynamicObjectPos(objectid, Float:x, Float:y, Float:z);
native GetDynamicObjectPos(objectid, &Float:x, &Float:y, &Float:z);
native SetDynamicObjectRot(objectid, Float:rx, Float:ry, Float:rz);
native GetDynamicObjectRot(objectid, &Float:rx, &Float:ry, &Float:rz);
native MoveDynamicObject(objectid, Float:x, Float:y, Float:z, Float:speed);
native StopDynamicObject(objectid);
native DestroyAllDynamicObjects();
native CountDynamicObjects();

public OnGameModeInit()
{
  
    DisableInteriorEnterExits( );
    hq = CreatePickup(1318,1,1316.94384766,-1183.64697266,23.83783913);
    CreateDynamicObject(14534,1546.51159668,3.73561096,977.27154541,0.00000000,0.00000000,0.00000000); //object(ab_woozies01) (1)
	CreateDynamicObject(5043,1552.45031738,6.18205786,974.07788086,0.00000000,0.00000000,270.00000000); //object(bombdoor_las) (1)
	CreateDynamicObject(14544,1546.32946777,3.84501886,975.33319092,0.00000000,0.00000000,0.00000000); //object(ab_woozies02) (1)
	CreateDynamicObject(14545,1550.85522461,2.14403176,974.82238770,0.00000000,0.00000000,0.00000000); //object(ab_wooziesglass) (1)
	CreateDynamicObject(14535,1551.17871094,3.81998134,979.88830566,0.00000000,0.00000000,0.00000000); //object(ab_woozies03) (1)
	CreateDynamicObject(14543,1547.89477539,7.46615887,979.90551758,0.00000000,0.00000000,0.00000000); //object(ab_woozies04) (1)
	
    
    
    return 1;
}

public OnPlayerCommandText( playerid, cmdtext[ ] )
{
    if( strcmp( "/enter", cmdtext, true, 6) == 0)
    {
        if( IsPlayerInRangeOfPoint( playerid,10,1316.94384766,-1183.64697266,23.83783913 ) )
        {
            SetPlayerPos( playerid,1552.38305664,5.53334618,974.64501953 );
			SetPlayerInterior(playerid,3);

			return 1;
        }
    }
    if( strcmp( "/exit",cmdtext,true,6) == 0)
    {
        if( IsPlayerInRangeOfPoint( playerid,10, 1552.38305664,5.53334618,974.64501953) )
        {
            SetPlayerPos( playerid, 1316.94384766,-1183.64697266,23.83783913);
            SetPlayerInterior(playerid,0);
            
            return 1;
        }
    }
    return 0;
}
public OnPlayerPickUpPickup( playerid, pickupid )
{
    if(pickupid == hq)
        {
        GameTextForPlayer(playerid,"~r~ /enter ~y~ to get inside Wah Ching Triads HeadQuarter",5000,5);
        }
	return 1;
}
Reply
#2

1. Chill and don't bump topic.
2. Re-Convert objects.
Reply
#3

try putting #include <streamer> under a_samp

make sure you have all the other parts the streamer needs.
Reply
#4

Quote:
Originally Posted by Hayden_Bruin
Посмотреть сообщение
try putting #include <streamer> under a_samp

make sure you have all the other parts the streamer needs.
Thanks bro
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)