14.02.2014, 16:42
(
Последний раз редактировалось AntonioCroatia; 14.02.2014 в 16:55.
Причина: FIXED
)
I wanna make with SetPlayerObjectMaterialText to show player class behind of player, I put the object and player pos close to object but MaterialText don't work, no errors, no warnings
Here's the code
EDIT: FIXED CreateObject must be CreatePlayerObject
Here's the code
Код:
public OnPlayerRequestClass(playerid, classid) { SetPlayerPos(playerid,-2667.84229, -299.69055, 16.93143); SetPlayerFacingAngle(playerid,320.9217); SetPlayerCameraPos(playerid, -2661.2222, -293.6193, 20.5209); SetPlayerCameraLookAt(playerid, -2661.9329, -294.3244, 20.4807); spawnobjekt = CreateObject(19353, -2670.07764, -301.65512, 20.69875, 0.00000, 0.00000, 45.48000); switch (classid) { case 0, 1, 2: // Classes that will be truckdrivers { SetPlayerObjectMaterialText(playerid, spawnobjekt, "Class 1", 0, OBJECT_MATERIAL_SIZE_256x128,"Arial", 28, 0, 0xFFFF8200, 0xFF000000, OBJECT_MATERIAL_TEXT_ALIGN_CENTER); // Display the name of the class GameTextForPlayer(playerid, TXT_ClassTrucker, 5000, 4); // Store the class for the player (truckdriver) APlayerData[playerid][PlayerClass] = ClassTruckDriver; } case 3, 4: // Classes that will be bus-drivers { // Display the name of the class GameTextForPlayer(playerid, TXT_ClassBusDriver, 5000, 4); SetPlayerObjectMaterialText(playerid, spawnobjekt, "Class 2", 0, OBJECT_MATERIAL_SIZE_256x128,"Arial", 28, 0, 0xFFFF8200, 0xFF000000, OBJECT_MATERIAL_TEXT_ALIGN_CENTER); APlayerData[playerid][PlayerClass] = ClassBusDriver; } . . .