TarkFox Posted February 21, 2014 Posted February 21, 2014 hola, hoy descargue de la comunidad este panel https://community.multitheftauto.com/ind ... ls&id=8770 ahi dice que edite unas lineas de un archivo llamado staff.lua nose como se hacia pero intente como creia, los reportes llegan y todo bien pero no me abre el panel de administracion, me ayudan?? Staff.lua local staffTable = { --You can add admins manually here -- {"Account Name"}, --Eg. {"Kunal"}, } --=========================================Don't edit anything below this or you might break it=========================================-- local staffTeam = createTeam("Staff", 225, 225, 225) local unoccupiedTeam = createTeam("Unoccupied", 225, 225, 0) addEventHandler("onResourceStart", root, function() for i=1, #staffTable do local staffList = dbPoll(dbQuery(adminDB, "SELECT * FROM staffList WHERE staff=?", staffTable[i][1]), -1) if (#staffList == 0) then dbExec(adminDB, "INSERT INTO staffList(staff) VALUES(?)", staffTable[i][1]) end end end ) addEventHandler("onPlayerLogin", root, function() local staffName = dbPoll(dbQuery(adminDB, "SELECT * FROM staffList WHERE staff=?", getAccountName(getPlayerAccount(source))), -1) if (not (#staffName == 0)) then setElementData(source, "isPlayerStaff", true) outputChatBox("Logged In as admin", source, 225, 225, 225) end end ) addCommandHandler("gostaff", function(plr) local isStaff = getElementData(plr, "isPlayerStaff") if (isStaff) then setPlayerTeam(plr, getTeamFromName("Staff")) setElementModel(plr, 217) outputChatBox("Entered staff mode", plr, 225, 225, 225) else return end end )
Alexs Posted February 21, 2014 Posted February 21, 2014 Según la descripción de la comunidad solo debes añadir un valor nuevo a la tabla 'staffTable' con el nombre de tu cuenta, ¿lo hiciste?
TarkFox Posted February 21, 2014 Author Posted February 21, 2014 ahh si, ahi donde dice account name, si lo cambie y nada..
Alexs Posted February 21, 2014 Posted February 21, 2014 ahh si, ahi donde dice account name, si lo cambie y nada.. En las primeras lineas: local staffTable = { --You can add admins manually here -- {"Account Name"}, --Eg. {"Kunal"}, } Añades el nombre de tu cuenta, por ejemplo: local staffTable = { --You can add admins manually here -- {"Account Name"}, --Eg. {"Alexs_Steel"}, {"TarkFox"}, {"Fulano"} } Haría que las cuentas 'Alexs_Steel', 'TarkFox' y 'Fulano' pudiesen abrir el panel. *Luego de eso, debes iniciar el recurso y loggearte (en ese orden) para que los cambios afecten a tu cuenta.
TarkFox Posted February 21, 2014 Author Posted February 21, 2014 eso lo hise, pero no sirve habria otra solucion?
Alexs Posted February 21, 2014 Posted February 21, 2014 Cuando te loggeas, ¿aparece un mensaje diciendo 'Logged In as admin'?
TarkFox Posted February 21, 2014 Author Posted February 21, 2014 EXELENTE BRO, ahora si me funciono gracias :D
Alexs Posted February 21, 2014 Posted February 21, 2014 EXELENTE BRO, ahora si me funciono gracias :D Vale, espero que algún día me aclares que fue lo que hice.
Recommended Posts