14.07.2014, 04:31
Olб , Schocc
Por gentileza seria isso aqui ?
Por gentileza seria isso aqui ?
Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) { switch(dialogid) { case DIALOG_ATTACH_INDEX_SELECTION: { if(response) { if(IsPlayerAttachedObjectSlotUsed(playerid, listitem)) { ShowPlayerDialog(playerid, DIALOG_ATTACH_EDITREPLACE, DIALOG_STYLE_MSGBOX, \ "{FF0000}Acessуrios {FFFFFF}- Modificaзгo", "Vocк deseja editar ou deletar seu acessуrio?", "Editar", "Deletar"); } else { new string[4000+1]; for(new x;x<sizeof(AttachmentObjects);x++) { format(string, sizeof(string), "%s%s\n", string, AttachmentObjects[x][attachname]); } ShowPlayerDialog(playerid, DIALOG_ATTACH_MODEL_SELECTION, DIALOG_STYLE_LIST, \ "{FF0000}Acessуrios Modificaзгo {FFFFFF}- Selecionar o modelo", string, "Selecionar", "Cancelar"); } SetPVarInt(playerid, "AttachmentIndexSel", listitem); } return 1; } case DIALOG_ATTACH_EDITREPLACE: { if(response) EditAttachedObject(playerid, GetPVarInt(playerid, "AttachmentIndexSel")); else RemovePlayerAttachedObject(playerid, GetPVarInt(playerid, "AttachmentIndexSel")); DeletePVar(playerid, "AttachmentIndexSel"); return 1; } case DIALOG_ATTACH_MODEL_SELECTION: { if(response) { if(GetPVarInt(playerid, "AttachmentUsed") == 1) EditAttachedObject(playerid, listitem); else { SetPVarInt(playerid, "AttachmentModelSel", AttachmentObjects[listitem][attachmodel]); new string[256+1]; for(new x;x<sizeof(AttachmentBones);x++) { format(string, sizeof(string), "%s%s\n", string, AttachmentBones[x]); } ShowPlayerDialog(playerid, DIALOG_ATTACH_BONE_SELECTION, DIALOG_STYLE_LIST, \ "{FF0000}Acessуrios {FFFFFF}- Selecionar o Local", string, "Selecionar", "Cancelar"); } } else DeletePVar(playerid, "AttachmentIndexSel"); return 1; } case DIALOG_ATTACH_BONE_SELECTION: { if(response) { SetPlayerAttachedObject(playerid, GetPVarInt(playerid, "AttachmentIndexSel"), GetPVarInt(playerid, "AttachmentModelSel"), listitem+1); EditAttachedObject(playerid, GetPVarInt(playerid, "AttachmentIndexSel")); SendClientMessage(playerid, 0xFFFFFFFF, "{FF0000}Acessуrios {FFFFFF}- Use o mouse para editar o acessуrio"); } DeletePVar(playerid, "AttachmentIndexSel"); DeletePVar(playerid, "AttachmentModelSel"); return 1; } } TogglePlayerControllable(playerid, 1); new string[128]; new giveplayer[MAX_PLAYER_NAME]; GetPlayerName(meavalie[playerid], giveplayer, sizeof(giveplayer)); GetPlayerName(playerid, sendername, sizeof(sendername)); if(dialogid == DIALOG_MEAVALIE) { if(response == 1) { SendClientMessage(meavalie[playerid],0x0000FFAA,"O Jogador qualificou a sua ajuda como POSITIVA, voce ganhou 1 nivel."); PlayerInfo[meavalie[playerid]][pHelper] = PlayerInfo[meavalie[playerid]][pHelper]+1; format(string, sizeof(string), "Vocк avaliou a ajuda do Helper %s como: {9EC73D}positiva.",giveplayer); SendClientMessage(playerid,COR_HELPER,string); } if(response == 0) { SendClientMessage(meavalie[playerid],0xFF0000AA,"O Jogador qualificou a sua ajuda como NEGATIVA, vocк perdeu 1 nivel."); PlayerInfo[meavalie[playerid]][pHelper] = PlayerInfo[meavalie[playerid]][pHelper]-1; format(string, sizeof(string), "Vocк avaliou a ajuda do Helper %s como: {FF0000}negativa.",giveplayer); SendClientMessage(playerid,COR_HELPER,string); } return 1; } if(dialogid == 1) { if(response == 0) { SendClientMessage(playerid, TEAM_VAGOS_COLOR, "Vocк foi Kickado por nгo logar no Servidor!"); Kick(playerid); return 1; } if(response >= 1) { if(strlen(inputtext) == 0) { GetPlayerName(playerid,loginname,sizeof(loginname)); TogglePlayerControllable(playerid, 0); SetPlayerPos(playerid,1415.4329,-806.9493,85.0470); SetPlayerCameraPos(playerid,-1007.0601,-760.0924,178.6651); SetPlayerCameraLookAt(playerid,-1007.0601,-760.0924,178.6651); //InterpolateCameraPos(playerid, 1473.830810, -1066.777709, 216.777587, 1662.295776, -1305.846191, 208.834182, 25000, CAMERA_CUT); //InterpolateCameraPos(playerid, 1473.830810, -1066.777709, 216.777587, 1662.295776, -1305.846191, 208.834182, 25000, CAMERA_CUT); //InterpolateCameraLookAt(playerid, 1477.482666, -1070.184326, 217.019683, 1665.385986, -1308.891113, 206.348419, 25000, CAMERA_MOVE); format(loginstring,sizeof(loginstring),"\n\n{FFFFFF}********************************************\n\nConta: %s\nStatus: {00FF00}Registrada\n\n********************************************\n\n{FFFFFF}- Digite sua senha abaixo para logar\n* Caso erre sua senha 6 vezes serб kikado!\n\n",loginname); ShowPlayerDialog(playerid, 1, DIALOG_STYLE_INPUT,"{00E5EE}Brasil {FFFFFF}Play {00E5EE}Faster",loginstring,"Logar","Cancelar"); return 1; } if(strval(inputtext) > 0) { strmid(StrPasswrd[playerid], inputtext, 0, strlen(inputtext), 255); Encrypt(StrPasswrd[playerid]); OnPlayerLogin(playerid); return 1; } strmid(StrPasswrd[playerid], inputtext, 0, strlen(inputtext), 255); Encrypt(StrPasswrd[playerid]); Hospital[playerid] = 1; SpawnPlayer(playerid); OnPlayerLogin(playerid); return 1; } return 1; } if(dialogid == 2) { if(response == 0) { SendClientMessage(playerid, TEAM_VAGOS_COLOR, "Vocк foi Kickado por nгo Registrar no Servidor!"); Kick(playerid); return 1; } if(response >= 1) { format(string, sizeof(string), OpenAccPlayer, PlayerName(playerid)); new File: hFile = fopen(string, io_read); if (hFile) { SendClientMessage(playerid, COLOR_YELLOW, "Este Nick jб existe, use outro."); fclose(hFile); Kick(playerid); return 1; } if(strlen(inputtext) == 0) { GetPlayerName(playerid,loginname,sizeof(loginname)); TogglePlayerControllable(playerid, 0); SetPlayerPos(playerid,1415.4329,-806.9493,85.0470); SetPlayerCameraPos(playerid,-1007.0601,-760.0924,178.6651); SetPlayerCameraLookAt(playerid,-1007.0601,-760.0924,178.6651); //InterpolateCameraPos(playerid, 1473.830810, -1066.777709, 216.777587, 1662.295776, -1305.846191, 208.834182, 25000, CAMERA_CUT); //InterpolateCameraPos(playerid, 1473.830810, -1066.777709, 216.777587, 1662.295776, -1305.846191, 208.834182, 25000, CAMERA_CUT); //InterpolateCameraLookAt(playerid, 1477.482666, -1070.184326, 217.019683, 1665.385986, -1308.891113, 206.348419, 25000, CAMERA_MOVE); format(loginstring,sizeof(loginstring),"\n\n{FFFFFF}********************************************\n\nConta: %s\nStatus: {FF0000}Nгo Registrada\n\n********************************************\n\n{FFFFFF}- Digite uma senha abaixo para registrar\n* OBS: Nгo passe sua senha para ninguem por questгo de seguranзa!\n\n",loginname); ShowPlayerDialog(playerid, 2, DIALOG_STYLE_INPUT,"{00E5EE}Brasil {FFFFFF}Play {00E5EE}Faster",loginstring,"Registrar","Cancelar"); return 1; } if(strval(inputtext) > 0) { if(strlen(inputtext) > 16) { SendClientMessage(playerid, TEAM_VAGOS_COLOR, "Erro: Sua senha nгo pode Conter mais de 16 Caracteres!"); SetPlayerPos(playerid,1415.4329,-806.9493,85.0470); SetPlayerCameraPos(playerid,-1007.0601,-760.0924,178.6651); SetPlayerCameraLookAt(playerid,-1007.0601,-760.0924,178.6651); //InterpolateCameraPos(playerid, 1473.830810, -1066.777709, 216.777587, 1662.295776, -1305.846191, 208.834182, 25000, CAMERA_CUT); //InterpolateCameraPos(playerid, 1473.830810, -1066.777709, 216.777587, 1662.295776, -1305.846191, 208.834182, 25000, CAMERA_CUT); //InterpolateCameraLookAt(playerid, 1477.482666, -1070.184326, 217.019683, 1665.385986, -1308.891113, 206.348419, 25000, CAMERA_MOVE); format(loginstring,sizeof(loginstring),"\n\n{FFFFFF}********************************************\n\nConta: %s\nStatus: {FF0000}Nгo Registrada\n\n********************************************\n\n{FFFFFF}- Digite uma senha abaixo para registrar\n* OBS: Nгo passe sua senha para ninguem por questгo de seguranзa!\n\n",loginname); ShowPlayerDialog(playerid, 2, DIALOG_STYLE_INPUT,"{00E5EE}Brasil {FFFFFF}Play {00E5EE}Faster",loginstring,"Registrar","Cancelar"); TogglePlayerControllable(playerid, 0); return true; } strmid(StrPasswrd[playerid], inputtext, 0, strlen(inputtext), 255); Encrypt(StrPasswrd[playerid]); OnPlayerRegister(playerid); return 1; } /*getdate(year, month, day); format(gstring, sizeof(gstring), "AdmCmd: %s Registrou no Servidor (%d-%d-%d), Senha: %s", PlayerName(playerid),day,month,year,StrPasswrd[playerid]); RegistroLog(gstring); SoEuVejoMsm(COLOR_YELLOW, gstring);*/ strmid(StrPasswrd[playerid], inputtext, 0, strlen(inputtext), 255); Encrypt(StrPasswrd[playerid]); OnPlayerRegister(playerid); return 1; } return 1; }