10.06.2014, 03:49
pawn Код:
if(dialogid == DIALOG_ATTACH_OBJECT2_SELECTION)
{
if(!response)
{ ShowPlayerDialog(playerid,DIALOG_ATTACH_OBJECT_SELECTION,DIALOG_STYLE_LIST,"Player Objects/Attachment: (Select Object Path)","Path:1 :: "COL_GREY"Server Objects Menu\n"COL_WHITE"Path:2 :: "COL_GREY"Custom Object","Next(>>)","Back(<<)"); }
if(response)
{
if(!strlen(inputtext))return SendClientMessage(playerid,-1,"PLAYER: You can't leave the coloumn blank."),ShowPlayerDialog(playerid,DIALOG_ATTACH_OBJECT2_SELECTION,DIALOG_STYLE_INPUT,"Player Objects/Attachment: (Insert objectid)",""COL_WHITE"Put your custom objectid below, You can also take help from ''http://wiki.sa-mp.com''.","Edit","Back(<<)");
if(!IsNumeric(inputtext)) return SendClientMessage(playerid,-1,"PLAYER: You can't fill a object name, only object id's allowed."),ShowPlayerDialog(playerid,DIALOG_ATTACH_OBJECT2_SELECTION,DIALOG_STYLE_INPUT,"Player Objects/Attachment: (Insert objectid)",""COL_WHITE"Put your custom objectid below, You can also take help from ''http://wiki.sa-mp.com''.","Edit","Back(<<)");
new obj;
if(!sscanf(inputtext, "i", obj))
{
if(GetPVarInt(playerid, "AttachmentUsed") == 1) EditAttachedObject(playerid, obj);
else
{
SetPVarInt(playerid, "AttachmentModelSel", obj);
new string[257];
new dialog[500];
for(new x;x<sizeof(AttachmentBones);x++)
{
format(string, sizeof(string), "Bone:%s\n", AttachmentBones[x]);
strcat(dialog,string);
}
ShowPlayerDialog(playerid, DIALOG_ATTACH_BONE_SELECTION, DIALOG_STYLE_LIST, \
"{FF0000}Attachment Modification - Bone Selection", dialog, "Select", "Cancel");
}
}
}
return 1;}