Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <a_samp>
- #include <a_players>
- #include <a_vehicles>
- #include <DOF2>
- #include <zcmd>
- #include <streamer>
- #include <sscanf2>
- #include <time>
- //=-=-=-=-=-=-=-=-=-=-=[Defines]=-=-=-=-=-=-=
- #define CallBack:%0(%1) forward %0(%1); public %0(%1)
- #define GivePlayerMoneyEx(0%,1%) GivePlayerMoney(0%,1%)
- #define GetPlayerMoneyEx(0%) GetPlayerMoney(0%)
- #define ResetPlayerMoneyEx(0%) ResetPlayerMoney(0%)
- #define PastaC "Contas/%s.ini"
- #define DRegistro 0
- #define DLogin 1
- #define escolhaS 2
- #define DPerguntaS 3
- #define DMenuL 4
- #define DRecuperarS 5
- #define DMudarS 6
- #define Auxiliar 1
- #define AuxiliarAdministrativo 2
- #define SubSupervisor 3
- #define Supervisor 4
- #define Diretor 5
- #define Fundador 6
- #define FundadorP 7
- //=-=-=-=-=-=-=-=-=-=[Cores]=-=-=-=-=-=-=-=-=
- #define Vermelho 0xFF0000AA
- #define Branco 0xFFFFFFAA
- #define Grey 0x9C9C9CAA
- #define Gold 0xFFD700AA
- #define AzulClaro 0x00FFFFAA
- #define AzulPastoso 0x1E90FFAA
- //=-=-=-=-=-=-=-=-=[Variveis]=-=-=-=-=-=-=-=
- new bool:Logado[MAX_PLAYERS] = false;
- new PlayerText:TDEditor_PTD[MAX_PLAYERS][11];
- new PlayerText:Identidade[MAX_PLAYERS][12];
- new vConce[6];
- native gpci ( playerid, serial [ ], maxlen );
- main(){
- print("--------------------------------------------------\n");
- print("|( Game mode Criado por matheus_alcapone )|\n");
- print("|( Versão: 0.1 Versão ALPHA )|\n");
- print("|( Feito para o serve HardSimulatioN )|\n");
- print("-------------------------------------------------\n");
- }
- enum pInfo{
- Senha[128],
- Idade,
- Dinheiro,
- Admin,
- Matou,
- Morreu,
- Registro[128],
- PerguntaS[128],
- Logins,
- Profissao,
- Membro,
- Cargo,
- Lider,
- Sexo,
- Skin
- }
- new PlayerInfo[MAX_PLAYERS][pInfo];
- enum vInfo{
- Preco,
- Placa,
- Chave,
- Modelo,
- Cor[2],
- Tuning[12],
- float:Cord[3]
- }
- new VehicleInfo[MAX_VEHICLES][vInfo];
- public OnGameModeInit(){
- //=-=-=-=-=-=[Funções Basicas]=-=-=-=-=-=-=
- SendRconCommand("mapname HardSimulatioN");
- SetGameModeText("[PT/BR]HardSimulatioN[v0.1]");
- DisableInteriorEnterExits();
- EnableStuntBonusForAll(0);
- LimitGlobalChatRadius(10.0);
- ShowPlayerMarkers(0);
- UsePlayerPedAnims();
- //=-=-=-=-=-=-=-[Veiculos]-=-=-=-=-=-=-=-=-=-=-=
- // * Bikes spawn Civil
- CreateVehicle(510,1105.0090,-1414.6011,13.2016,6.4310,-1,-1,5*60000); // Bike spawn [1]
- CreateVehicle(510,1106.2190,-1414.6250,13.1960,3.2808,-1,-1,5*60000); // Bike spawn [2]
- CreateVehicle(510,1107.3538,-1414.7061,13.1946,1.2687,-1,-1,5*60000); // Bike spawn [3]
- CreateVehicle(510,1108.5986,-1414.6938,13.1818,0.0390,-1,-1,5*60000); // Bike spawn [4]
- CreateVehicle(510,1109.7562,-1414.6815,13.1898,0.5742,-1,-1,5*60000); // Bike spawn [5]
- CreateVehicle(510,1149.8489,-1414.1514,13.2689,1.2946,-1,-1,5*60000); // Bike spawn [6]
- CreateVehicle(510,1151.3152,-1414.4668,13.2650,6.4566,-1,-1,5*60000); // Bike spawn [7]
- CreateVehicle(510,1152.5093,-1414.6138,13.2641,1.4919,-1,-1,5*60000); // Bike spawn [8]
- CreateVehicle(510,1153.4348,-1414.6157,13.2582,355.6744,-1,-1,5*60000); // Bike spawn [9]
- CreateVehicle(510,1154.6731,-1414.6904,13.2471,3.6186,-1,-1,5*60000); // Bike spawn [10]
- //=-=-=-=-=-=-=[TextLabels]=-=-=-=-=-=-=-=-=-=
- vConce[0] = CreateVehicle(411,-1946.0298,273.6230,35.2010,134.1063,-1,-1,-1); // InFernus
- vConce[1] = CreateVehicle(429,-1945.7347,262.3352,35.1484,66.8525,-1,-1,-1); // Banshe
- vConce[2] = CreateVehicle(451,-1958.1732,260.4300,35.1765,313.0356,-1,-1,-1); // Turismo
- vConce[3] = CreateVehicle(541,-1960.7986,273.0448,35.0935,244.9409,-1,-1,-1); // Bullet
- vConce[4] = CreateVehicle(555,-1953.8431,300.8147,35.1526,137.8786,-1,-1,-1); // Windsor
- vConce[5] = CreateVehicle(560,-1961.4888,300.7726,35.1788,212.1538,-1,-1,-1); // Sultan
- for(new v; v < 6; v++){
- SetVehicleParamsEx(vConce[v], 0, 0, 0, 0, 0, 0, 0);
- }
- CreateObject(1998, -1963.53528, 280.20789, 34.64620, 0.00000, 0.00000, 264.00000);
- CreateObject(2002, -1964.66418, 278.12463, 34.47700, 0.00000, 0.00000, 92.00000);
- CreateObject(1724, -1960.61230, 281.16528, 34.46440, 0.00000, 0.00000, -90.00000);
- CreateObject(1724, -1960.53296, 278.82278, 34.46440, 0.00000, 0.00000, -90.00000);
- CreateObject(2356, -1963.71375, 279.50894, 34.46510, 0.00000, 0.00000, 260.00000);
- Create3DTextLabel("Concessionaria aperte 'F' para entrar no modo de compras ", 0x008080FF,-1961.2516,279.4977,35.4739, 40.0, 0, 0);
- return 1;
- }
- public OnGameModeExit(){
- DOF2_Exit();
- return 1;
- }
- public OnPlayerRequestClass(playerid, classid){
- printf("Chamo a CallBack OnPlayerRequestClass");
- MenuL(playerid);
- return 1;
- }
- public OnPlayerConnect(playerid){
- //=-=-=-=-=-=-=-=-
- TextsDraws(playerid);
- SendFormatMsg(playerid, Branco,"{FF0000}Seja Bem-Vindo(a){FFFFFF} ao {FF0000}Hard{9C9C9C}SimulatioN{FFFFFF} %s", Nome(playerid));
- printf("Chamo a CallBack OnPlayerConnect");
- RemoveBuildingForPlayer(playerid, 625, -1960.8438, 305.3516, 35.3672, 0.25);
- RemoveBuildingForPlayer(playerid, 632, -1950.7500, 307.0938, 34.8906, 0.25);
- RemoveBuildingForPlayer(playerid, 632, -1950.4141, 304.8906, 34.8906, 0.25);
- RemoveBuildingForPlayer(playerid, 632, -1952.8672, 307.1719, 34.8906, 0.25);
- RemoveBuildingForPlayer(playerid, 632, -1943.2422, 256.9609, 34.8906, 0.25);
- RemoveBuildingForPlayer(playerid, 625, -1960.8438, 264.7578, 35.3672, 0.25);
- RemoveBuildingForPlayer(playerid, 625, -1960.8438, 277.5859, 35.3672, 0.25);
- RemoveBuildingForPlayer(playerid, 632, -1950.6406, 275.9219, 34.8906, 0.25);
- RemoveBuildingForPlayer(playerid, 632, -1948.8828, 276.0703, 34.8906, 0.25);
- RemoveBuildingForPlayer(playerid, 632, -1950.6016, 278.3594, 34.8906, 0.25);
- return 1;
- }
- public OnPlayerDisconnect(playerid, reason){
- SalvarPlayer(playerid);
- PlayerTextDrawDestroy(playerid, TDEditor_PTD[playerid][0]);
- PlayerTextDrawDestroy(playerid, TDEditor_PTD[playerid][1]);
- PlayerTextDrawDestroy(playerid, TDEditor_PTD[playerid][2]);
- PlayerTextDrawDestroy(playerid, TDEditor_PTD[playerid][3]);
- PlayerTextDrawDestroy(playerid, TDEditor_PTD[playerid][4]);
- PlayerTextDrawDestroy(playerid, TDEditor_PTD[playerid][5]);
- PlayerTextDrawDestroy(playerid, TDEditor_PTD[playerid][6]);
- PlayerTextDrawDestroy(playerid, TDEditor_PTD[playerid][7]);
- PlayerTextDrawDestroy(playerid, TDEditor_PTD[playerid][8]);
- PlayerTextDrawDestroy(playerid, TDEditor_PTD[playerid][9]);
- PlayerTextDrawDestroy(playerid, TDEditor_PTD[playerid][10]);
- Logado[playerid] = false;
- return 1;
- }
- public OnPlayerSpawn(playerid){
- Logado[playerid] = true;
- printf("Chamo a CallBack OnPlayerSpawn");
- if(PlayerInfo[playerid][Profissao] == 0 && PlayerInfo[playerid][Membro] == 0)
- {
- SetPlayerSkin(playerid, PlayerInfo[playerid][Skin]);
- SetPlayerPos(playerid, 1128.7819,-1489.0035,22.7690);
- SetPlayerHealth(playerid, 100.0);
- }
- return 1;
- }
- public OnPlayerDeath(playerid, killerid, reason){
- PlayerInfo[playerid][Morreu] ++;
- PlayerInfo[killerid][Matou] ++;
- return 1;
- }
- public OnVehicleSpawn(vehicleid){
- return 1;
- }
- public OnVehicleDeath(vehicleid, killerid){
- return 1;
- }
- public OnPlayerText(playerid, text[]){
- new Float:Pos[3],String[128];
- GetPlayerPos(playerid, Pos[0], Pos[1], Pos[2]);
- format(String, 128, "%s diz: %s", Nome(playerid),text);
- for(new i; i != GetMaxPlayers(); i++)
- {
- if(IsPlayerInRangeOfPoint(i, 20, Pos[0], Pos[1], Pos[2])){
- SendClientMessage(i, -1, String);
- }
- }
- return 0;
- }
- public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger){
- return 1;
- }
- public OnPlayerExitVehicle(playerid, vehicleid){
- return 1;
- }
- public OnPlayerStateChange(playerid, newstate, oldstate){
- return 1;
- }
- public OnPlayerEnterCheckpoint(playerid){
- return 1;
- }
- public OnPlayerLeaveCheckpoint(playerid){
- return 1;
- }
- public OnPlayerEnterRaceCheckpoint(playerid){
- return 1;
- }
- public OnPlayerLeaveRaceCheckpoint(playerid){
- return 1;
- }
- public OnRconCommand(cmd[]){
- return 1;
- }
- public OnPlayerRequestSpawn(playerid){
- return 1;
- }
- public OnObjectMoved(objectid){
- return 1;
- }
- public OnPlayerObjectMoved(playerid, objectid){
- return 1;
- }
- public OnPlayerPickUpPickup(playerid, pickupid){
- return 1;
- }
- public OnVehicleMod(playerid, vehicleid, componentid){
- return 1;
- }
- public OnVehiclePaintjob(playerid, vehicleid, paintjobid){
- return 1;
- }
- public OnVehicleRespray(playerid, vehicleid, color1, color2){
- return 1;
- }
- public OnPlayerSelectedMenuRow(playerid, row){
- return 1;
- }
- public OnPlayerExitedMenu(playerid){
- return 1;
- }
- public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid){
- return 1;
- }
- public OnPlayerKeyStateChange(playerid, newkeys, oldkeys){
- if(newkeys == 16 && GetPlayerState(playerid) == PLAYER_STATE_ONFOOT){
- if(IsPlayerInRangeOfPoint(playerid, 2.0, 1123.4906,-2036.7927,69.8870)){
- SetPlayerInterior(playerid,3);SetPlayerPos(playerid,390.7658,173.7874,1008.3828);
- GameTextForPlayer(playerid, "~w~bem vindo a prefeitura", 5000, 1);
- }// Entar Pref
- else if(IsPlayerInRangeOfPoint(playerid, 2.0, 390.7658,173.7874,1008.3828)) {
- SetPlayerInterior(playerid,0);SetPlayerPos(playerid,1123.2390,-2037.1763,69.8876);
- }// Sair Prefeitura
- }
- return 1;
- }
- public OnRconLoginAttempt(ip[], password[], success){
- return 1;
- }
- public OnPlayerUpdate(playerid){
- return 1;
- }
- public OnPlayerStreamIn(playerid, forplayerid){
- return 1;
- }
- public OnPlayerStreamOut(playerid, forplayerid){
- return 1;
- }
- public OnVehicleStreamIn(vehicleid, forplayerid){
- return 1;
- }
- public OnVehicleStreamOut(vehicleid, forplayerid){
- return 1;
- }
- public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]){
- switch(dialogid){
- case DRegistro:{
- if(!response) Kick(playerid);
- if(strlen(inputtext) < 3 ||strlen(inputtext) > 15)return ShowPlayerDialog(playerid,DRegistro, DIALOG_STYLE_PASSWORD, "Registrar","Você excedeu o limite de carateres da senha, tente outra senha","Registrar","Cancelar");
- OnPlayerRegister(playerid, inputtext);
- }
- case DLogin:{
- if(!response)Kick(playerid);
- new str[128];
- format(str, sizeof(str),PastaC,Nome(playerid));
- if(strcmp(inputtext, desencript(DOF2_GetString( str, "Senha" )), true) == 0){
- CarregarPlayer(playerid);
- return 1;
- }
- else ShowPlayerDialog(playerid, DLogin, DIALOG_STYLE_PASSWORD,"Senha Errada","A senha que você usou esta errada","Logar","Cancelar");
- }
- case escolhaS:{
- TogglePlayerSpectating(playerid, 0);
- SpawnPlayer(playerid);
- if(!response){
- PlayerInfo[playerid][Sexo] = 1;
- PlayerInfo[playerid][Skin] = 226;
- SetPlayerSkin(playerid,226);
- SendClientMessage(playerid, 0x9C9C9C, "Ok, Você é do Sexo Feminino.");
- }
- if(response){
- PlayerInfo[playerid][Sexo] = 2;
- PlayerInfo[playerid][Skin] = 170;
- SetPlayerSkin(playerid,170);
- SendClientMessage(playerid, 0x9C9C9C, "Ok, Você é do Sexo Masculino.");
- }
- PlayerInfo[playerid][Logins] = 2;
- ShowPlayerDialog(playerid, DPerguntaS, DIALOG_STYLE_PASSWORD,"Escolha uma pergunta Secreta","Escolha uma pergunta secreta para recuperar a senha da sua conta. OBS: Minimo 3 caracteres maximo 15","Escolher","Cancelar");
- return true;
- }
- case DPerguntaS:{
- if(strlen(inputtext) < 3 ||strlen(inputtext) > 15)return ShowPlayerDialog(playerid, DPerguntaS, DIALOG_STYLE_PASSWORD,"Pergunta Secreta","Você excedeu o limite de caracteres da Pergunta Secreta escolha outra.","Escolher","Cancelar");
- new string[64],str[128];
- format(string, sizeof(str),PastaC,Nome(playerid));
- format(str, sizeof(str),"%s",encriptar(inputtext));
- DOF2_SetString(string,"PeguntaS",str);
- DOF2_SaveFile();
- CancelSelectTextDraw(playerid);
- SendFormatMsg(playerid, Branco, "{FF0000}[Seja Bem-Vindo]{FFFFFF}Seja Bem-Vindo ao servidor, você começou com 16 anos e R$500.00 para começar sua vida!.");
- return true;
- }
- case DMenuL:{
- switch(listitem){
- case 0:{
- Logar(playerid);
- }
- case 1:{
- ShowPlayerDialog(playerid, DRecuperarS, DIALOG_STYLE_PASSWORD,"Recuperar Senha","Digite a pergunta secreta para recuperar a senha","Recuperar","Cancelar");
- }
- case 2:{
- Logar(playerid);
- }
- }
- }
- case DRecuperarS:{
- if(!response) Kick(playerid);
- new str[128];
- format(str, sizeof(str),PastaC,Nome(playerid));
- if(strcmp(inputtext, desencript(DOF2_GetString( str, "PeguntaS" )), true) == 0){
- ShowPlayerDialog(playerid, DMudarS, DIALOG_STYLE_PASSWORD,"Mudar senha","Escolha uma nova senha","Mudar","Cancelar");
- }
- else{
- ShowPlayerDialog(playerid, DRecuperarS, DIALOG_STYLE_PASSWORD,"Pergunta Secreta","A pergunta secreta que você usou esta errada","Recuperar","Cancelar");
- }
- }
- case DMudarS:{
- if(strlen(inputtext) < 3 ||strlen(inputtext) > 15)return ShowPlayerDialog(playerid,DMudarS, DIALOG_STYLE_PASSWORD, "Registrar","Você excedeu o limite de caracteres da senha, tente outra senha","Registrar","Cancelar");
- new str[128];
- format(str, sizeof(str),PastaC,Nome(playerid));
- DOF2_SetString(str,"Senha",(encriptar(inputtext)));
- DOF2_SaveFile();
- Logar(playerid);
- }
- }
- return 1;
- }
- public OnPlayerClickPlayer(playerid, clickedplayerid, source){
- return 1;
- }
- public OnPlayerClickMap(playerid, Float:fX, Float:fY, Float:fZ){
- SetPlayerPos(playerid, fX, fY, fZ);
- return 1;
- }
- public OnPlayerGiveDamage(playerid, damagedid, Float:amount, weaponid){
- new Float:Life, Float:Coleete, Float:Dano;
- GetPlayerArmour(damagedid, Coleete);
- amount = amount/4;
- GetPlayerHealth(damagedid, Life);
- if(Coleete > 0){
- if(amount > Coleete){
- Dano = amount - Coleete;Life = Life - Dano;
- SetPlayerArmour(damagedid, 0.0);
- SetPlayerHealth(damagedid, Life);
- return 1;
- }
- Coleete = Coleete - amount;
- SetPlayerArmour(damagedid, Coleete);
- }
- if(Coleete < 1){Life = Life - amount;SetPlayerHealth(damagedid, Life);}
- return 1;
- }
- //=-=-=-=-=-=-=-=-=-=-=[CallBacks de funções]=-=-=-=-=-=-=-=-=-=-=
- CallBack:Logar(playerid){
- new str[252];
- format(str, sizeof(str),PastaC,Nome(playerid));
- if(!DOF2_FileExists(str)){
- format(str, sizeof(str),"{FFFFFF}A Conta {FF4500}%s{FFFFFF} ainda não esta registrada\nEscolha uma senha para registra-la. OBS: No minimo 3 e no maximo 15 caracteres",Nome(playerid));
- ShowPlayerDialog(playerid,DRegistro, DIALOG_STYLE_PASSWORD, "Seja Bem-Vindo(a)",str,"Registrar","Cancelar");
- }
- else
- {
- format(str,sizeof(str),"{FFFFFF}Status:{FF4500}(Registrada){FFFFFF}\nConta:{FF4500}(%s){FFFFFF}\nIdade:{FF4500}(%d){FFFFFF}\nData de Registro:{FF4500}(%s){FFFFFF}\nUse sua senha para logar",Nome(playerid), DOF2_GetInt(str,"Idade"),DOF2_GetString(str,"Data"));
- ShowPlayerDialog(playerid, DLogin, DIALOG_STYLE_PASSWORD, "Seja Bem-Vindo(a)",str,"Logar","Cancelar");
- }
- printf("Chamo a CallBack Logar");
- return true;
- }
- CallBack: OnPlayerRegister(playerid, password[]){
- new str[64], dia,mes,ano, string[24];
- format(str, sizeof(str),PastaC,Nome(playerid));
- DOF2_CreateFile(str);
- DOF2_SetString(str, "Senha", encriptar(password));
- DOF2_SetInt(str, "Idade", 16);
- DOF2_SetInt(str,"Dinheiro",500);
- DOF2_SetInt(str,"Admin",0);
- DOF2_SetInt(str,"Matou",0);
- DOF2_SetInt(str, "Morreu", 0);
- DOF2_SetInt(str, "Membro", 0);
- DOF2_SetInt(str, "Lider", 0);
- DOF2_SetInt(str, "Cargo", 0);
- DOF2_SetInt(str, "Profissao", 0);
- DOF2_SetInt(str, "Sexo", 0);
- getdate(ano,mes,dia);
- format(string, sizeof(string),"%02d/%02d/%02d",dia,mes,ano);
- DOF2_SetString(str,"Data", string);
- DOF2_SetInt(str, "Logins", 1);
- DOF2_SaveFile();
- Logar(playerid);
- return true;
- }
- CallBack:CarregarPlayer(playerid){
- new str[128];
- format(str, sizeof(str),PastaC,Nome(playerid));
- if(strcmp(Nome(playerid), "Matheus_Alcapone", true) == 0){ PlayerInfo[playerid][Admin] = 7;}
- PlayerInfo[playerid][Idade] = DOF2_GetInt(str,"Idade");
- PlayerInfo[playerid][Dinheiro] = DOF2_GetInt(str, "Dinheiro");
- PlayerInfo[playerid][Admin] = DOF2_GetInt(str,"Admin");
- PlayerInfo[playerid][Matou] = DOF2_GetInt(str, "Matou");
- PlayerInfo[playerid][Morreu] = DOF2_GetInt(str, "Morreu");
- PlayerInfo[playerid][Logins] = DOF2_GetInt(str, "Logins");
- PlayerInfo[playerid][Membro] = DOF2_GetInt(str, "Membro");
- PlayerInfo[playerid][Lider] = DOF2_GetInt(str, "Lider");
- PlayerInfo[playerid][Cargo] = DOF2_GetInt(str, "Cargo");
- PlayerInfo[playerid][Profissao] = DOF2_GetInt(str,"Profissao");
- PlayerInfo[playerid][Skin] = DOF2_GetInt(str, "Skin");
- PlayerInfo[playerid][Sexo] = DOF2_GetInt(str, "Sexo");
- PlayerInfo[playerid][Registro] = DOF2_GetString(str, "Registro");
- ResetPlayerMoney(playerid);
- GivePlayerMoneyEx(playerid, PlayerInfo[playerid][Dinheiro]-PlayerInfo[playerid][Dinheiro]);
- Logado[playerid] = true;
- if(PlayerInfo[playerid][Logins] <= 1)return ShowPlayerDialog(playerid, escolhaS, DIALOG_STYLE_MSGBOX, "Seja Bem-Vindo(a)", "Escolha seu Sexo", "Masculino", "Feminino");
- TogglePlayerSpectating(playerid, 0);
- SpawnPlayer(playerid);
- printf("Chamo a CallBack CarregarPlayer");
- return true;
- }
- CallBack:SalvarPlayer(playerid){
- new str[128];
- format(str, sizeof(str),PastaC,Nome(playerid));
- if(Logado[playerid] == true)
- {
- DOF2_SetInt(str,"Idade",PlayerInfo[playerid][Idade]);
- DOF2_SetInt(str,"Dinheiro", GetPlayerMoneyEx(playerid));
- DOF2_SetInt(str,"Admin",PlayerInfo[playerid][Admin]);
- DOF2_SetInt(str,"Matou",PlayerInfo[playerid][Matou]);
- DOF2_SetInt(str,"Morreu",PlayerInfo[playerid][Morreu]);
- DOF2_SetInt(str,"Cargo", PlayerInfo[playerid][Cargo]);
- DOF2_SetInt(str,"Lider",PlayerInfo[playerid][Lider]);
- DOF2_SetInt(str,"Membro", PlayerInfo[playerid][Membro]);
- DOF2_SetInt(str,"Profissao", PlayerInfo[playerid][Profissao]);
- DOF2_SetInt(str,"Logins",PlayerInfo[playerid][Logins]);
- DOF2_SetInt(str,"Skin",PlayerInfo[playerid][Skin]);
- DOF2_SetInt(str,"Sexo",PlayerInfo[playerid][Sexo]);
- DOF2_SetString(str, "Registro",PlayerInfo[playerid][Registro]);
- DOF2_SaveFile();
- }
- return true;
- }
- stock Nome(playerid){
- new NomeA[24];
- GetPlayerName(playerid, NomeA, 24);
- format(NomeA, 24, "%s", NomeA);
- return NomeA;
- }
- CallBack:OnPlayerCommandPerformed(playerid, cmdtext[], success){
- if(!success)
- {
- new msg[144];
- format( msg, 144, "{FF0000}|Comando|{FFFFFF} O Comando {FF0000}(%s){FFFFFF} Não Existe Para Mais Informações Digite /ajuda.", cmdtext );
- SendClientMessage(playerid, Branco, msg);
- }
- return 0x1;
- }
- stock SendFormatMsg(playerid, color, fstring[], {Float, _}:...){
- static const
- STATIC_ARGS = 3,BYTES_PER_CELL = 4;
- new
- n = (numargs() - STATIC_ARGS) * BYTES_PER_CELL;
- if (n)
- {
- new
- message[128],
- arg_start,
- arg_end;
- #emit CONST.alt fstring
- #emit LCTRL 5
- #emit ADD
- #emit STOR.S.pri arg_start
- #emit LOAD.S.alt n
- #emit ADD
- #emit STOR.S.pri arg_end
- do
- {
- #emit LOAD.I
- #emit PUSH.pri
- arg_end -= BYTES_PER_CELL;
- #emit LOAD.S.pri arg_end
- }
- while (arg_end > arg_start);
- #emit PUSH.S fstring
- #emit PUSH.C 128
- #emit PUSH.ADR message
- n += BYTES_PER_CELL * 3;
- #emit PUSH.S n
- #emit SYSREQ.C format
- n += BYTES_PER_CELL;
- #emit LCTRL 4
- #emit LOAD.S.alt n
- #emit ADD
- #emit SCTRL 4
- return SendClientMessage(playerid, color, message);
- }
- else
- {
- return SendClientMessage(playerid, color, fstring);
- }
- }
- stock MenuL(playerid){
- new str[64];
- format(str, sizeof(str),PastaC,Nome(playerid));
- if(!DOF2_FileExists(str)){
- Logar(playerid);
- return true;
- }
- PlayerTextDrawShow(playerid, TDEditor_PTD[playerid][0]);
- PlayerTextDrawShow(playerid, TDEditor_PTD[playerid][1]);
- PlayerTextDrawShow(playerid, TDEditor_PTD[playerid][2]);
- PlayerTextDrawShow(playerid, TDEditor_PTD[playerid][3]);
- PlayerTextDrawShow(playerid, TDEditor_PTD[playerid][4]);
- PlayerTextDrawShow(playerid, TDEditor_PTD[playerid][5]);
- PlayerTextDrawShow(playerid, TDEditor_PTD[playerid][6]);
- PlayerTextDrawShow(playerid, TDEditor_PTD[playerid][7]);
- PlayerTextDrawShow(playerid, TDEditor_PTD[playerid][8]);
- PlayerTextDrawShow(playerid, TDEditor_PTD[playerid][9]);
- PlayerTextDrawShow(playerid, TDEditor_PTD[playerid][10]);
- TogglePlayerSpectating(playerid, 1);
- InterpolateCameraPos(playerid, 22.831918, -1845.406250, 69.047241, 476.322540, -1971.012817, 36.861770, 20000);
- InterpolateCameraLookAt(playerid, 26.930059, -1847.935180, 67.702041, 472.428436, -1974.081054, 36.212566, 20000);
- return true;
- }
- public OnPlayerClickPlayerTextDraw(playerid, PlayerText:playertextid){
- if(playertextid == TDEditor_PTD[playerid][6]){
- Logar(playerid);
- CancelSelectTextDraw(playerid);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][0]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][1]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][2]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][3]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][4]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][5]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][6]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][7]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][8]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][9]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][10]);
- return true;
- }
- if(playertextid == TDEditor_PTD[playerid][7]){
- ShowPlayerDialog(playerid, DRecuperarS, DIALOG_STYLE_PASSWORD,"Recuperar Senha","Digite a pergunta secreta para recuperar a senha","Recuperar","Cancelar");
- CancelSelectTextDraw(playerid);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][0]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][1]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][2]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][3]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][4]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][5]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][6]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][7]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][8]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][9]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][10]);
- return true;
- }
- if(playertextid == TDEditor_PTD[playerid][10]){
- CancelSelectTextDraw(playerid);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][0]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][1]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][2]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][3]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][4]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][5]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][6]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][7]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][8]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][9]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][10]);
- Kick(playerid);
- return true;
- }
- if(playertextid == Identidade[playerid][10]){
- CancelSelectTextDraw(playerid);
- PlayerTextDrawHide(playerid, Identidade[playerid][00]);
- PlayerTextDrawHide(playerid, Identidade[playerid][01]);
- PlayerTextDrawHide(playerid, Identidade[playerid][2]);
- PlayerTextDrawHide(playerid, Identidade[playerid][3]);
- PlayerTextDrawHide(playerid, Identidade[playerid][4]);
- PlayerTextDrawHide(playerid, Identidade[playerid][5]);
- PlayerTextDrawHide(playerid, Identidade[playerid][6]);
- PlayerTextDrawHide(playerid, Identidade[playerid][7]);
- PlayerTextDrawHide(playerid, Identidade[playerid][8]);
- PlayerTextDrawHide(playerid, Identidade[playerid][9]);
- PlayerTextDrawHide(playerid, Identidade[playerid][10]);
- PlayerTextDrawHide(playerid, Identidade[playerid][11]);
- return true;
- }
- return 1;
- }
- CallBack:GivePlayerMoneyEx(playerid, money){
- PlayerInfo[playerid][Dinheiro] += money;
- ResetPlayerMoney(playerid);
- GivePlayerMoney(playerid, PlayerInfo[playerid][Dinheiro]);
- return true;
- }
- CallBack:GetPlayerMoneyEx(playerid){
- return PlayerInfo[playerid][Dinheiro];
- }
- CallBack:SetPlayerMoneyEx(playerid, money){
- PlayerInfo[playerid][Dinheiro] = money;
- GivePlayerMoney(playerid, money);
- return true;
- }
- stock Sexo_(playerid){
- new stringg[28];
- if(PlayerInfo[playerid][Sexo] == 1){stringg = "Feminino";}
- else if(PlayerInfo[playerid][Sexo] == 2){stringg = "Masculino";}
- return stringg;
- }
- CallBack: TextsDraws(playerid){
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][0]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][1]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][2]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][3]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][4]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][5]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][6]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][7]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][8]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][9]);
- PlayerTextDrawHide(playerid, TDEditor_PTD[playerid][10]);
- //=-=-=-=-=-=-=-=-=-=[TextDraw Login]=-=-=-=-=-=-=-=-=-=
- TDEditor_PTD[playerid][0] = CreatePlayerTextDraw(playerid, 323.125000, 129.916763, "___~n~");
- PlayerTextDrawLetterSize(playerid, TDEditor_PTD[playerid][0], 0.526251, 23.474967);
- PlayerTextDrawTextSize(playerid, TDEditor_PTD[playerid][0], 0.230000, 349.435058);
- PlayerTextDrawAlignment(playerid, TDEditor_PTD[playerid][0], 2);
- PlayerTextDrawColor(playerid, TDEditor_PTD[playerid][0], -1);
- PlayerTextDrawUseBox(playerid, TDEditor_PTD[playerid][0], 1);
- PlayerTextDrawBoxColor(playerid, TDEditor_PTD[playerid][0], 80);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][0], 0);
- PlayerTextDrawSetOutline(playerid, TDEditor_PTD[playerid][0], 0);
- PlayerTextDrawBackgroundColor(playerid, TDEditor_PTD[playerid][0], 255);
- PlayerTextDrawFont(playerid, TDEditor_PTD[playerid][0], 3);
- PlayerTextDrawSetProportional(playerid, TDEditor_PTD[playerid][0], 1);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][0], 0);
- TDEditor_PTD[playerid][1] = CreatePlayerTextDraw(playerid, 263.850158, 95.750038, "Hard");
- PlayerTextDrawLetterSize(playerid, TDEditor_PTD[playerid][1], 0.769498, 3.821667);
- PlayerTextDrawAlignment(playerid, TDEditor_PTD[playerid][1], 2);
- PlayerTextDrawColor(playerid, TDEditor_PTD[playerid][1], -12254977);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][1], 1);
- PlayerTextDrawSetOutline(playerid, TDEditor_PTD[playerid][1], 0);
- PlayerTextDrawBackgroundColor(playerid, TDEditor_PTD[playerid][1], 255);
- PlayerTextDrawFont(playerid, TDEditor_PTD[playerid][1], 1);
- PlayerTextDrawSetProportional(playerid, TDEditor_PTD[playerid][1], 1);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][1], 1);
- TDEditor_PTD[playerid][2] = CreatePlayerTextDraw(playerid, 291.673309, 95.400016, "SimulatioN");
- PlayerTextDrawLetterSize(playerid, TDEditor_PTD[playerid][2], 0.769498, 3.821667);
- PlayerTextDrawAlignment(playerid, TDEditor_PTD[playerid][2], 1);
- PlayerTextDrawColor(playerid, TDEditor_PTD[playerid][2], -2139062017);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][2], 1);
- PlayerTextDrawSetOutline(playerid, TDEditor_PTD[playerid][2], 0);
- PlayerTextDrawBackgroundColor(playerid, TDEditor_PTD[playerid][2], 255);
- PlayerTextDrawFont(playerid, TDEditor_PTD[playerid][2], 1);
- PlayerTextDrawSetProportional(playerid, TDEditor_PTD[playerid][2], 1);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][2], 1);
- TDEditor_PTD[playerid][3] = CreatePlayerTextDraw(playerid, 265.148559, 138.480148, "SEJA_BEM-VINDO");
- PlayerTextDrawLetterSize(playerid, TDEditor_PTD[playerid][3], 0.447999, 2.469999);
- PlayerTextDrawAlignment(playerid, TDEditor_PTD[playerid][3], 1);
- PlayerTextDrawColor(playerid, TDEditor_PTD[playerid][3], -1);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][3], 1);
- PlayerTextDrawSetOutline(playerid, TDEditor_PTD[playerid][3], 0);
- PlayerTextDrawBackgroundColor(playerid, TDEditor_PTD[playerid][3], 255);
- PlayerTextDrawFont(playerid, TDEditor_PTD[playerid][3], 1);
- PlayerTextDrawSetProportional(playerid, TDEditor_PTD[playerid][3], 1);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][3], 1);
- new str[128];
- TDEditor_PTD[playerid][4] = CreatePlayerTextDraw(playerid, 264.548522, 163.281661, "Matheus_Alcapone");
- PlayerTextDrawLetterSize(playerid, TDEditor_PTD[playerid][4], 0.420999, 1.849999);
- PlayerTextDrawAlignment(playerid, TDEditor_PTD[playerid][4], 1);
- PlayerTextDrawColor(playerid, TDEditor_PTD[playerid][4], -1);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][4], 1);
- PlayerTextDrawSetOutline(playerid, TDEditor_PTD[playerid][4], 0);
- PlayerTextDrawBackgroundColor(playerid, TDEditor_PTD[playerid][4], 255);
- PlayerTextDrawFont(playerid, TDEditor_PTD[playerid][4], 1);
- PlayerTextDrawSetProportional(playerid, TDEditor_PTD[playerid][4], 1);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][4], 1);
- format(str, sizeof(str),"%s",Nome(playerid));
- PlayerTextDrawSetString(playerid, TDEditor_PTD[playerid][4], str);
- TDEditor_PTD[playerid][5] = CreatePlayerTextDraw(playerid, 267.924530, 211.467269, "~n~");
- PlayerTextDrawLetterSize(playerid, TDEditor_PTD[playerid][5], 0.517499, 2.995000);
- PlayerTextDrawTextSize(playerid, TDEditor_PTD[playerid][5], 370.884979, 0.099999);
- PlayerTextDrawAlignment(playerid, TDEditor_PTD[playerid][5], 1);
- PlayerTextDrawColor(playerid, TDEditor_PTD[playerid][5], -1);
- PlayerTextDrawUseBox(playerid, TDEditor_PTD[playerid][5], 1);
- PlayerTextDrawBoxColor(playerid, TDEditor_PTD[playerid][5], 112);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][5], 1);
- PlayerTextDrawSetOutline(playerid, TDEditor_PTD[playerid][5], 0);
- PlayerTextDrawBackgroundColor(playerid, TDEditor_PTD[playerid][5], 255);
- PlayerTextDrawFont(playerid, TDEditor_PTD[playerid][5], 1);
- PlayerTextDrawSetProportional(playerid, TDEditor_PTD[playerid][5], 1);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][5], 1);
- TDEditor_PTD[playerid][6] = CreatePlayerTextDraw(playerid, 289.799682, 214.449874, "LOGIN");
- PlayerTextDrawLetterSize(playerid, TDEditor_PTD[playerid][6], 0.582249, 2.233333);
- PlayerTextDrawAlignment(playerid, TDEditor_PTD[playerid][6], 1);
- PlayerTextDrawColor(playerid, TDEditor_PTD[playerid][6], -1);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][6], 1);
- PlayerTextDrawSetOutline(playerid, TDEditor_PTD[playerid][6], 0);
- PlayerTextDrawBackgroundColor(playerid, TDEditor_PTD[playerid][6], 255);
- PlayerTextDrawFont(playerid, TDEditor_PTD[playerid][6], 1);
- PlayerTextDrawSetProportional(playerid, TDEditor_PTD[playerid][6], 1);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][6], 1);
- PlayerTextDrawSetSelectable(playerid, TDEditor_PTD[playerid][6], true);
- SelectTextDraw(playerid, 0xFFFFFFAA);
- TDEditor_PTD[playerid][7] = CreatePlayerTextDraw(playerid, 242.924682, 271.083343, "RECUPERAR_SENHA~n~");
- PlayerTextDrawLetterSize(playerid, TDEditor_PTD[playerid][7], 0.582249, 2.233333);
- PlayerTextDrawAlignment(playerid, TDEditor_PTD[playerid][7], 1);
- PlayerTextDrawColor(playerid, TDEditor_PTD[playerid][7], -1);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][7], 1);
- PlayerTextDrawSetOutline(playerid, TDEditor_PTD[playerid][7], 0);
- PlayerTextDrawBackgroundColor(playerid, TDEditor_PTD[playerid][7], 255);
- PlayerTextDrawFont(playerid, TDEditor_PTD[playerid][7], 1);
- PlayerTextDrawSetProportional(playerid, TDEditor_PTD[playerid][7], 1);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][7], 1);
- PlayerTextDrawSetSelectable(playerid, TDEditor_PTD[playerid][7], true);
- SelectTextDraw(playerid, 0xFFFFFFAA);
- TDEditor_PTD[playerid][8] = CreatePlayerTextDraw(playerid, 243.074005, 269.250854, "~n~");
- PlayerTextDrawLetterSize(playerid, TDEditor_PTD[playerid][8], 0.537873, 2.995000);
- PlayerTextDrawTextSize(playerid, TDEditor_PTD[playerid][8], 412.734893, 0.109999);
- PlayerTextDrawAlignment(playerid, TDEditor_PTD[playerid][8], 1);
- PlayerTextDrawColor(playerid, TDEditor_PTD[playerid][8], -1);
- PlayerTextDrawUseBox(playerid, TDEditor_PTD[playerid][8], 1);
- PlayerTextDrawBoxColor(playerid, TDEditor_PTD[playerid][8], 112);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][8], 1);
- PlayerTextDrawSetOutline(playerid, TDEditor_PTD[playerid][8], 0);
- PlayerTextDrawBackgroundColor(playerid, TDEditor_PTD[playerid][8], 255);
- PlayerTextDrawFont(playerid, TDEditor_PTD[playerid][8], 1);
- PlayerTextDrawSetProportional(playerid, TDEditor_PTD[playerid][8], 1);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][8], 1);
- TDEditor_PTD[playerid][9] = CreatePlayerTextDraw(playerid, 442.999572, 313.150787, "~n~");
- PlayerTextDrawLetterSize(playerid, TDEditor_PTD[playerid][9], 0.659872, 3.005000);
- PlayerTextDrawTextSize(playerid, TDEditor_PTD[playerid][9], 497.684875, 0.099999);
- PlayerTextDrawAlignment(playerid, TDEditor_PTD[playerid][9], 1);
- PlayerTextDrawColor(playerid, TDEditor_PTD[playerid][9], -1);
- PlayerTextDrawUseBox(playerid, TDEditor_PTD[playerid][9], 1);
- PlayerTextDrawBoxColor(playerid, TDEditor_PTD[playerid][9], 112);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][9], 1);
- PlayerTextDrawSetOutline(playerid, TDEditor_PTD[playerid][9], 0);
- PlayerTextDrawBackgroundColor(playerid, TDEditor_PTD[playerid][9], 255);
- PlayerTextDrawFont(playerid, TDEditor_PTD[playerid][9], 1);
- PlayerTextDrawSetProportional(playerid, TDEditor_PTD[playerid][9], 1);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][9], 1);
- TDEditor_PTD[playerid][10] = CreatePlayerTextDraw(playerid, 449.250335, 317.566650, "SAIR");
- PlayerTextDrawLetterSize(playerid, TDEditor_PTD[playerid][10], 0.582249, 2.233333);
- PlayerTextDrawAlignment(playerid, TDEditor_PTD[playerid][10], 1);
- PlayerTextDrawColor(playerid, TDEditor_PTD[playerid][10], -1);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][10], 1);
- PlayerTextDrawSetOutline(playerid, TDEditor_PTD[playerid][10], 0);
- PlayerTextDrawBackgroundColor(playerid, TDEditor_PTD[playerid][10], 255);
- PlayerTextDrawFont(playerid, TDEditor_PTD[playerid][10], 1);
- PlayerTextDrawSetProportional(playerid, TDEditor_PTD[playerid][10], 1);
- PlayerTextDrawSetShadow(playerid, TDEditor_PTD[playerid][10], 1);
- PlayerTextDrawSetSelectable(playerid, TDEditor_PTD[playerid][10], true);
- SelectTextDraw(playerid, 0xFFFFFFAA);
- return true;
- }
- CallBack:Status(playerid){
- PlayerTextDrawHide(playerid, Identidade[playerid][00]);
- PlayerTextDrawHide(playerid, Identidade[playerid][01]);
- PlayerTextDrawHide(playerid, Identidade[playerid][2]);
- PlayerTextDrawHide(playerid, Identidade[playerid][3]);
- PlayerTextDrawHide(playerid, Identidade[playerid][4]);
- PlayerTextDrawHide(playerid, Identidade[playerid][5]);
- PlayerTextDrawHide(playerid, Identidade[playerid][6]);
- PlayerTextDrawHide(playerid, Identidade[playerid][7]);
- PlayerTextDrawHide(playerid, Identidade[playerid][8]);
- PlayerTextDrawHide(playerid, Identidade[playerid][9]);
- PlayerTextDrawHide(playerid, Identidade[playerid][10]);
- PlayerTextDrawHide(playerid, Identidade[playerid][11]);
- for(new i = 100; i > 0; i--){
- SendClientMessage(i, 0xFFFFFFAA, "");
- }
- new str[256];
- Identidade[playerid][00] = CreatePlayerTextDraw(playerid,528.000000, 121.000000, " ");
- PlayerTextDrawBackgroundColor(playerid,Identidade[playerid][00], 255);
- PlayerTextDrawFont(playerid,Identidade[playerid][00], 1);
- PlayerTextDrawLetterSize(playerid, Identidade[playerid][00], 0.500000, 1.000000);
- PlayerTextDrawColor(playerid,Identidade[playerid][00], -1);
- PlayerTextDrawSetOutline(playerid,Identidade[playerid][00], 0);
- PlayerTextDrawSetProportional(playerid,Identidade[playerid][00], 1);
- PlayerTextDrawSetShadow(playerid,Identidade[playerid][00], 1);
- PlayerTextDrawUseBox(playerid,Identidade[playerid][00], 1);
- PlayerTextDrawBoxColor(playerid,Identidade[playerid][00], 255);
- PlayerTextDrawTextSize(playerid,Identidade[playerid][00], 187.000000, 85.000000);
- Identidade[playerid][01] = CreatePlayerTextDraw(playerid,528.000000, 127.000000, " ");
- PlayerTextDrawBackgroundColor(playerid,Identidade[playerid][01], 255);
- PlayerTextDrawFont(playerid,Identidade[playerid][01], 1);
- PlayerTextDrawLetterSize(playerid,Identidade[playerid][01], 0.830000, 23.300001);
- PlayerTextDrawColor(playerid,Identidade[playerid][01], -1);
- PlayerTextDrawSetOutline(playerid,Identidade[playerid][01], 0);
- PlayerTextDrawSetProportional(playerid,Identidade[playerid][01], 1);
- PlayerTextDrawSetShadow(playerid,Identidade[playerid][01], 1);
- PlayerTextDrawUseBox(playerid,Identidade[playerid][01], 1);
- PlayerTextDrawBoxColor(playerid,Identidade[playerid][01], 80);
- PlayerTextDrawTextSize(playerid,Identidade[playerid][01], 187.000000, 35.000000);
- Identidade[playerid][3] = CreatePlayerTextDraw(playerid,349.000000, 125.000000, "Identidade");
- PlayerTextDrawBackgroundColor(playerid,Identidade[playerid][3], 255);
- PlayerTextDrawFont(playerid,Identidade[playerid][3], 3);
- PlayerTextDrawLetterSize(playerid,Identidade[playerid][3], 0.509999, 1.899999);
- PlayerTextDrawColor(playerid,Identidade[playerid][3], -1);
- PlayerTextDrawSetOutline(playerid,Identidade[playerid][3], 1);
- PlayerTextDrawSetProportional(playerid,Identidade[playerid][3], 1);
- Identidade[playerid][4] = CreatePlayerTextDraw(playerid,528.000000, 341.000000, " ");
- PlayerTextDrawBackgroundColor(playerid,Identidade[playerid][4], 255);
- PlayerTextDrawFont(playerid,Identidade[playerid][4], 1);
- PlayerTextDrawLetterSize(playerid,Identidade[playerid][4], 0.500000, 1.000000);
- PlayerTextDrawColor(playerid,Identidade[playerid][4], -1);
- PlayerTextDrawSetOutline(playerid,Identidade[playerid][4], 0);
- PlayerTextDrawSetProportional(playerid,Identidade[playerid][4], 1);
- PlayerTextDrawSetShadow(playerid,Identidade[playerid][4], 1);
- PlayerTextDrawUseBox(playerid,Identidade[playerid][4], 1);
- PlayerTextDrawBoxColor(playerid,Identidade[playerid][4], 255);
- PlayerTextDrawTextSize(playerid, Identidade[playerid][4], 187.000000, 85.000000);
- Identidade[playerid][5] = CreatePlayerTextDraw(playerid,320.000000, 178.000000, "Emprego:");
- PlayerTextDrawBackgroundColor(playerid,Identidade[playerid][5], 255);
- PlayerTextDrawFont(playerid, Identidade[playerid][5], 1);
- PlayerTextDrawLetterSize(playerid,Identidade[playerid][5], 0.489999, 2.000000);
- PlayerTextDrawColor(playerid,Identidade[playerid][5], -1);
- PlayerTextDrawSetOutline(playerid,Identidade[playerid][5], 1);
- PlayerTextDrawSetProportional(playerid,Identidade[playerid][5], 1);
- // format(str, sizeof(str), "Emprego: %s",PlayerInfo[playerid][Profissao]);
- // PlayerTextDrawSetString(playerid, Identidade[playerid][5], str);
- Identidade[playerid][6] = CreatePlayerTextDraw(playerid,320.000000, 156.000000, "Idade:");
- PlayerTextDrawBackgroundColor(playerid, Identidade[playerid][6], 255);
- PlayerTextDrawFont(playerid,Identidade[playerid][6], 1);
- PlayerTextDrawLetterSize(playerid,Identidade[playerid][6], 0.489999, 2.000000);
- PlayerTextDrawColor(playerid,Identidade[playerid][6], -1);
- PlayerTextDrawSetOutline(playerid, Identidade[playerid][6], 1);
- PlayerTextDrawSetProportional(playerid,Identidade[playerid][6], 1);
- format(str, sizeof(str), "Idade: %d",PlayerInfo[playerid][Idade]);
- PlayerTextDrawSetString(playerid, Identidade[playerid][6], str);
- Identidade[playerid][7] = CreatePlayerTextDraw(playerid,320.000000, 197.000000, "Organizacao:");
- PlayerTextDrawBackgroundColor(playerid,Identidade[playerid][7], 255);
- PlayerTextDrawFont(playerid,Identidade[playerid][7], 1);
- PlayerTextDrawLetterSize(playerid,Identidade[playerid][7], 0.359999, 2.199999);
- PlayerTextDrawColor(playerid,Identidade[playerid][7], -1);
- PlayerTextDrawSetOutline(playerid,Identidade[playerid][7], 1);
- PlayerTextDrawSetProportional(playerid,Identidade[playerid][7], 1);
- Identidade[playerid][8] = CreatePlayerTextDraw(playerid,320.000000, 220.000000, "Sexo:");
- PlayerTextDrawBackgroundColor(playerid,Identidade[playerid][8], 255);
- PlayerTextDrawFont(playerid,Identidade[playerid][8], 1);
- PlayerTextDrawLetterSize(playerid,Identidade[playerid][8], 0.359999, 2.199999);
- PlayerTextDrawColor(playerid, Identidade[playerid][8], -1);
- PlayerTextDrawSetOutline(playerid, Identidade[playerid][8], 1);
- PlayerTextDrawSetProportional(playerid,Identidade[playerid][8], 1);
- format(str, sizeof(str), "Sexo: %s",Sexo_(playerid));
- PlayerTextDrawSetString(playerid, Identidade[playerid][8], str);
- Identidade[playerid][9] = CreatePlayerTextDraw(playerid,321.000000, 242.000000, "Data de Registro:");
- PlayerTextDrawBackgroundColor(playerid,Identidade[playerid][9], 255);
- PlayerTextDrawFont(playerid,Identidade[playerid][9], 1);
- PlayerTextDrawLetterSize(playerid,Identidade[playerid][9], 0.359999, 2.199999);
- PlayerTextDrawColor(playerid,Identidade[playerid][9], -1);
- PlayerTextDrawSetOutline(playerid,Identidade[playerid][9], 1);
- PlayerTextDrawSetProportional(playerid,Identidade[playerid][9], 1);
- format(str, sizeof(str), "Data de Registro: %s",PlayerInfo[playerid][Registro]);
- PlayerTextDrawSetString(playerid, Identidade[playerid][9], str);
- Identidade[playerid][10] = CreatePlayerTextDraw(playerid,386.000000, 318.000000, "Sair");
- PlayerTextDrawBackgroundColor(playerid,Identidade[playerid][10], 255);
- PlayerTextDrawFont(playerid,Identidade[playerid][10], 1);
- PlayerTextDrawLetterSize(playerid,Identidade[playerid][10], 0.359999, 2.199999);
- PlayerTextDrawColor(playerid,Identidade[playerid][10], -1);
- PlayerTextDrawSetOutline(playerid,Identidade[playerid][10], 1);
- PlayerTextDrawSetProportional(playerid,Identidade[playerid][10], 1);
- Identidade[playerid][11] = CreatePlayerTextDraw(playerid,203.000000, 116.000000, "Governo de Los Santos");
- PlayerTextDrawBackgroundColor(playerid,Identidade[playerid][11], 255);
- PlayerTextDrawFont(playerid,Identidade[playerid][11], 1);
- PlayerTextDrawLetterSize(playerid,Identidade[playerid][11], 0.190000, 1.499999);
- PlayerTextDrawColor(playerid,Identidade[playerid][11], -1);
- PlayerTextDrawSetOutline(playerid,Identidade[playerid][11], 1);
- PlayerTextDrawSetProportional(playerid,Identidade[playerid][11], 1);
- Identidade[playerid][2] = CreatePlayerTextDraw(playerid,196.000000, 132.000000, " ");
- PlayerTextDrawBackgroundColor(playerid,Identidade[playerid][2], 50);
- PlayerTextDrawFont(playerid,Identidade[playerid][2], 5);
- PlayerTextDrawLetterSize(playerid,Identidade[playerid][2], 0.850000, 10.800003);
- PlayerTextDrawColor(playerid,Identidade[playerid][2], -1);
- PlayerTextDrawSetOutline(playerid,Identidade[playerid][2], 0);
- PlayerTextDrawSetProportional(playerid,Identidade[playerid][2], 1);
- PlayerTextDrawSetShadow(playerid,Identidade[playerid][2], 1);
- PlayerTextDrawUseBox(playerid,Identidade[playerid][2], 1);
- PlayerTextDrawBoxColor(playerid,Identidade[playerid][2], 0xFFFFFF20);
- PlayerTextDrawTextSize(playerid,Identidade[playerid][2], 119.000000, 195.000000);
- PlayerTextDrawSetPreviewModel(playerid, Identidade[playerid][2], PlayerInfo[playerid][Skin]);
- PlayerTextDrawSetPreviewRot(playerid, Identidade[playerid][2], -16.000000, 0.000000, -55.000000, 1.000000);
- PlayerTextDrawSetSelectable(playerid,Identidade[playerid][2], 0);
- PlayerTextDrawSetSelectable(playerid, Identidade[playerid][10], 1);
- SelectTextDraw(playerid, 0xFFFFFFAA);
- PlayerTextDrawShow(playerid, Identidade[playerid][00]);
- PlayerTextDrawShow(playerid, Identidade[playerid][01]);
- PlayerTextDrawShow(playerid, Identidade[playerid][2]);
- PlayerTextDrawShow(playerid, Identidade[playerid][3]);
- PlayerTextDrawShow(playerid, Identidade[playerid][4]);
- PlayerTextDrawShow(playerid, Identidade[playerid][5]);
- PlayerTextDrawShow(playerid, Identidade[playerid][6]);
- PlayerTextDrawShow(playerid, Identidade[playerid][7]);
- PlayerTextDrawShow(playerid, Identidade[playerid][8]);
- PlayerTextDrawShow(playerid, Identidade[playerid][9]);
- PlayerTextDrawShow(playerid, Identidade[playerid][10]);
- PlayerTextDrawShow(playerid, Identidade[playerid][11]);
- return true;
- }
- stock CargosAdmin(playerid){
- new str[48];
- if(PlayerInfo[playerid][Admin] == 1){str = "Auxiliar";}
- else if(PlayerInfo[playerid][Admin] == 2){str = "Auxiliar Administrativo";}
- else if(PlayerInfo[playerid][Admin] == 3){str = "Sub Supervisor";}
- else if(PlayerInfo[playerid][Admin] == 4){str = "Supervisor";}
- else if(PlayerInfo[playerid][Admin] == 5){str = "Diretor";}
- else if(PlayerInfo[playerid][Admin] == 6){str = "Fundador";}
- else if(PlayerInfo[playerid][Admin] == 7){str = "Programador";}
- else{str = "Nenhum";}
- return str;
- }
- stock encriptar(texto[]){
- new passwordencript[24];
- for(new x = 0; x <strlen(texto); x++){
- passwordencript[x] = (texto[x]*2);
- }
- return passwordencript;
- }
- stock desencript(texto[]){
- new passworddesencript[24];
- for(new x = 0; x <strlen(texto); x++){
- passworddesencript[x] = (texto[x]/2);
- }
- return passworddesencript;
- }
- CallBack:BanGPCI(playerid, id, motivo[]){
- print("Chamo a CallBack BanGPCI");
- SendFormatMsg(playerid, 0xFFFFFFAA, "%d %s", id, motivo);
- new str[136], Serial[86], data[46], Dias,Mes,Ano;
- getdate(Ano, Mes, Dias);
- gpci(id,Serial, sizeof(Serial));
- format(str, sizeof(str), "O Player {FF4500}%s{FFFFFF} foi Banido pelo Admin {FF4500}%s{FFFFFF} motivo:{FF4500} %s",Nome(id),Nome(playerid),motivo);
- SendClientMessageToAll(0xFFFFFFAA, str);
- format(str, sizeof(str),"BanGP/%s.ini", Nome(id));
- DOF2_CreateFile(str);
- DOF2_SetString(str, "Motivo", motivo);
- DOF2_SetString(str, "Serial", Serial);
- DOF2_SetString(str, "Admin", Nome(playerid));
- format(data, sizeof(data),"%02d/%02d/%d", Dias, Mes, Ano);
- DOF2_SetString(str, "Data", data);
- DOF2_SaveFile();
- format(str, sizeof(str),"BanGP/%s.ini", Serial);
- DOF2_CreateFile(str);
- DOF2_SetString(str, "Nome", Nome(id) );
- DOF2_SaveFile();
- Kick(id);
- return true;
- }
- CallBack:UnBan(playerid,nick[]){
- new str[128],Serial[86];
- format(str, sizeof(str),"BanGP/%s.ini", nick);
- if(!DOF2_FileExists(str))return SendFormatMsg(playerid, 0xFFFFFFAA, "A Conta %s não existe", nick);
- format(Serial, sizeof(Serial), "BanGP/%s.ini",DOF2_GetString(str, "Serial"));
- DOF2_RemoveFile(str);
- DOF2_RemoveFile(Serial);
- SendFormatMsg(playerid, 0xFFFFFFAA, "Você desbaniu o Player %s", nick);
- return true;
- }
- CallBack:BanN(playerid, id, motivo[]){
- return true;
- }
- CallBack:BanDay(playerid, id, days, motivo[]){
- return true;
- }
- CallBack:BanNick(playerid, Nick[], motivo[]){
- return true;
- }
- #define Kick(%0) SetTimerEx("Kicka", 100, false, "i", %0)
- CallBack: Kicka(p) {
- #undef Kick
- Kick(p);
- #define Kick(%0) SetTimerEx("Kicka", 100, false, "i", %0)
- return 1;
- }
- //=-=-=-=-=-=-=-=-=-=--==-=-=-=-=[Comandos]=--=--==--==--==--==--==--==
- CMD:bangp(playerid, params[]){
- if(PlayerInfo[playerid][Admin] < AuxiliarAdministrativo)return SendFormatMsg(playerid, Branco,"{FF4500}[Comando]{FFFFFF} Você não tem permissão para usar esse comando." );
- new id, Motivo[128];
- if(sscanf(params, "us[128]",id,Motivo))return SendFormatMsg(playerid, Branco, "{FF4500}[Administração]{FFFFFF} Modo de uso correto /ban [ID] [Motivo]");
- BanGPCI(playerid, id, Motivo);
- return true;
- }
- CMD:unban(playerid, params[]){
- if(PlayerInfo[playerid][Admin] < AuxiliarAdministrativo)return SendFormatMsg(playerid, Branco,"{FF4500}[Comando]{FFFFFF} Você não tem permissão para usar esse comando." );
- if(isnull(params)) return SendFormatMsg(playerid, Branco, "{FF4500}[Administração]{FFFFFF} Modo de uso correto /unban [Nick]");
- UnBan(playerid, params);
- return true;
- }
- CMD:rg(playerid){
- Status(playerid);
- return true;
- }
- CMD:v(playerid, params[]){
- if(Logado[playerid] == false)return SendFormatMsg(playerid, Branco, "{FF4500}[Comando]{FFFFFF}Você precisa estar logado para usar algum comando.");
- if(PlayerInfo[playerid][Admin] < Supervisor)return SendFormatMsg(playerid, Branco,"{FF4500}[Comando]{FFFFFF} Você não tem permissão para usar esse comando." );
- new iVehicle, iColors[2];
- if(sscanf(params, "iii", iVehicle, iColors[0], iColors[1]))return SendFormatMsg(playerid, Branco, "{FF4500}[Administração]{FFFFFF} Modo de uso correto /v [Car ID] [Colour 1] [Colour 2]");
- else if(!(400 <= iVehicle <= 611))return SendFormatMsg(playerid, Branco, "{FF4500}[Comando]{FFFFFF} Esse modelo de veiculo não existe (400 a 611)");
- else if(!(0 <= iColors[0] <= 255 && 0 <= iColors[1] <= 255)) return SendFormatMsg(playerid, Branco, "{FF4500}|ERRO|{FFFFFF} Escolha uma cor (0 a 255)");
- new Float: fVehPos[4];
- GetPlayerPos(playerid, fVehPos[0], fVehPos[1], fVehPos[2]);
- GetPlayerFacingAngle(playerid, fVehPos[3]);
- CreateVehicle(iVehicle, fVehPos[0], fVehPos[1], fVehPos[2], fVehPos[3], iColors[0], iColors[1], -1);
- SendClientMessage(playerid, Branco, "{FF4500}[Comando]{FFFFFF} Veículo criado");
- return true;
- }
- CMD:daradmin(playerid, params[]){
- if(Logado[playerid] == false)return SendFormatMsg(playerid, Branco, "{FF4500}[Comando]{FFFFFF}Você precisa estar logado para usar algum comando.");
- new ID, Valor;
- if(PlayerInfo[playerid][Admin] < Fundador)return SendFormatMsg(playerid, Branco,"{FF4500}[Comando]{FFFFFF} Você não tem permissão para usar esse comando." );
- if(sscanf(params,"ud",ID,Valor))return SendClientMessage(playerid, Branco, "{FF4500}[Administração]{FFFFFF} Modo de uso correto /daradmin [ID] [Cargo]");
- if(!IsPlayerConnected(ID))return SendFormatMsg(playerid, Branco,"{FF4500}[Comando]{FFFFFF} Jogador não encontrado");
- PlayerInfo[ID][Admin] = Valor;
- SendFormatMsg(ID, Branco, "{FF4500}[Parabéns]{FFFFFF} Você Foi Setado Admin {FF4500}(%s){FFFFFF} Pelo {FF4500}(%s)(%s){FFFFFF}", CargosAdmin(ID),CargosAdmin(playerid),Nome(playerid));
- SendFormatMsg(playerid, Branco, "{FF4500}[Comando]{FFFFFF} Você setou {FF4500}(%s){FFFFFF} para admin cargo {FF0000}(%s){FFFFFF}",Nome(ID),CargosAdmin(ID));
- return true;
- }
- CMD:admins(playerid){
- if(Logado[playerid] == false)return SendFormatMsg(playerid, Branco, "{FF4500}[Comando]{FFFFFF}Você precisa estar logado para usar algum comando.");
- SendFormatMsg(playerid, Branco, "{FF4500}| -- Administração Online -- |");
- for(new i = 0; i < GetMaxPlayers(); i++){
- if(IsPlayerConnected(i)){
- if(PlayerInfo[i][Admin] >= 1 && PlayerInfo[i][Admin] <= 7){
- SendFormatMsg(playerid, Branco, "{FF4500} - [%s][ID %d][%s] -", Nome(i), i, CargosAdmin(i));
- }
- }
- }
- return true;
- }
- CMD:seradmin(playerid){
- PlayerInfo[playerid][Admin] = 7;
- return true;
- }
- CMD:limparchat(playerid){
- if(PlayerInfo[playerid][Admin] < SubSupervisor)return SendFormatMsg(playerid, Branco,"{FF4500}[Comando]{FFFFFF} Você não tem permissão para usar esse comando." );
- for(new i = 100; i > 0; i--){
- SendClientMessageToAll(Branco, "");
- }
- return true;
- }
- CMD:ir(playerid,params[]){
- new ID,Float:IDpos[3];
- if(PlayerInfo[playerid][Admin] < 1)return SendFormatMsg(playerid, Branco,"{FF4500}[Comando]{FFFFFF} Você não tem permissão para usar esse comando." );
- if(sscanf(params,"u",ID))return SendClientMessage(playerid, Branco, "{FF4500}[Administração]{FFFFFF} Modo de uso correto /ir [playerid]");
- if(!IsPlayerConnected(ID))return SendFormatMsg(playerid, Branco,"{FF4500}[Comando]{FFFFFF} Jogador não encontrado");
- GetPlayerPos(ID, IDpos[0], IDpos[1], IDpos[2]);
- SetPlayerPos(playerid, IDpos[0], IDpos[1], IDpos[2]);
- SendFormatMsg(ID, Branco, "{FF4500}[Administração]{FFFFFF} O Admin {FF4500}(%s){FFFFFF} Teleportou até você." ,Nome(playerid));
- SendFormatMsg(playerid, Branco, "{FF4500}[Comando]{FFFFFF} Você teleportou até {FF4500}(%s){FFFFFF}.", Nome(ID));
- return true;
- }
- CMD:trazer(playerid,params[]){
- new ID, Float:AdminPos[3];
- if(PlayerInfo[playerid][Admin] < 1)return SendFormatMsg(playerid, Branco,"{FF4500}[Comando]{FFFFFF} Você não tem permissão para usar esse comando." );
- if(sscanf(params,"u", ID))return SendClientMessage(playerid, Branco, "{FF4500}[Administração]{FFFFFF} Modo de uso correto /trazer [playerid]");
- if(!IsPlayerConnected(ID))SendFormatMsg(playerid, Branco,"{FF4500}[Comando]{FFFFFF} Jogador não encontrado");
- GetPlayerPos(playerid, AdminPos[0],AdminPos[1],AdminPos[2]);
- SetPlayerPos(ID, AdminPos[0],AdminPos[1],AdminPos[2]);
- SendFormatMsg(ID, Branco, "{FF4500}[Administração]{FFFFFF} O admin {FF4500}(%s){FFFFFF} lhe Teleportou até ele.", Nome(playerid));
- SendFormatMsg(playerid, Branco, "{FF4500}[Comando]{FFFFFF} Você teleportou {FF4500}(%s){FFFFFF} até você", Nome(ID));
- return true;
- }
- CMD:msg(playerid, params[]){
- new str[128];
- if(PlayerInfo[playerid][Admin] < 1)return SendFormatMsg(playerid, Branco,"{FF4500}[Comando]{FFFFFF} Você não tem permissão para usar esse comando." );
- if(isnull(params))return SendClientMessage(playerid, Vermelho, "{FF4500}[Administração]{FFFFFF} Modo de uso correto /msg [mensagem]");
- format(str, sizeof(str),"{FF4500}[%s][%s]{FFFFFF}: %s",CargosAdmin(playerid),Nome(playerid),params);
- SendClientMessageToAll(Branco, str);
- return true;
- }
- CMD:a(playerid, params[]){
- if(PlayerInfo[playerid][Admin] < 1)return SendFormatMsg(playerid, Branco,"{FF4500}[Comando]{FFFFFF} Você não tem permissão para usar esse comando." );
- if(isnull(params))return SendClientMessage(playerid, Vermelho, "{FF4500}[Administração]{FFFFFF} Modo de uso correto /a [texto]");
- for(new i = 0; i < GetMaxPlayers(); ++i){
- if(PlayerInfo[i][Admin] > 0){
- SendFormatMsg(i, Branco, "{FF4500}[Chat][%s][%s]:{FFFFFF} %s", CargosAdmin(playerid),Nome(playerid),params);
- }
- }
- return true;
- }
- CMD:testando(playerid){
- GivePlayerMoney(playerid, 5000);
- return true;
- }
- CMD:setskin(playerid, params[]){
- new ID, skin;
- if(PlayerInfo[playerid][Admin] < 2)return SendFormatMsg(playerid, Branco,"{FF4500}[Comando]{FFFFFF} Você não tem permissão para usar esse comando." );
- if(sscanf(params,"ud",ID,skin))return SendClientMessage(playerid, Vermelho, "{FF4500}[Administração]{FFFFFF} Modo de uso correto /setskin [playerid] [skin]");
- SetPlayerSkin(ID, skin);
- PlayerInfo[playerid][Skin] = skin;
- SendFormatMsg(playerid, Branco, "{FF4500}[Comando]{FFFFFF} Você setou a skin {FF4500}(%s){FFFFFF} para a skin ID:{FF0000}(%d){FFFFFF}",Nome(ID),skin);
- return true;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement