SHOW:
|
|
- or go back to the newest paste.
1 | /* | |
2 | ***************************************** | |
3 | * H H eeee m m pppp * | |
4 | * H H e m m m m p p * | |
5 | * HHHHH eee m m m m ppp * | |
6 | * H H e m m m p * | |
7 | * H H eeee m m p * | |
8 | ***************************************** System ® | |
9 | ||
10 | |=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-| | |
11 | |=-=-=-=-=-=-=-=-=-=-=-=-=-=[hEmp System - Criado e Desenvolvido por: HeyHoLetsGo]=-=-=-=-=-=-=-=-=-=-=-=-=| | |
12 | |=-=-=-=-=-=-=-=-=-=-=-=-=-=[Créditos ao Tonisaltolia por BETA Tester + Ajuda ]=-=-=-=-=-=-=-=-=-=-=-=-=| | |
13 | |=-=-=-=-=-=-=-=-=-=-=-=-=-=[Visite: forum.sa-mp.com | NÃO RETIRE OS CRÉDITOS! ]=-=-=-=-=-=-=-=-=-=-=-=-=| | |
14 | |=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-| | |
15 | ||
16 | */ | |
17 | ||
18 | #include a_samp | |
19 | #include ZCMD | |
20 | #include DOF2 | |
21 | ||
22 | #define DIALOG_VALOR_EMP (1) | |
23 | #define DIALOG_EMP_INT_ID (2) | |
24 | #define DIALOG_INT_ID (3) | |
25 | #define DIALOG_EXTORCAO (4) | |
26 | #define DIALOG_PICKUP (5) | |
27 | #define DIALOG_NOME (6) | |
28 | #define DIALOG_INT_CHOOSE1 (7) | |
29 | #define DIALOG_INT_CHOOSE2 (8) | |
30 | #define DIALOG_CONCLUSAO (9) | |
31 | #define DIALOG_SALDO_EMP (10) | |
32 | #define DIALOG_COMPRAR_EMP (11) | |
33 | #define DIALOG_VENDER_EMP (12) | |
34 | #define DIALOG_DELETAR_EMP (13) | |
35 | #define DIALOG_INFOS_EMP (14) | |
36 | #define DIALOG_INFOS_EMP_SHOW (15) | |
37 | #define DIALOG_CREDITOS (16) | |
38 | ||
39 | enum EnumEmp | |
40 | { | |
41 | Float:X, | |
42 | Float:Y, | |
43 | Float:Z, | |
44 | ValorEmp, | |
45 | IntID, | |
46 | Extorcao, | |
47 | Pickup, | |
48 | Float:UltimaPosX, | |
49 | Float:UltimaPosY, | |
50 | Float:UltimaPosZ, | |
51 | bool:DentroEmp, | |
52 | IDEmpPresente | |
53 | }; | |
54 | ||
55 | new InfosEmp[MAX_PLAYERS][EnumEmp],NomeEmp[64],IDEmp[MAX_PLAYERS],Text3D:IDTextEmp[999],EmpPickup[999]; | |
56 | ||
57 | public OnFilterScriptInit() | |
58 | { | |
59 | CarregarEmps(); | |
60 | print("\n=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-="); | |
61 | print("hEmp System - Criador de empresas In-Game"); | |
62 | print("Criado por: HeyHoLetsGo | forum.sa-mp.com"); | |
63 | print("CARREGADO COM SUCESSO! Bom jogo!"); | |
64 | print("=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=\n"); | |
65 | return 1; | |
66 | } | |
67 | ||
68 | - | public OnPlayerDisconnect(playerid) |
68 | + | public OnFilterScriptExit() |
69 | { | |
70 | DOF2_Exit(); | |
71 | return 1; | |
72 | } | |
73 | ||
74 | public OnPlayerKeyStateChange(playerid, newkeys, oldkeys) | |
75 | { | |
76 | if ((newkeys==KEY_SECONDARY_ATTACK)) | |
77 | { | |
78 | for(new e = 0; e <= 999; ++e) | |
79 | { | |
80 | new Emps[128]; | |
81 | format(Emps,sizeof(Emps),"Empresas/%d.ini",e); | |
82 | { | |
83 | if(IsPlayerInRangeOfPoint(playerid,2.0,DOF2_GetFloat(Emps,"X"),DOF2_GetFloat(Emps,"Y"),DOF2_GetFloat(Emps,"Z"))) | |
84 | { | |
85 | if(DOF2_GetInt(Emps,"IDInterior") == 0) | |
86 | { | |
87 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
88 | SetPlayerInterior(playerid,17); | |
89 | SetPlayerPos(playerid,-25.884498,-185.868988,1003.546875); | |
90 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
91 | InfosEmp[playerid][DentroEmp] = true; | |
92 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
93 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
94 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
95 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
96 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
97 | GameTextForPlayer(playerid,GameText,4000,1); | |
98 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
99 | break; | |
100 | } | |
101 | if(DOF2_GetInt(Emps,"IDInterior") == 1) | |
102 | { | |
103 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
104 | SetPlayerInterior(playerid,10); | |
105 | SetPlayerPos(playerid,6.091179,-29.271898,1003.549438); | |
106 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
107 | InfosEmp[playerid][DentroEmp] = true; | |
108 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
109 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
110 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
111 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
112 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
113 | GameTextForPlayer(playerid,GameText,4000,1); | |
114 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
115 | break; | |
116 | } | |
117 | if(DOF2_GetInt(Emps,"IDInterior") == 2) | |
118 | { | |
119 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
120 | SetPlayerInterior(playerid,18); | |
121 | SetPlayerPos(playerid,-30.946699,-89.609596,1003.546875); | |
122 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
123 | InfosEmp[playerid][DentroEmp] = true; | |
124 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
125 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
126 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
127 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
128 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
129 | GameTextForPlayer(playerid,GameText,4000,1); | |
130 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
131 | break; | |
132 | } | |
133 | if(DOF2_GetInt(Emps,"IDInterior") == 3) | |
134 | { | |
135 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
136 | SetPlayerInterior(playerid,16); | |
137 | SetPlayerPos(playerid,-25.132598,-139.066986,1003.546875); | |
138 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
139 | InfosEmp[playerid][DentroEmp] = true; | |
140 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
141 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
142 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
143 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
144 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
145 | GameTextForPlayer(playerid,GameText,4000,1); | |
146 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
147 | break; | |
148 | } | |
149 | if(DOF2_GetInt(Emps,"IDInterior") == 4) | |
150 | { | |
151 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
152 | SetPlayerInterior(playerid,4); | |
153 | SetPlayerPos(playerid,-27.312299,-29.277599,1003.557250); | |
154 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
155 | InfosEmp[playerid][DentroEmp] = true; | |
156 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
157 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
158 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
159 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
160 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
161 | GameTextForPlayer(playerid,GameText,4000,1); | |
162 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
163 | break; | |
164 | } | |
165 | if(DOF2_GetInt(Emps,"IDInterior") == 5) | |
166 | { | |
167 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
168 | SetPlayerInterior(playerid,6); | |
169 | SetPlayerPos(playerid,-26.691598,-55.714897,1003.546875); | |
170 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
171 | InfosEmp[playerid][DentroEmp] = true; | |
172 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
173 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
174 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
175 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
176 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
177 | GameTextForPlayer(playerid,GameText,4000,1); | |
178 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
179 | break; | |
180 | } | |
181 | if(DOF2_GetInt(Emps,"IDInterior") == 6) | |
182 | { | |
183 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
184 | SetPlayerInterior(playerid,14); | |
185 | SetPlayerPos(playerid,-1827.147338,7.207417,1061.143554); | |
186 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
187 | InfosEmp[playerid][DentroEmp] = true; | |
188 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
189 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
190 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
191 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
192 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
193 | GameTextForPlayer(playerid,GameText,4000,1); | |
194 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
195 | break; | |
196 | } | |
197 | if(DOF2_GetInt(Emps,"IDInterior") == 7) | |
198 | { | |
199 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
200 | SetPlayerInterior(playerid,14); | |
201 | SetPlayerPos(playerid,-1861.936889,54.908092,1061.143554); | |
202 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
203 | InfosEmp[playerid][DentroEmp] = true; | |
204 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
205 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
206 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
207 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
208 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
209 | GameTextForPlayer(playerid,GameText,4000,1); | |
210 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
211 | break; | |
212 | } | |
213 | if(DOF2_GetInt(Emps,"IDInterior") == 8) | |
214 | { | |
215 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
216 | SetPlayerInterior(playerid,1); | |
217 | SetPlayerPos(playerid,1.808619,32.384357,1199.593750); | |
218 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
219 | InfosEmp[playerid][DentroEmp] = true; | |
220 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
221 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
222 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
223 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
224 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
225 | GameTextForPlayer(playerid,GameText,4000,1); | |
226 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
227 | break; | |
228 | } | |
229 | if(DOF2_GetInt(Emps,"IDInterior") == 9) | |
230 | { | |
231 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
232 | SetPlayerInterior(playerid,9); | |
233 | SetPlayerPos(playerid,315.745086,984.969299,1958.919067); | |
234 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
235 | InfosEmp[playerid][DentroEmp] = true; | |
236 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
237 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
238 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
239 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
240 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
241 | GameTextForPlayer(playerid,GameText,4000,1); | |
242 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
243 | break; | |
244 | } | |
245 | if(DOF2_GetInt(Emps,"IDInterior") == 10) | |
246 | { | |
247 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
248 | SetPlayerInterior(playerid,1); | |
249 | SetPlayerPos(playerid,286.148986,-40.644397,1001.515625); | |
250 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
251 | InfosEmp[playerid][DentroEmp] = true; | |
252 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
253 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
254 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
255 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
256 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
257 | GameTextForPlayer(playerid,GameText,4000,1); | |
258 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
259 | break; | |
260 | } | |
261 | if(DOF2_GetInt(Emps,"IDInterior") == 11) | |
262 | { | |
263 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
264 | SetPlayerInterior(playerid,4); | |
265 | SetPlayerPos(playerid,286.800994,-82.547599,1001.515625); | |
266 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
267 | InfosEmp[playerid][DentroEmp] = true; | |
268 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
269 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
270 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
271 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
272 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
273 | GameTextForPlayer(playerid,GameText,4000,1); | |
274 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
275 | break; | |
276 | } | |
277 | if(DOF2_GetInt(Emps,"IDInterior") == 12) | |
278 | { | |
279 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
280 | SetPlayerInterior(playerid,6); | |
281 | SetPlayerPos(playerid,296.919982,-108.071998,1001.515625); | |
282 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
283 | InfosEmp[playerid][DentroEmp] = true; | |
284 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
285 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
286 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
287 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
288 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
289 | GameTextForPlayer(playerid,GameText,4000,1); | |
290 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
291 | break; | |
292 | } | |
293 | if(DOF2_GetInt(Emps,"IDInterior") == 13) | |
294 | { | |
295 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
296 | SetPlayerInterior(playerid,7); | |
297 | SetPlayerPos(playerid,314.820983,-141.431991,999.601562); | |
298 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
299 | InfosEmp[playerid][DentroEmp] = true; | |
300 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
301 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
302 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
303 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
304 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
305 | GameTextForPlayer(playerid,GameText,4000,1); | |
306 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
307 | break; | |
308 | } | |
309 | if(DOF2_GetInt(Emps,"IDInterior") == 14) | |
310 | { | |
311 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
312 | SetPlayerInterior(playerid,6); | |
313 | SetPlayerPos(playerid,316.524993,-167.706985,999.593750); | |
314 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
315 | InfosEmp[playerid][DentroEmp] = true; | |
316 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
317 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
318 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
319 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
320 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
321 | GameTextForPlayer(playerid,GameText,4000,1); | |
322 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
323 | break; | |
324 | } | |
325 | if(DOF2_GetInt(Emps,"IDInterior") == 15) | |
326 | { | |
327 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
328 | SetPlayerInterior(playerid,7); | |
329 | SetPlayerPos(playerid,302.292877,-143.139099,1004.062500); | |
330 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
331 | InfosEmp[playerid][DentroEmp] = true; | |
332 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
333 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
334 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
335 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
336 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
337 | GameTextForPlayer(playerid,GameText,4000,1); | |
338 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
339 | break; | |
340 | } | |
341 | if(DOF2_GetInt(Emps,"IDInterior") == 16) | |
342 | { | |
343 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
344 | SetPlayerInterior(playerid,7); | |
345 | SetPlayerPos(playerid,298.507934,-141.647048,1004.054748); | |
346 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
347 | InfosEmp[playerid][DentroEmp] = true; | |
348 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
349 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
350 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
351 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
352 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
353 | GameTextForPlayer(playerid,GameText,4000,1); | |
354 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
355 | break; | |
356 | } | |
357 | if(DOF2_GetInt(Emps,"IDInterior") == 17) | |
358 | { | |
359 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
360 | SetPlayerInterior(playerid,3); | |
361 | SetPlayerPos(playerid,1038.531372,0.111030,1001.284484); | |
362 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
363 | InfosEmp[playerid][DentroEmp] = true; | |
364 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
365 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
366 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
367 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
368 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
369 | GameTextForPlayer(playerid,GameText,4000,1); | |
370 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
371 | break; | |
372 | } | |
373 | if(DOF2_GetInt(Emps,"IDInterior") == 18) | |
374 | { | |
375 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
376 | SetPlayerInterior(playerid,12); | |
377 | SetPlayerPos(playerid,444.646911,508.239044,1001.419494); | |
378 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
379 | InfosEmp[playerid][DentroEmp] = true; | |
380 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
381 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
382 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
383 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
384 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
385 | GameTextForPlayer(playerid,GameText,4000,1); | |
386 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
387 | break; | |
388 | } | |
389 | if(DOF2_GetInt(Emps,"IDInterior") == 19) | |
390 | { | |
391 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
392 | SetPlayerInterior(playerid,15); | |
393 | SetPlayerPos(playerid,2215.454833,-1147.475585,1025.796875); | |
394 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
395 | InfosEmp[playerid][DentroEmp] = true; | |
396 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
397 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
398 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
399 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
400 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
401 | GameTextForPlayer(playerid,GameText,4000,1); | |
402 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
403 | break; | |
404 | } | |
405 | if(DOF2_GetInt(Emps,"IDInterior") == 20) | |
406 | { | |
407 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
408 | SetPlayerInterior(playerid,3); | |
409 | SetPlayerPos(playerid,833.269775,10.588416,1004.179687); | |
410 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
411 | InfosEmp[playerid][DentroEmp] = true; | |
412 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
413 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
414 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
415 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
416 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
417 | GameTextForPlayer(playerid,GameText,4000,1); | |
418 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
419 | break; | |
420 | } | |
421 | if(DOF2_GetInt(Emps,"IDInterior") == 21) | |
422 | { | |
423 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
424 | SetPlayerInterior(playerid,3); | |
425 | SetPlayerPos(playerid,-103.559165,-24.225606,1000.718750); | |
426 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
427 | InfosEmp[playerid][DentroEmp] = true; | |
428 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
429 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
430 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
431 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
432 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
433 | GameTextForPlayer(playerid,GameText,4000,1); | |
434 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
435 | break; | |
436 | } | |
437 | if(DOF2_GetInt(Emps,"IDInterior") == 22) | |
438 | { | |
439 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
440 | SetPlayerInterior(playerid,1); | |
441 | SetPlayerPos(playerid,963.418762,2108.292480,1011.030273); | |
442 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
443 | InfosEmp[playerid][DentroEmp] = true; | |
444 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
445 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
446 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
447 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
448 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
449 | GameTextForPlayer(playerid,GameText,4000,1); | |
450 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
451 | break; | |
452 | } | |
453 | if(DOF2_GetInt(Emps,"IDInterior") == 23) | |
454 | { | |
455 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
456 | SetPlayerInterior(playerid,6); | |
457 | SetPlayerPos(playerid,-2240.468505,137.060440,1035.414062); | |
458 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
459 | InfosEmp[playerid][DentroEmp] = true; | |
460 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
461 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
462 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
463 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
464 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
465 | GameTextForPlayer(playerid,GameText,4000,1); | |
466 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
467 | break; | |
468 | } | |
469 | if(DOF2_GetInt(Emps,"IDInterior") == 24) | |
470 | { | |
471 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
472 | SetPlayerInterior(playerid,0); | |
473 | SetPlayerPos(playerid,663.836242,-575.605407,16.343263); | |
474 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
475 | InfosEmp[playerid][DentroEmp] = true; | |
476 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
477 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
478 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
479 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
480 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
481 | GameTextForPlayer(playerid,GameText,4000,1); | |
482 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
483 | break; | |
484 | } | |
485 | if(DOF2_GetInt(Emps,"IDInterior") == 25) | |
486 | { | |
487 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
488 | SetPlayerInterior(playerid,1); | |
489 | SetPlayerPos(playerid,2169.461181,1618.798339,999.976562); | |
490 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
491 | InfosEmp[playerid][DentroEmp] = true; | |
492 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
493 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
494 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
495 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
496 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
497 | GameTextForPlayer(playerid,GameText,4000,1); | |
498 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
499 | break; | |
500 | } | |
501 | if(DOF2_GetInt(Emps,"IDInterior") == 26) | |
502 | { | |
503 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
504 | SetPlayerInterior(playerid,10); | |
505 | SetPlayerPos(playerid,1889.953369,1017.438293,31.882812); | |
506 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
507 | InfosEmp[playerid][DentroEmp] = true; | |
508 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
509 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
510 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
511 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
512 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
513 | GameTextForPlayer(playerid,GameText,4000,1); | |
514 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
515 | break; | |
516 | } | |
517 | if(DOF2_GetInt(Emps,"IDInterior") == 27) | |
518 | { | |
519 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
520 | SetPlayerInterior(playerid,1); | |
521 | SetPlayerPos(playerid,-2159.122802,641.517517,1052.381713); | |
522 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
523 | InfosEmp[playerid][DentroEmp] = true; | |
524 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
525 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
526 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
527 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
528 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
529 | GameTextForPlayer(playerid,GameText,4000,1); | |
530 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
531 | break; | |
532 | } | |
533 | if(DOF2_GetInt(Emps,"IDInterior") == 28) | |
534 | { | |
535 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
536 | SetPlayerInterior(playerid,15); | |
537 | SetPlayerPos(playerid,207.737991,-109.019996,1005.132812); | |
538 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
539 | InfosEmp[playerid][DentroEmp] = true; | |
540 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
541 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
542 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
543 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
544 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
545 | GameTextForPlayer(playerid,GameText,4000,1); | |
546 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
547 | break; | |
548 | } | |
549 | if(DOF2_GetInt(Emps,"IDInterior") == 29) | |
550 | { | |
551 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
552 | SetPlayerInterior(playerid,14); | |
553 | SetPlayerPos(playerid,204.332992,-166.694992,1000.523437); | |
554 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
555 | InfosEmp[playerid][DentroEmp] = true; | |
556 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
557 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
558 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
559 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
560 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
561 | GameTextForPlayer(playerid,GameText,4000,1); | |
562 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
563 | break; | |
564 | } | |
565 | if(DOF2_GetInt(Emps,"IDInterior") == 30) | |
566 | { | |
567 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
568 | SetPlayerInterior(playerid,3); | |
569 | SetPlayerPos(playerid,207.054992,-138.804992,1003.507812); | |
570 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
571 | InfosEmp[playerid][DentroEmp] = true; | |
572 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
573 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
574 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
575 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
576 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
577 | GameTextForPlayer(playerid,GameText,4000,1); | |
578 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
579 | break; | |
580 | } | |
581 | if(DOF2_GetInt(Emps,"IDInterior") == 31) | |
582 | { | |
583 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
584 | SetPlayerInterior(playerid,1); | |
585 | SetPlayerPos(playerid,203.777999,-48.492397,1001.804687); | |
586 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
587 | InfosEmp[playerid][DentroEmp] = true; | |
588 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
589 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
590 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
591 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
592 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
593 | GameTextForPlayer(playerid,GameText,4000,1); | |
594 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
595 | break; | |
596 | } | |
597 | if(DOF2_GetInt(Emps,"IDInterior") == 32) | |
598 | { | |
599 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
600 | SetPlayerInterior(playerid,5); | |
601 | SetPlayerPos(playerid,226.293991,-7.431529,1002.210937); | |
602 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
603 | InfosEmp[playerid][DentroEmp] = true; | |
604 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
605 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
606 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
607 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
608 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
609 | GameTextForPlayer(playerid,GameText,4000,1); | |
610 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
611 | break; | |
612 | } | |
613 | if(DOF2_GetInt(Emps,"IDInterior") == 33) | |
614 | { | |
615 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
616 | SetPlayerInterior(playerid,18); | |
617 | SetPlayerPos(playerid,161.391006,-93.159156,1001.804687); | |
618 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
619 | InfosEmp[playerid][DentroEmp] = true; | |
620 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
621 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
622 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
623 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
624 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
625 | GameTextForPlayer(playerid,GameText,4000,1); | |
626 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
627 | break; | |
628 | } | |
629 | if(DOF2_GetInt(Emps,"IDInterior") == 34) | |
630 | { | |
631 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
632 | SetPlayerInterior(playerid,17); | |
633 | SetPlayerPos(playerid,493.390991,-22.722799,1000.679687); | |
634 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
635 | InfosEmp[playerid][DentroEmp] = true; | |
636 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
637 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
638 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
639 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
640 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
641 | GameTextForPlayer(playerid,GameText,4000,1); | |
642 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
643 | break; | |
644 | } | |
645 | if(DOF2_GetInt(Emps,"IDInterior") == 35) | |
646 | { | |
647 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
648 | SetPlayerInterior(playerid,11); | |
649 | SetPlayerPos(playerid,501.980987,-69.150199,998.757812); | |
650 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
651 | InfosEmp[playerid][DentroEmp] = true; | |
652 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
653 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
654 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
655 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
656 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
657 | GameTextForPlayer(playerid,GameText,4000,1); | |
658 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
659 | break; | |
660 | } | |
661 | if(DOF2_GetInt(Emps,"IDInterior") == 36) | |
662 | { | |
663 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
664 | SetPlayerInterior(playerid,18); | |
665 | SetPlayerPos(playerid,-227.027999,1401.229980,27.765625); | |
666 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
667 | InfosEmp[playerid][DentroEmp] = true; | |
668 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
669 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
670 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
671 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
672 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
673 | GameTextForPlayer(playerid,GameText,4000,1); | |
674 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
675 | break; | |
676 | } | |
677 | if(DOF2_GetInt(Emps,"IDInterior") == 37) | |
678 | { | |
679 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
680 | SetPlayerInterior(playerid,4); | |
681 | SetPlayerPos(playerid,457.304748,-88.428497,999.554687); | |
682 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
683 | InfosEmp[playerid][DentroEmp] = true; | |
684 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
685 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
686 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
687 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
688 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
689 | GameTextForPlayer(playerid,GameText,4000,1); | |
690 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
691 | break; | |
692 | } | |
693 | if(DOF2_GetInt(Emps,"IDInterior") == 38) | |
694 | { | |
695 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
696 | SetPlayerInterior(playerid,5); | |
697 | SetPlayerPos(playerid,454.973937,-110.104995,1000.077209); | |
698 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
699 | InfosEmp[playerid][DentroEmp] = true; | |
700 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
701 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
702 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
703 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
704 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
705 | GameTextForPlayer(playerid,GameText,4000,1); | |
706 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
707 | break; | |
708 | } | |
709 | if(DOF2_GetInt(Emps,"IDInterior") == 39) | |
710 | { | |
711 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
712 | SetPlayerInterior(playerid,6); | |
713 | SetPlayerPos(playerid,435.271331,-80.958938,999.554687); | |
714 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
715 | InfosEmp[playerid][DentroEmp] = true; | |
716 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
717 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
718 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
719 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
720 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
721 | GameTextForPlayer(playerid,GameText,4000,1); | |
722 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
723 | break; | |
724 | } | |
725 | if(DOF2_GetInt(Emps,"IDInterior") == 40) | |
726 | { | |
727 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
728 | SetPlayerInterior(playerid,1); | |
729 | SetPlayerPos(playerid,452.489990,-18.179698,1001.132812); | |
730 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
731 | InfosEmp[playerid][DentroEmp] = true; | |
732 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
733 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
734 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
735 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
736 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
737 | GameTextForPlayer(playerid,GameText,4000,1); | |
738 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
739 | break; | |
740 | } | |
741 | if(DOF2_GetInt(Emps,"IDInterior") == 41) | |
742 | { | |
743 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
744 | SetPlayerInterior(playerid,1); | |
745 | SetPlayerPos(playerid,681.557861,-455.680053,-25.609874); | |
746 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
747 | InfosEmp[playerid][DentroEmp] = true; | |
748 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
749 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
750 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
751 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
752 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
753 | GameTextForPlayer(playerid,GameText,4000,1); | |
754 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
755 | break; | |
756 | } | |
757 | if(DOF2_GetInt(Emps,"IDInterior") == 42) | |
758 | { | |
759 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
760 | SetPlayerInterior(playerid,10); | |
761 | SetPlayerPos(playerid,375.962463,-65.816848,1001.507812); | |
762 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
763 | InfosEmp[playerid][DentroEmp] = true; | |
764 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
765 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
766 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
767 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
768 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
769 | GameTextForPlayer(playerid,GameText,4000,1); | |
770 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
771 | break; | |
772 | } | |
773 | if(DOF2_GetInt(Emps,"IDInterior") == 43) | |
774 | { | |
775 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
776 | SetPlayerInterior(playerid,9); | |
777 | SetPlayerPos(playerid,369.579528,-4.487294,1001.858886); | |
778 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
779 | InfosEmp[playerid][DentroEmp] = true; | |
780 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
781 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
782 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
783 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
784 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
785 | GameTextForPlayer(playerid,GameText,4000,1); | |
786 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
787 | break; | |
788 | } | |
789 | if(DOF2_GetInt(Emps,"IDInterior") == 44) | |
790 | { | |
791 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
792 | SetPlayerInterior(playerid,5); | |
793 | SetPlayerPos(playerid,373.825653,-117.270904,1001.499511); | |
794 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
795 | InfosEmp[playerid][DentroEmp] = true; | |
796 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
797 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
798 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
799 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
800 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
801 | GameTextForPlayer(playerid,GameText,4000,1); | |
802 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
803 | break; | |
804 | } | |
805 | if(DOF2_GetInt(Emps,"IDInterior") == 45) | |
806 | { | |
807 | GetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
808 | SetPlayerInterior(playerid,17); | |
809 | SetPlayerPos(playerid,381.169189,-188.803024,1000.632812); | |
810 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Digite {FFFFFF}/sairemp {FADD00}para sair desta empresa{FFFFFF}."); | |
811 | InfosEmp[playerid][DentroEmp] = true; | |
812 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Extorcao")); | |
813 | new AtualCofre[MAX_PLAYERS],GameText[128]; | |
814 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
815 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]+DOF2_GetInt(Emps,"Extorcao")); | |
816 | format(GameText,sizeof(GameText),"Entrada: -R$%d",DOF2_GetInt(Emps,"Extorcao")); | |
817 | GameTextForPlayer(playerid,GameText,4000,1); | |
818 | InfosEmp[playerid][IDEmpPresente] = DOF2_GetInt(Emps,"ID"); | |
819 | break; | |
820 | } | |
821 | } | |
822 | } | |
823 | } | |
824 | } | |
825 | return 1; | |
826 | } | |
827 | ||
828 | CMD:creditoshemp(playerid) | |
829 | { | |
830 | ShowPlayerDialog(playerid,DIALOG_CREDITOS,DIALOG_STYLE_MSGBOX,"{FADD00}h{1F00CF}Emp{FFFFFF} - CRÉDITOS","{00ED04}Criado e desenvido por: {FFFFFF}HeyHoLetsGo\n{00ED04}Créditos também a {FFFFFF}Tonisantolia - {00ED04}BETA Tester.\n \n{00ED04}Tenha um {FFFFFF}Bom Jogo{00ED04}!","FECHAR",""); | |
831 | return 1; | |
832 | } | |
833 | ||
834 | CMD:infosemp(playerid) | |
835 | { | |
836 | if(IsPlayerAdmin(playerid)) | |
837 | { | |
838 | ShowPlayerDialog(playerid,DIALOG_INFOS_EMP,DIALOG_STYLE_INPUT,"{FADD00}h{1F00CF}Emp{FFFFFF} - INFORMAÇÕES","{00ED04}Digite o {FFFFFF}ID {00ED04}da empresa que deseja vizualizar as informações{FFFFFF}:","VER","Cancelar"); | |
839 | } | |
840 | else SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FF0000}Você não é um Administrador logado na RCON então não pode realizar este comando{FFFFFF}."); | |
841 | return 1; | |
842 | } | |
843 | ||
844 | CMD:deletaremp(playerid) | |
845 | { | |
846 | if(IsPlayerAdmin(playerid)) | |
847 | { | |
848 | ShowPlayerDialog(playerid,DIALOG_DELETAR_EMP,DIALOG_STYLE_INPUT,"{26C2FF}h{1F00CF}Emp{FFFFFF} - DELETAR EMPRESA","{00ED04}Digite o {FFFFFF}ID {00ED04}da empresa que deseja deletar{FFFFFF}:","PRÓXIMO","Cancelar"); | |
849 | } | |
850 | else SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FF0000}Você não é um Administrador logado na RCON{FFFFFF}."); | |
851 | return 1; | |
852 | } | |
853 | ||
854 | CMD:venderemp(playerid) | |
855 | { | |
856 | new Emps[64]; | |
857 | for(new e = 0; e <= 999; ++e) | |
858 | { | |
859 | format(Emps,sizeof(Emps),"Empresas/%d.ini",InfosEmp[playerid][IDEmpPresente]); | |
860 | { | |
861 | new Nome[MAX_PLAYER_NAME],str[600],str2[600]; | |
862 | GetPlayerName(playerid,Nome,MAX_PLAYER_NAME); | |
863 | if(InfosEmp[playerid][DentroEmp] == true) | |
864 | { | |
865 | if(!strcmp(DOF2_GetString(Emps,"DONO"),Nome,false)) | |
866 | { | |
867 | format(str,sizeof(str),"{00ED04}Você está prestes a vender sua {FFFFFF}empresa:\n \n{00ED04}Empresa nas coordenadas:\nX: {FFFFFF}%f {00ED04}Y: {FFFFFF}%f {00ED04}Z: {FFFFFF}%f\n{00ED04}No valor de: R${FFFFFF}%d \n{00ED04}Com o interior conforme o ID: {FFFFFF}%d",DOF2_GetFloat(Emps,"X"),DOF2_GetFloat(Emps,"Y"),DOF2_GetFloat(Emps,"Z"),DOF2_GetInt(Emps,"Valor"),DOF2_GetInt(Emps,"IDInterior")); strcat(str2,str); | |
868 | format(str,sizeof(str),"\n{00ED04}Com valor inicial de extorção por entrada de: R${FFFFFF}%d\n{00ED04}Com modelo de pickup conforme ID: {FFFFFF}%d\n{00ED04}Com o nome da empresa: {FFFFFF}%s\n \n{00ED04}Você tem certeza de que quer vender sua empresa?\nOBS: {FFFFFF}Você não poderá desfazer isto depois.",DOF2_GetInt(Emps,"Extorcao"),DOF2_GetInt(Emps,"Pickup"),DOF2_GetString(Emps,"Nome")); strcat(str2,str); | |
869 | ShowPlayerDialog(playerid,DIALOG_VENDER_EMP,DIALOG_STYLE_MSGBOX,"{FADD00}h{1F00CF}Emp{FFFFFF} - VENDER EMPRESA",str2,"VENDER","Cancelar"); | |
870 | RetirarEmps(); | |
871 | CarregarEmps(); | |
872 | break; | |
873 | } | |
874 | else SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FF0000}Esta empresa não pertence a você{FFFFFF}!"); | |
875 | break; | |
876 | } | |
877 | else SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FF0000}Você não está em sua empresa{FFFFFF}."); | |
878 | break; | |
879 | } | |
880 | } | |
881 | return 1; | |
882 | } | |
883 | ||
884 | CMD:compraremp(playerid) | |
885 | { | |
886 | for(new e = 0; e <= 999; ++e) | |
887 | { | |
888 | new Emps[128]; | |
889 | format(Emps,sizeof(Emps),"Empresas/%d.ini",e); | |
890 | { | |
891 | if(IsPlayerInRangeOfPoint(playerid,2.0,DOF2_GetFloat(Emps,"X"),DOF2_GetFloat(Emps,"Y"),DOF2_GetFloat(Emps,"Z"))) | |
892 | { | |
893 | if(!strcmp(DOF2_GetString(Emps,"DONO"),"Nenhum",false)) | |
894 | { | |
895 | if(GetPlayerMoney(playerid) >= DOF2_GetInt(Emps,"Valor")) | |
896 | { | |
897 | IDEmp[playerid] = e; | |
898 | new str[600],str2[800]; | |
899 | format(str,sizeof(str),"{00ED04}Você está prestes a comprar esta {FFFFFF}empresa:\n \n{00ED04}Empresa nas coordenadas:\nX: {FFFFFF}%f {00ED04}Y: {FFFFFF}%f {00ED04}Z: {FFFFFF}%f\n{00ED04}No valor de: R${FFFFFF}%d \n{00ED04}Com o interior conforme o ID: {FFFFFF}%d",DOF2_GetFloat(Emps,"X"),DOF2_GetFloat(Emps,"Y"),DOF2_GetFloat(Emps,"Z"),DOF2_GetInt(Emps,"Valor"),DOF2_GetInt(Emps,"IDInterior")); strcat(str2,str); | |
900 | format(str,sizeof(str),"\n{00ED04}Com valor inicial de extorção por entrada de: R${FFFFFF}%d\n{00ED04}Com modelo de pickup conforme ID: {FFFFFF}%d\n{00ED04}Com o nome da empresa: {FFFFFF}%s\n \n{00ED04}Você tem certeza de que quer comprar esta {FFFFFF}empresa{00ED04}?\n \nOBS: {FFFFFF}Você poderá vendê-la a qualquer momento\nusando o comando {00ED04}/venderemp{FFFFFF}.",DOF2_GetInt(Emps,"Extorcao"),DOF2_GetInt(Emps,"Pickup"),DOF2_GetString(Emps,"Nome")); strcat(str2,str); | |
901 | ShowPlayerDialog(playerid,DIALOG_COMPRAR_EMP,DIALOG_STYLE_MSGBOX,"{FADD00}h{1F00CF}Emp{FFFFFF} - COMPRAR EMPRESA",str2,"COMPRAR","Cancelar"); | |
902 | break; | |
903 | } | |
904 | else SendClientMessage(playerid,-1,"{FFFFFF}[ ! ]{FF0000}Você não possúi dinheiro suficiente para comprar esta empresa{FFFFFF}."); | |
905 | break; | |
906 | } | |
907 | else SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FF0000}Esta empresa não está à venda{FFFFFF}!"); | |
908 | break; | |
909 | } | |
910 | } | |
911 | } | |
912 | return 1; | |
913 | } | |
914 | ||
915 | CMD:cofreemp(playerid) | |
916 | { | |
917 | for(new e = 0; e <= 999; ++e) | |
918 | { | |
919 | new Emps[64],TxtSaldoCofre[256]; | |
920 | format(Emps,sizeof(Emps),"Empresas/%d.ini",InfosEmp[playerid][IDEmpPresente]); | |
921 | if(DOF2_FileExists(Emps)) | |
922 | { | |
923 | if(InfosEmp[playerid][DentroEmp] == true) | |
924 | { | |
925 | format(TxtSaldoCofre,sizeof(TxtSaldoCofre),"{00ED04}Saldo do Cofre: R${FFFFFF}%d,00\n \n{00ED04}Use: {FFFFFF}/sacaremp {00ED04}para sacar o dinheiro\n({FFFFFF}COMANDO APENAS DISPONÍVEL PARA O DONO{00ED04})\n \n{00ED04}Tenha um bom jogo!",DOF2_GetInt(Emps,"Cofre")); | |
926 | ShowPlayerDialog(playerid,DIALOG_SALDO_EMP,DIALOG_STYLE_MSGBOX,"{FADD00}h{1F00CF}Emp{FFFFFF} - COFRE DA EMPRESA",TxtSaldoCofre,"FECHAR",""); | |
927 | break; | |
928 | } | |
929 | else SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FF0000}Você não está dentro de uma empresa{FFFFFF}!"); | |
930 | break; | |
931 | } | |
932 | else SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FF0000}Esta empresa falíu{FFFFFF}! {FF0000}(Acaba de ser deletada por um Admin)"); | |
933 | break; | |
934 | } | |
935 | return 1; | |
936 | } | |
937 | ||
938 | CMD:sacaremp(playerid) | |
939 | { | |
940 | for(new e = 0; e <= 999; ++e) | |
941 | { | |
942 | new Emps[128],TxtSaldoCofre[256]; | |
943 | format(Emps,sizeof(Emps),"Empresas/%d.ini",InfosEmp[playerid][IDEmpPresente]); | |
944 | if(DOF2_FileExists(Emps)) | |
945 | { | |
946 | new Nome[MAX_PLAYER_NAME]; | |
947 | GetPlayerName(playerid,Nome,sizeof(Nome)); | |
948 | if(!strcmp(DOF2_GetString(Emps,"DONO"),Nome,false)) | |
949 | { | |
950 | format(TxtSaldoCofre,sizeof(TxtSaldoCofre),"{00ED04}Saldo do Cofre: R${FFFFFF}%d,00\n \n{00ED04}Digite a quantia em dinheiro que deseja sacar:\nOBS: {FFFFFF}Sem {00ED04}R$ {FFFFFF}ou {00ED04}vírgula{FFFFFF}, apenas o número inteiro{00ED04}.",DOF2_GetInt(Emps,"Cofre")); | |
951 | ShowPlayerDialog(playerid,DIALOG_SALDO_EMP,DIALOG_STYLE_INPUT,"{FADD00}h{1F00CF}Emp{FFFFFF} - COFRE DA EMPRESA - SACAR",TxtSaldoCofre,"SACAR","Fechar"); | |
952 | InfosEmp[playerid][IDEmpPresente] = e; | |
953 | break; | |
954 | } | |
955 | else SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FF0000}Você não é o dono desta empresa e não tem permissão de sacar os lucros{FFFFFF}."); | |
956 | break; | |
957 | } | |
958 | else SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FF0000}Esta empresa falíu{FFFFFF}! {FF0000}(Acaba de ser deletada por um Admin)"); | |
959 | break; | |
960 | } | |
961 | return 1; | |
962 | } | |
963 | ||
964 | CMD:sairemp(playerid) | |
965 | { | |
966 | if(InfosEmp[playerid][DentroEmp] == false) | |
967 | { | |
968 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FF0000}Você não está dentro de uma empresa{FFFFFF}!"); | |
969 | } | |
970 | else | |
971 | { | |
972 | SetPlayerInterior(playerid,0); | |
973 | SetPlayerPos(playerid,InfosEmp[playerid][UltimaPosX],InfosEmp[playerid][UltimaPosY],InfosEmp[playerid][UltimaPosZ]); | |
974 | InfosEmp[playerid][DentroEmp] = false; | |
975 | } | |
976 | return 1; | |
977 | } | |
978 | ||
979 | CMD:criaremp(playerid) | |
980 | { | |
981 | if(IsPlayerAdmin(playerid)) | |
982 | { | |
983 | new str[256]; | |
984 | GetPlayerPos(playerid,InfosEmp[playerid][X],InfosEmp[playerid][Y],InfosEmp[playerid][Z]); | |
985 | format(str,sizeof(str),"{00ED04}Você deseja criar uma empresa nas coordenadas:\nX: {FFFFFF}%f {00ED04}Y: {FFFFFF}%f {00ED04}Z: {FFFFFF}%f\n \n{00ED04}Digite o {FFFFFF}VALOR {00ED04}da nova empresa{FFFFFF}:",InfosEmp[playerid][X],InfosEmp[playerid][Y],InfosEmp[playerid][Z]); | |
986 | ShowPlayerDialog(playerid,DIALOG_VALOR_EMP,DIALOG_STYLE_INPUT,"{FADD00}h{1F00CF}Emp{FFFFFF} - CRIAR EMPRESA",str,"Próximo","Cancelar"); | |
987 | } | |
988 | else SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FF0000}Você não é um Administrador logado na RCON então não pode realizar este comando{FFFFFF}."); | |
989 | } | |
990 | ||
991 | public OnDialogResponse(playerid,dialogid,response,listitem,inputtext[]) | |
992 | { | |
993 | if(dialogid == DIALOG_VALOR_EMP) | |
994 | { | |
995 | if(response) | |
996 | { | |
997 | new str[300]; | |
998 | InfosEmp[playerid][ValorEmp] = strval(inputtext); | |
999 | format(str,sizeof(str),"{00ED04}Você deseja criar uma empresa nas coordenadas:\nX: {FFFFFF}%f {00ED04}Y: {FFFFFF}%f {00ED04}Z: {FFFFFF}%f\n{00ED04}No valor de: R${FFFFFF}%d\n \n{00ED04}Escolha o {FFFFFF}INTERIOR {00ED04}da nova empresa na lista a seguir{FFFFFF}:",InfosEmp[playerid][X],InfosEmp[playerid][Y],InfosEmp[playerid][Z],InfosEmp[playerid][ValorEmp]); | |
1000 | ShowPlayerDialog(playerid,DIALOG_INT_CHOOSE1,DIALOG_STYLE_MSGBOX,"{FADD00}h{1F00CF}Emp{FFFFFF} - CRIAR EMPRESA",str,"Próximo","Cancelar"); | |
1001 | } | |
1002 | } | |
1003 | if(dialogid == DIALOG_INT_CHOOSE1) | |
1004 | { | |
1005 | if(response) | |
1006 | { | |
1007 | new list[1500]; | |
1008 | strcat(list,"SELECIONE UM INTERIOR (Mais opções na próxima versão)\n"); | |
1009 | strcat(list,"{00ED04}24/7 - {FFFFFF}1\n{00ED04}24/7 - {FFFFFF}2\n{00ED04}24/7 - {FFFFFF}3\n{00ED04}24/7 - {FFFFFF}4\n{00ED04}24/7 - {FFFFFF}5\n{00ED04}24/7 - {FFFFFF}6\n{00ED04}Balcao do Aeroporto\n{00ED04}Sala de bagagens do Aeroporto\n{00ED04}Shamal - {FFFFFF}Nave\n{00ED04}Andromada - {FFFFFF}Avião\n{00ED04}Loja de armas - {FFFFFF}1\n{00ED04}Loja de armas - {FFFFFF}2\n{00ED04}Loja de armas - {FFFFFF}3\n{00ED04}Loja de armas - {FFFFFF}4\n{00ED04}Loja de armas - {FFFFFF}5\n{00ED04}"); | |
1010 | strcat(list,"Loja de armas - {FFFFFF}Cabines\n{00ED04}Loja de armas - {FFFFFF}Pista\n{00ED04}Corredor dos tolos - {FFFFFF}Blastin\n{00ED04}Sala de orçamento do Motel\n{00ED04}Motel Jefferson\n{00ED04}Loja de apostas - {FFFFFF}Loteria\n{00ED04}Sex Shop\n{00ED04}Fábrica de carne\n{00ED04}Loja do Zero\n{00ED04}Posto de Dillimore\n{00ED04}Porão de Caligula\n{00ED04}Sala de Zeladores FDC\n{00ED04}Escritório do Woozie\n{00ED04}Binco - {FFFFFF}Loja de roupas\n{00ED04}Didier sachs - {FFFFFF}"); | |
1011 | strcat(list,"Loja de roupas\n{00ED04}Prolaps - {FFFFFF}Loja de roupas\n{00ED04}Suburban - {FFFFFF}Loja de roupas\n{00ED04}Victim - {FFFFFF}Loja de roupas\n{00ED04}Zip - {FFFFFF}Loja de roupas\n{00ED04}Alhambra\n{00ED04}Bar\n{00ED04}Bar Lil' probe\n{00ED04}Lanchonete do Jay\n{00ED04}Lanchonete do Gant\n{00ED04}Lanchonete secreta do vale\n{00ED04}Mundo de Coq\n{00ED04}Bar dos bombas\n{00ED04}Burger shot\n{00ED04}Cluckin' bell\n{00ED04}Well stacked pizza\n{00ED04}Rusty Browns rosquinhas"); | |
1012 | ShowPlayerDialog(playerid,DIALOG_INT_CHOOSE2,DIALOG_STYLE_LIST,"{FADD00}h{1F00CF}Emp{FFFFFF} - CRIAR EMPRESA:",list,"Próximo","Cancelar"); | |
1013 | } | |
1014 | } | |
1015 | if(dialogid == DIALOG_INT_CHOOSE2) | |
1016 | { | |
1017 | if(response) | |
1018 | { | |
1019 | for(new i = 0; i <= 46; ++i) | |
1020 | { | |
1021 | if(listitem == i) | |
1022 | { | |
1023 | InfosEmp[playerid][IntID] = i-1; | |
1024 | break; | |
1025 | } | |
1026 | new str[300]; | |
1027 | format(str,sizeof(str),"{00ED04}Você deseja criar uma empresa nas coordenadas:\nX: {FFFFFF}%f {00ED04}Y: {FFFFFF}%f {00ED04}Z: {FFFFFF}%f\n{00ED04}No valor de: R${FFFFFF}%d\n{00ED04}Com o interior número: {FFFFFF}%d\n \n{00ED04}Digite o valor inicial de {FFFFFF}EXTORÇÃO {00ED04}por entrada{FFFFFF}:",InfosEmp[playerid][X],InfosEmp[playerid][Y],InfosEmp[playerid][Z],InfosEmp[playerid][ValorEmp],i); | |
1028 | ShowPlayerDialog(playerid,DIALOG_EXTORCAO,DIALOG_STYLE_INPUT,"{FADD00}h{1F00CF}Emp{FFFFFF} - CRIAR EMPRESA",str,"Próximo","Cancelar"); | |
1029 | } | |
1030 | } | |
1031 | } | |
1032 | if(dialogid == DIALOG_EXTORCAO) | |
1033 | { | |
1034 | if(response) | |
1035 | { | |
1036 | new str[300],str2[500]; | |
1037 | InfosEmp[playerid][Extorcao] = strval(inputtext); | |
1038 | format(str,sizeof(str),"{00ED04}Você deseja criar uma empresa nas coordenadas:\nX: {FFFFFF}%f {00ED04}Y: {FFFFFF}%f {00ED04}Z: {FFFFFF}%f\n{00ED04}No valor de: R${FFFFFF}%d\n{00ED04}Com o interior número: {FFFFFF}%d\n",InfosEmp[playerid][X],InfosEmp[playerid][Y],InfosEmp[playerid][Z],InfosEmp[playerid][ValorEmp],InfosEmp[playerid][IntID]); strcat(str2,str); | |
1039 | format(str,sizeof(str),"{00ED04}Com valor inicial de extorção por entrada de: R${FFFFFF}%d\n \n{00ED04}Digite o {FFFFFF}ID DA PICKUP {00ED04}da nova empresa{FFFFFF}:",InfosEmp[playerid][Extorcao]); strcat(str2,str); | |
1040 | ShowPlayerDialog(playerid,DIALOG_PICKUP,DIALOG_STYLE_INPUT,"{FADD00}h{1F00CF}Emp{FFFFFF} - CRIAR EMPRESA",str2,"Próximo","Cancelar"); | |
1041 | } | |
1042 | } | |
1043 | if(dialogid == DIALOG_PICKUP) | |
1044 | { | |
1045 | if(response) | |
1046 | { | |
1047 | new str[300],str2[600]; | |
1048 | InfosEmp[playerid][Pickup] = strval(inputtext); | |
1049 | format(str,sizeof(str),"{00ED04}Você deseja criar uma empresa nas coordenadas:\nX: {FFFFFF}%f {00ED04}Y: {FFFFFF}%f {00ED04}Z: {FFFFFF}%f\n{00ED04}No valor de: R${FFFFFF}%d\n",InfosEmp[playerid][X],InfosEmp[playerid][Y],InfosEmp[playerid][Z],InfosEmp[playerid][ValorEmp]); strcat(str2,str); | |
1050 | format(str,sizeof(str),"{00ED04}Com o interior conforme o ID: {FFFFFF}%d\n{00ED04}Com valor inicial de extorção por entrada de: R${FFFFFF}%d\n{00ED04}Com modelo de pickup conforme ID: {FFFFFF}%d\n \n{00ED04}Finalizando, digite o {FFFFFF}NOME {00ED04}da nova empresa{FFFFFF}:",InfosEmp[playerid][IntID],InfosEmp[playerid][Extorcao],InfosEmp[playerid][Pickup]); strcat(str2,str); | |
1051 | ShowPlayerDialog(playerid,DIALOG_NOME,DIALOG_STYLE_INPUT,"{FADD00}h{1F00CF}Emp{FFFFFF} - CRIAR EMPRESA",str2,"CRIAR","Cancelar"); | |
1052 | } | |
1053 | } | |
1054 | if(dialogid == DIALOG_NOME) | |
1055 | { | |
1056 | if(response) | |
1057 | { | |
1058 | new str[400],str2[800]; | |
1059 | format(NomeEmp,sizeof(NomeEmp),"%s",inputtext); | |
1060 | format(str,sizeof(str),"{00ED04}Você deseja criar uma empresa nas coordenadas:\nX: {FFFFFF}%f {00ED04}Y: {FFFFFF}%f {00ED04}Z: {FFFFFF}%f\n{00ED04}No valor de: R${FFFFFF}%d\n{00ED04}Com o interior conforme o ID: {FFFFFF}%d\n{00ED04}Com valor inicial de extorção por entrada de: R${FFFFFF}",InfosEmp[playerid][X],InfosEmp[playerid][Y],InfosEmp[playerid][Z],InfosEmp[playerid][ValorEmp],InfosEmp[playerid][IntID]); strcat(str2,str); | |
1061 | format(str,sizeof(str),"%d\n{00ED04}Com modelo de pickup conforme ID: {FFFFFF}%d\n{00ED04}Com o nome da empresa: {FFFFFF}%s\n \n{00ED04}Você tem certeza que deseja criar esta\nnova empresa{FFFFFF}? {00ED04}Clique em {FFFFFF}CRIAR {00ED04}para terminar{FFFFFF}.\n \n{00ED04}OBS: {FFFFFF}Você poderá destruir esta empresa\nà qualquer momento usando {00ED04}/destruiremp{FFFFFF}.",InfosEmp[playerid][Extorcao],InfosEmp[playerid][Pickup],NomeEmp); strcat(str2,str); | |
1062 | ShowPlayerDialog(playerid,DIALOG_CONCLUSAO,DIALOG_STYLE_MSGBOX,"{FADD00}h{1F00CF}Emp{FFFFFF} - CRIAR EMPRESA",str2,"CRIAR","Cancelar"); | |
1063 | } | |
1064 | } | |
1065 | if(dialogid == DIALOG_CONCLUSAO) | |
1066 | { | |
1067 | if(response) | |
1068 | { | |
1069 | for(new e = 0; e <= 999; e++) | |
1070 | { | |
1071 | new Emps[64]; | |
1072 | format(Emps,sizeof(Emps),"Empresas/%d.ini",e); | |
1073 | if(!DOF2_FileExists(Emps)) | |
1074 | { | |
1075 | DOF2_CreateFile(Emps); | |
1076 | DOF2_SetString(Emps,"Nome",NomeEmp); | |
1077 | DOF2_SetFloat(Emps,"X",InfosEmp[playerid][X]); | |
1078 | DOF2_SetFloat(Emps,"Y",InfosEmp[playerid][Y]); | |
1079 | DOF2_SetFloat(Emps,"Z",InfosEmp[playerid][Z]); | |
1080 | DOF2_SetInt(Emps,"ID",e); | |
1081 | DOF2_SetInt(Emps,"Valor",InfosEmp[playerid][ValorEmp]); | |
1082 | DOF2_SetInt(Emps,"IDInterior",InfosEmp[playerid][IntID]); | |
1083 | DOF2_SetInt(Emps,"Extorcao",InfosEmp[playerid][Extorcao]); | |
1084 | DOF2_SetInt(Emps,"Pickup",InfosEmp[playerid][Pickup]); | |
1085 | DOF2_SetInt(Emps,"Cofre",0); | |
1086 | DOF2_SetString(Emps,"DONO","Nenhum"); | |
1087 | DOF2_SaveFile(); | |
1088 | CarregarEmps(); | |
1089 | break; | |
1090 | } | |
1091 | } | |
1092 | } | |
1093 | else SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FADD00}Criação da nova empresa cancelada{FFFFFF}."); | |
1094 | } | |
1095 | if(dialogid == DIALOG_COMPRAR_EMP) | |
1096 | { | |
1097 | if(response) | |
1098 | { | |
1099 | new Nome[MAX_PLAYER_NAME],Emps[64]; | |
1100 | format(Emps,sizeof(Emps),"Empresas/%d.ini",IDEmp[playerid]); | |
1101 | GetPlayerName(playerid,Nome,MAX_PLAYER_NAME); | |
1102 | DOF2_SetString(Emps,"DONO",Nome); | |
1103 | DOF2_SaveFile(); | |
1104 | GivePlayerMoney(playerid,-DOF2_GetInt(Emps,"Valor")); | |
1105 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {00ED04}Você comprou esta empresa! Use: {FFFFFF}/ajudaemp {00ED04}para mais informações{FFFFFF}."); | |
1106 | RetirarEmps(); | |
1107 | CarregarEmps(); | |
1108 | } | |
1109 | } | |
1110 | if(dialogid == DIALOG_VENDER_EMP) | |
1111 | { | |
1112 | if(response) | |
1113 | { | |
1114 | new Emps[64]; | |
1115 | format(Emps,sizeof(Emps),"Empresas/%d.ini",InfosEmp[playerid][IDEmpPresente]); | |
1116 | DOF2_SetString(Emps,"DONO","Nenhum"); | |
1117 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {00ED04}Empresa vendida com sucesso{FFFFFF}!"); | |
1118 | RetirarEmps(); | |
1119 | CarregarEmps(); | |
1120 | } | |
1121 | } | |
1122 | if(dialogid == DIALOG_SALDO_EMP) | |
1123 | { | |
1124 | new Emps[64]; | |
1125 | format(Emps,sizeof(Emps),"Empresas/%d.ini",InfosEmp[playerid][IDEmpPresente]); | |
1126 | { | |
1127 | if(strval(inputtext) <= DOF2_GetInt(Emps,"Cofre")) | |
1128 | { | |
1129 | new AtualCofre[MAX_PLAYERS]; | |
1130 | GivePlayerMoney(playerid,strval(inputtext)); | |
1131 | AtualCofre[playerid] = DOF2_GetInt(Emps,"Cofre"); | |
1132 | DOF2_SetInt(Emps,"Cofre",AtualCofre[playerid]-strval(inputtext)); | |
1133 | } | |
1134 | else SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FF0000}Sua empresa não possúi esta quantidade de lucros{FFFFFF}."); | |
1135 | } | |
1136 | } | |
1137 | if(dialogid == DIALOG_DELETAR_EMP) | |
1138 | { | |
1139 | if(response) | |
1140 | { | |
1141 | new Emps[64]; | |
1142 | format(Emps,sizeof(Emps),"Empresas/%d.ini",strval(inputtext)); | |
1143 | if(DOF2_FileExists(Emps)) | |
1144 | { | |
1145 | DOF2_RemoveFile(Emps); | |
1146 | RetirarEmps(); | |
1147 | CarregarEmps(); | |
1148 | SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {00ED04}A empresa foi removida com sucesso{FFFFFF}."); | |
1149 | } | |
1150 | else SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FF0000}Esta empresa não existe{FFFFFF}!"); | |
1151 | } | |
1152 | } | |
1153 | if(dialogid == DIALOG_INFOS_EMP) | |
1154 | { | |
1155 | if(response) | |
1156 | { | |
1157 | new Emps[64]; | |
1158 | format(Emps,sizeof(Emps),"Empresas/%d.ini",strval(inputtext)); | |
1159 | { | |
1160 | if(DOF2_FileExists(Emps)) | |
1161 | { | |
1162 | new str[400],str2[600]; | |
1163 | format(str,sizeof(str),"{00ED04}Esta empresa está localizada nas coordenadas:\nX: {FFFFFF}%f {00ED04}Y: {FFFFFF}%f {00ED04}Z: {FFFFFF}%f\n{00ED04}No valor de: R${FFFFFF}%d\n{00ED04}Com o interior conforme o ID: {FFFFFF}%d\n{00ED04}Com valor de extorção por entrada de: R${FFFFFF}",DOF2_GetFloat(Emps,"X"),DOF2_GetFloat(Emps,"Y"),DOF2_GetFloat(Emps,"Z"),DOF2_GetInt(Emps,"Valor"),DOF2_GetInt(Emps,"IDInterior")); strcat(str2,str); | |
1164 | format(str,sizeof(str),"%d\n{00ED04}Com modelo de pickup conforme ID: {FFFFFF}%d\n{00ED04}Com o nome da empresa: {FFFFFF}%s\n{00ED04}DONO da empresa: {FFFFFF}%s",DOF2_GetInt(Emps,"Extorcao"),DOF2_GetInt(Emps,"Pickup"),DOF2_GetString(Emps,"Nome"),DOF2_GetString(Emps,"DONO")); strcat(str2,str); | |
1165 | ShowPlayerDialog(playerid,DIALOG_INFOS_EMP_SHOW,DIALOG_STYLE_MSGBOX,"{FADD00}h{1F00CF}Emp{FFFFFF} - INFORMAÇÕES",str2,"FECHAR",""); | |
1166 | } | |
1167 | else SendClientMessage(playerid,-1,"{FFFFFF}[ ! ] {FF0000}Esta empresa não existe{FFFFFF}!"); | |
1168 | } | |
1169 | } | |
1170 | } | |
1171 | return 1; | |
1172 | } | |
1173 | ||
1174 | stock CarregarEmps() | |
1175 | { | |
1176 | new Emps[128],TxtEmp[256]; | |
1177 | for(new e = 0; e <= 999; ++e) | |
1178 | { | |
1179 | format(Emps,sizeof(Emps),"Empresas/%d.ini",e); | |
1180 | if(DOF2_FileExists(Emps)) | |
1181 | { | |
1182 | if(!strcmp(DOF2_GetString(Emps,"DONO"),"Nenhum",false)) | |
1183 | { | |
1184 | format(TxtEmp,sizeof(TxtEmp),"{26C2FF}EMPRESA\n{FADD00}Nome: {FFFFFF}%s\n{FADD00}ID: {FFFFFF}%d\n{FADD00}DONO: {FFFFFF}%s\n{FADD00}Extorção: {00ED04}R${FFFFFF}%d,00\n{00ED04}À VENDA! Use: {FFFFFF}/compraremp\n{FADD00}VALOR: R${FFFFFF}%d\n{26C2FF}F para entrar.",DOF2_GetString(Emps,"Nome"),DOF2_GetInt(Emps,"ID"),DOF2_GetString(Emps,"DONO"),DOF2_GetInt(Emps,"Extorcao"),DOF2_GetInt(Emps,"Valor")); | |
1185 | IDTextEmp[e] = Create3DTextLabel(TxtEmp,-1,DOF2_GetFloat(Emps,"X"),DOF2_GetFloat(Emps,"Y"),DOF2_GetFloat(Emps,"Z"),30.0,0); | |
1186 | EmpPickup[e] = CreatePickup(DOF2_GetInt(Emps,"Pickup"),23,DOF2_GetFloat(Emps,"X"),DOF2_GetFloat(Emps,"Y"),DOF2_GetFloat(Emps,"Z"),0); | |
1187 | } | |
1188 | else | |
1189 | { | |
1190 | format(TxtEmp,sizeof(TxtEmp),"{26C2FF}EMPRESA\n{FADD00}Nome: {FFFFFF}%s\n{FADD00}ID: {FFFFFF}%d\n{FADD00}DONO: {FFFFFF}%s\n{FADD00}Extorção: {00ED04}R${FFFFFF}%d,00\n \n{26C2FF}F para entrar.",DOF2_GetString(Emps,"Nome"),DOF2_GetInt(Emps,"ID"),DOF2_GetString(Emps,"DONO"),DOF2_GetInt(Emps,"Extorcao")); | |
1191 | IDTextEmp[e] = Create3DTextLabel(TxtEmp,-1,DOF2_GetFloat(Emps,"X"),DOF2_GetFloat(Emps,"Y"),DOF2_GetFloat(Emps,"Z"),30.0,0); | |
1192 | EmpPickup[e] = CreatePickup(DOF2_GetInt(Emps,"Pickup"),23,DOF2_GetFloat(Emps,"X"),DOF2_GetFloat(Emps,"Y"),DOF2_GetFloat(Emps,"Z"),0); | |
1193 | } | |
1194 | } | |
1195 | } | |
1196 | return 1; | |
1197 | } | |
1198 | ||
1199 | stock RetirarEmps() | |
1200 | { | |
1201 | for(new e = 0; e <= 999; ++e) | |
1202 | { | |
1203 | DestroyPickup(EmpPickup[e]); | |
1204 | Delete3DTextLabel(IDTextEmp[e]); | |
1205 | if(!IDTextEmp[e]) | |
1206 | { | |
1207 | break; | |
1208 | } | |
1209 | } | |
1210 | return 1; | |
1211 | } | |
1212 | ||
1213 | //=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- | |
1214 | //=-=-=-=-=-=-=-=-=-=-=-=-=-=[hEmp System - Criado e Desenvolvido por: HeyHoLetsGo]=-=-=-=-=-=-=-=-=-=-=-=-= | |
1215 | //=-=-=-=-=-=-=-=-=-=-=-=-=-=[Créditos ao Tonisaltolia por BETA Tester + Ajuda ]=-=-=-=-=-=-=-=-=-=-=-=-= | |
1216 | //=-=-=-=-=-=-=-=-=-=-=-=-=-=[Visite: forum.sa-mp.com | NÃO RETIRE OS CRÉDITOS! ]=-=-=-=-=-=-=-=-=-=-=-=-= | |
1217 | //=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- |