Jump to content

peri200

Miembro
  • Contador contenido

    84
  • Ingreso

  • Última visita

  • Días ganados

    2

Mensajes publicados por peri200

  1. tras implementar la itemshop de sema resulta que funciona perfecta pero al crear un nuevo value que requiere el register.php deja de funcionar

     

    necesito que algien me edite el register.php para que acepte el nuevo value y funcione

     

    es urgente porfavor

     

    Debes iniciar sesión para ver el contenido del enlace en esta publicación.
    !FlQcdPs7hgDxW9SYE1cYcp95PSF7ZYqr7izjx7bI0Y4

     

    : ALTER TABLE account ADD drs int NOT NULL

     

    esa es la query como veis se llama drs

  2.  

    Aquí está una quest de blackyuyo:

     

    Está quest lo que hace es crear un archivo txt con el nombre del jugador que ha enviado el reporte, la fecha y su mensaje. El archivo se crea usr/home/game/share/locale/spain(germany, etc)/quest/bug_report/

     

    Quest

    quest gm_inform begin
    	state start begin
    	when login begin
    		set_state(information)
    	end
    end
    	state information begin
    		when letter begin
    			send_letter("Reporta un informe")
    		end		
    		when button or info begin
    			say_title("Reportar un informe")
    			say_reward("Atención: Tu nombre será guardado[ENTER]")
    			say ("Quieres informar de un algo?[ENTER]")
    			local s = select ("Si", "No")
    			if s == 2 then
    				return
    			end
    			local max_rows = 20
    			local row_n = 1
    			local bug_mex = ""
    			local stop = false
    			-- Read all rows
    			repeat
    				say_title("Reportar informe - Linea "..row_n.." / "..max_rows)
    				say("Por favor, haz una descripción detallada")
    				say("del informe:[ENTER]")
    				local line = input()
    				say_title("Reportar informe - Linea "..row_n.." / "..max_rows)
    				if string.len(line) < 4 then
    					-- Row too short
    					say("Has insertado un texto demasiado corto.[ENTER]")
    					if row_n == 1 then
    						wait()
    					else
    						local s = select("Continuar", "Enviar reporte")
    						if s == 2 then
    							stop = true
    						end
    					end
    				else
    					-- Next line
    					bug_mex = bug_mex..NEW_LINE_FILE..line
    					row_n = row_n+1
    					if row_n == max_rows then
    						say("Has realizado el reporte con éxito.[ENTER]")
    						wait()
    						stop = true
    					else
    						say("Deseas escribir más lineas?[ENTER]")
    						local s = select("Si", "No")
    						if s == 2 then
    							stop = true
    						end
    					end
    				end
    			until stop	
    			-- Finsh reading rows
    			say_title("Reportes")
    			if (BugReport.Report(bug_mex)) then
    				say("Tu reporte se ha enviado correctamente[ENTER]")
    			else
    				say("Ha ocurrido un error al enviar el reporte.")
    				say("Prueba más tarde.[ENTER]")
    			end
    		end	-- when
    	end	-- state
    end	-- quest
    
    

    Questlib.lua

    --**
    --** Report functions
    --**
    BugReport = {['Folder'] = get_locale_base_path().."/quest/bug_report/"}
    
    --** Write bug report to file
    function BugReport.Report(bug_message)
    	local written = false
    	local new_count = BugReport.Count.Update()
    	local file_name = BugReport.Folder..pc.get_name().."_"..new_count..".txt"
    	local file = io.open(file_name, "w")
    	if file != nil then
    		written = true
    		file:write("Personaje: "..pc.get_name().." (PID: "..pc.get_player_id()..")\n")
    		file:write("Fecha: "..os.date("%d/%m/%Y - Ore: %H:%M").."\n")
    		file:write("Mensaje:\n")
    		file:write(bug_message.."\n")
    		file:close()
    	end
    	return written
    end
    
    --** Bug count handling
    BugReport.Count = {['Flag'] = "bug_count"}
    
    --** Get the bug count for a player
    function BugReport.Count.Get()
    	return pc.getqf(BugReport.Count.Flag)
    end
    
    --** Set the bug count for a player
    function BugReport.Count.Set(new_count)
    	pc.setqf(BugReport.Count.Flag, new_count)
    end
    
    --** Update bug count for a player
    function BugReport.Count.Update()
    	local new_count = BugReport.Count.Get()+1
    	BugReport.Count.Set(new_count)
    	return new_count
    end
    
    

     

    gracias :D

  3. Alguien lo ha probado? Me gustaria saber si aun funciona con las nuevas bases de datos.

     

    Estoy intentando mirar haber como se puede realizar un backup de toda la base de datos, es un lio hacerlo, de manera que consuma pocos recursos hacerlo y no necesite mucho tiempo. Programo con xampp en localhost, y no tengo una base de datos de un servidor funcionando para probarlo, ya que se generan bases de datos tranquilamente de 500mb, asi que voy a ciegas.

     

    Que funciones mas estarian bien añadir?

     

    no funciona en 40k ya que no es por sql si no text xd

×
×
  • Crear nuevo...