Attach Object
#5

Good ?

Код:
		}
		GetPlayerPos(playerid,X,Y,Z);
		GetPlayerFacingAngle(playerid, A);
		RadioInfo[id][rObject] = CreateDynamicObject(2103, X,Y,Z-1, 0.0, 0.0, A, GetPlayerVirtualWorld(playerid));
		format(string, sizeof(string),"[BOOM BOX]\n%s", PlayerName(playerid));
		RadioInfo[id][rText] = CreateDynamic3DTextLabel(string, COLOR_WHITE, X, Y, Z-0.25, 25.0, INVALID_PLAYER_ID, INVALID_VEHICLE_ID, 1, 0, 0, -1, 50.0);
		RadioInfo[id][rX] = X;
		RadioInfo[id][rY] = Y;
		RadioInfo[id][rZ] = Z;
		RadioInfo[id][rStatus] = 0;
		RadioInfo[id][rAreaID] = GetPlayerZone(playerid);
		strmid(RadioInfo[id][rOwner], PlayerName(playerid), 0, strlen(PlayerName(playerid)), 255);
		strmid(RadioInfo[id][rURL], "NUll", 0, strlen("NULL"), 255);
		SetPVarInt(playerid, "RadioPlant", 0);
		AttachObjectToVehicle(objectid, vehicleid, Float:fOffsetX, Float:fOffsetY, Float:fOffsetZ, Float:fRotX, Float:fRotY, Float:RotZ);
		SendClientMessage(playerid, COLOR_WHITE, "BoomBox planted, type (/editradio) to configure the radio options !");
    }
    else SendClientMessage(playerid, COLOR_LIGHTRED, "You don't have a radio to plant !");
	return 1;
}
I putted AttachObjectToVehicle(objectid, vehicleid, Float:fOffsetX, Float:fOffsetY, Float:fOffsetZ, Float:fRotX, Float:fRotY, Float:RotZ); there..
Reply


Messages In This Thread
Attach Object - by DonBonanno - 20.01.2014, 22:27
Re: Attach Object - by minijackc - 20.01.2014, 22:37
Re: Attach Object - by DonBonanno - 21.01.2014, 19:16
Re: Attach Object - by CutX - 21.01.2014, 19:29
Re: Attach Object - by DonBonanno - 21.01.2014, 19:50
Re: Attach Object - by CutX - 21.01.2014, 19:52

Forum Jump:


Users browsing this thread: 1 Guest(s)