Discussione [HELP]war tra regni e war tra gilde

Stato
Discussione chiusa ad ulteriori risposte.

suoch

Utente Emerald
7 Novembre 2011
452
51
163
363
cerco una persona k mi da una mano a sbuggare le war tra regni e war tra gilde pls . +1 garantito
contatto skype ern00b
 
Codice:
quest threeway_war begin	
	state start begin
	
			when kill with pc.get_map_index() == "103" begin


			if game.get_event_flag("threeway_war_kill_count1") == game.get_event_flag("threeway_war_kill_count") or game.get_event_flag("threeway_war_kill_count2") == game.get_event_flag("threeway_war_kill_count") or game.get_event_flag("threeway_war_kill_count3") == game.get_event_flag("threeway_war_kill_count") then


				notice_all("La guerra si è conclusa con un pareggio!")


			end


			if npc.is_pc() and npc.get_empire != pc.get_empire() then


				game.set_event_flag("threeway_war_kill_count"..pc.get_empire(), game.get_event_flag("threeway_war_kill_count"..pc.get_empire()) + 1)
				notice_all("Attuale punteggio: Shinsoo "..game.get_event_flag("threeway_war_kill_count1").."[ENTER]Chunjo "..game.get_event_flag("threeway_war_kill_count2").."[ENTER]Jinno "..game.get_event_flag("threeway_war_kill_count3").."")


					if game.get_event_flag("threeway_war_kill_count1") == game.get_event_flag("threeway_war_kill_count") then


					notice_all("Shinsoo ha vinto la guerra!")


					elseif game.get_event_flag("threeway_war_kill_count2") == game.get_event_flag("threeway_war_kill_count") then


					notice_all("Chunjo ha vinto la guerra!")


					elseif game.get_event_flag("threeway_war_kill_count3") == game.get_event_flag("threeway_war_kill_count") then


					notice_all("Jinno ha vinto la guerra!")


					end


			end


		end
			
		when 11001.chat."GM - Guerra Tra Regni" or 11003.chat."GM - Guerra Tra Regni" or 11005.chat."GM - Guerra Tra Regni" with pc.is_gm() begin
		
		sel = select ("Attiva", "Disattiva", "Esci")


		if sel == 1 then


		notice_all("Oggi si svolge l'evento: Guerra Tra Regni!")
		notice_all("Parlate con L'admin battaglie per entrare nella guerra tra regni!")


		rand = math.random(1, 3)


		if rand == 1 then


			game.set_event_flag("war_regni", 1)


		elseif rand == 2 then


			game.set_event_flag("war_regni", 2)


		elseif rand == 3 then


			game.set_event_flag("war_regni", 3)


		end
		
			game.set_event_flag("threeway_war", 1)
			game.set_event_flag("threeway_war_dead_count", 5)
			game.set_event_flag("threeway_war_mob_count", 150)
			game.set_event_flag("threeway_war_kill_count", 200)
			game.set_event_flag("threeway_war_kill_count1", 0)
			game.set_event_flag("threeway_war_kill_count2", 0)
			game.set_event_flag("threeway_war_kill_count3", 0)
			game.set_event_flag("threeway_war_kill_boss_count", 1)
			game.set_event_flag("threeway_war_open_gate1", 1)
			game.set_event_flag("threeway_war_open_gate2", 1)
			game.set_event_flag("threeway_war_open_gate3", 1)


		elseif sel == 2 then
		
			game.set_event_flag("threeway_war",0)
			notice_all("Evento Guerra Tra Regni disattivato")
			
			MAPPA_ATTUALE = pc.get_map_index()
			REGNO = pc.get_empire()
			
			MAPPA1_WAR_REGNI_INDEX = "181"
			MAPPA2_WAR_REGNI_INDEX = "182"
			MAPPA3_WAR_REGNI_INDEX = "183"
			
			MAPPA_FINALE = "t1"
			
			if MAPPA_ATTUALE == MAPPA1_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA2_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA3_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA_FINALE and REGNO == 1 then


				forked.warp_all_in_map(MAPPA_ATTUALE, 1, 409600, 896000, 10);
		
			elseif MAPPA_ATTUALE == MAPPA1_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA2_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA3_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA_FINALE and REGNO == 2 then
		
				forked.warp_all_in_map(MAPPA_ATTUALE, 21, 0, 102400, 10);
			
			elseif MAPPA_ATTUALE == MAPPA1_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA2_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA3_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA_FINALE and REGNO == 3 then


				forked.warp_all_in_map(MAPPA_ATTUALE, 41, 921600, 204800, 10);
			
			end
			
		elseif sel == 3 then


		return
			
		end
		
		end
	
			when 11001.chat."Guerra Tra Regni" or 11003.chat."Guerra Tra Regni" or 11005.chat."Guerra Tra Regni" with game.get_event_flag("threeway_war") == 1 begin
		
				say_title("Guerra Tra Regni")
				say("Ciao!")
				say("Sei pronto ad affrontare questa grande battaglia?!")
				say("Allora vieni?")
				
				sel = select("Si","No!")
				
				if sel == 1 then
			
				if pc.get_level() < 50 then
				say("Non sei al livello giusto.Torna quando sarai al 50!");
				return
				end
				
				if pc.get_empire() == 1 then
					if game.get_event_flag("threeway_war_open_gate1" ) == 0 then
						say("In questo momento non puoi entrare, devi aspettare!" );
					end
				elseif pc.getempire() == 2 then
					if game.get_event_flag("threeway_war_open_gate2" ) == 0 then
						say("In questo momento non puoi entrare, devi aspettare!" );
					end
				elseif pc.getempire() == 3 then
					if game.get_event_flag("threeway_war_open_gate3" ) == 0 then
						say("In questo momento non puoi entrare, devi aspettare!" );
					end
				else
					say("Guerra tra regni non attiva!")
				end
				
				mappa = game.get_event_flag("war_regni")
				regno = pc.get_empire()
				
				if mappa == 1 then
				
				-- MAPPA 1 GUERRA TRA REGNI --
				
				cord_rossi="974900"
				cord2_rossi="134300"
				
				cord_gialli="976600"
				cord2_gialli="149100"
				
				cord_blu="1019200"
				cord2_blu="149100"
				
				if regno == 1 then
				
					pc.warp(cord_rossi, cord2_rossi)
					
				elseif regno == 2 then
				
					pc.warp(cord_gialli, cord2_gialli)
					
				elseif regno == 3 then
				
					pc.warp(cord_blu, cord2_blu)
					
				end
				
				
				elseif mappa == 2 then
				
				-- MAPPA 2 GUERRA TRA REGNI --
				
				cord_rossi="923700"
				cord2_rossi="185000"
				
				cord_gialli="925900"
				cord2_gialli="199500"
				
				cord_blu="967500"
				cord2_blu="200700"
				
				if regno == 1 then
				
					pc.warp(cord_rossi, cord2_rossi)
					
				elseif regno == 2 then
				
					pc.warp(cord_gialli, cord2_gialli)
					
				elseif regno == 3 then
				
					pc.warp(cord_blu, cord2_blu)
					
				end
				
				elseif mappa == 3 then
				
				-- MAPPA 3 GUERRA TRA REGNI --
				
				cord_rossi="976800"
				cord2_rossi="185300"
				
				cord_gialli="978600"
				cord2_gialli="199600"
				
				cord_blu="1019100"
				cord2_blu="199300"
				
				if regno == 1 then
				
					pc.warp(cord_rossi, cord2_rossi)
					
				elseif regno == 2 then
				
					pc.warp(cord_gialli, cord2_gialli)
					
				elseif regno == 3 then
				
					pc.warp(cord_blu, cord2_blu)
					
				end
				
				end


				elseif sel == 2 then
					
					return
					
				end
				
			end


			
		when 1306.kill with game.get_event_flag("threeway_war") == 1 begin


			if pc.get_map_index() == 181 or pc.get_map_index() == 182 or pc.get_map_index() == 183 then
			
			regno = pc.get_empire()
			
				if regno == 1 then
				
					set_state("teleporta_rossi")
					
				elseif regno == 2 then
				
					set_state("teleporta_gialli")
					
				elseif regno == 3 then
				
					set_state("teleporta_blu")
				
				end
			
			end
			
		end
		
	end
		
		state teleporta_rossi begin
		
			pc.warp(47000, 45000)
		
		end
		
		state teleporta_gialli begin
		
			pc.warp(20500, 55700)
		
		end
		
		state teleporta_blu begin
		
			pc.warp(45400, 83500)
		
		end


end

Ecco la war tra regni :D

Salva tutto in un file chiamato threeway_war.quest
 
Codice:
quest threeway_war begin    
    state start begin
    
            when kill with pc.get_map_index() == "103" begin


            if game.get_event_flag("threeway_war_kill_count1") == game.get_event_flag("threeway_war_kill_count") or game.get_event_flag("threeway_war_kill_count2") == game.get_event_flag("threeway_war_kill_count") or game.get_event_flag("threeway_war_kill_count3") == game.get_event_flag("threeway_war_kill_count") then


                notice_all("La guerra si è conclusa con un pareggio!")


            end


            if npc.is_pc() and npc.get_empire != pc.get_empire() then


                game.set_event_flag("threeway_war_kill_count"..pc.get_empire(), game.get_event_flag("threeway_war_kill_count"..pc.get_empire()) + 1)
                notice_all("Attuale punteggio: Shinsoo "..game.get_event_flag("threeway_war_kill_count1").."[ENTER]Chunjo "..game.get_event_flag("threeway_war_kill_count2").."[ENTER]Jinno "..game.get_event_flag("threeway_war_kill_count3").."")


                    if game.get_event_flag("threeway_war_kill_count1") == game.get_event_flag("threeway_war_kill_count") then


                    notice_all("Shinsoo ha vinto la guerra!")


                    elseif game.get_event_flag("threeway_war_kill_count2") == game.get_event_flag("threeway_war_kill_count") then


                    notice_all("Chunjo ha vinto la guerra!")


                    elseif game.get_event_flag("threeway_war_kill_count3") == game.get_event_flag("threeway_war_kill_count") then


                    notice_all("Jinno ha vinto la guerra!")


                    end


            end


        end
            
        when 11001.chat."GM - Guerra Tra Regni" or 11003.chat."GM - Guerra Tra Regni" or 11005.chat."GM - Guerra Tra Regni" with pc.is_gm() begin
        
        sel = select ("Attiva", "Disattiva", "Esci")


        if sel == 1 then


        notice_all("Oggi si svolge l'evento: Guerra Tra Regni!")
        notice_all("Parlate con L'admin battaglie per entrare nella guerra tra regni!")


        rand = math.random(1, 3)


        if rand == 1 then


            game.set_event_flag("war_regni", 1)


        elseif rand == 2 then


            game.set_event_flag("war_regni", 2)


        elseif rand == 3 then


            game.set_event_flag("war_regni", 3)


        end
        
            game.set_event_flag("threeway_war", 1)
            game.set_event_flag("threeway_war_dead_count", 5)
            game.set_event_flag("threeway_war_mob_count", 150)
            game.set_event_flag("threeway_war_kill_count", 200)
            game.set_event_flag("threeway_war_kill_count1", 0)
            game.set_event_flag("threeway_war_kill_count2", 0)
            game.set_event_flag("threeway_war_kill_count3", 0)
            game.set_event_flag("threeway_war_kill_boss_count", 1)
            game.set_event_flag("threeway_war_open_gate1", 1)
            game.set_event_flag("threeway_war_open_gate2", 1)
            game.set_event_flag("threeway_war_open_gate3", 1)


        elseif sel == 2 then
        
            game.set_event_flag("threeway_war",0)
            notice_all("Evento Guerra Tra Regni disattivato")
            
            MAPPA_ATTUALE = pc.get_map_index()
            REGNO = pc.get_empire()
            
            MAPPA1_WAR_REGNI_INDEX = "181"
            MAPPA2_WAR_REGNI_INDEX = "182"
            MAPPA3_WAR_REGNI_INDEX = "183"
            
            MAPPA_FINALE = "t1"
            
            if MAPPA_ATTUALE == MAPPA1_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA2_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA3_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA_FINALE and REGNO == 1 then


                forked.warp_all_in_map(MAPPA_ATTUALE, 1, 409600, 896000, 10);
        
            elseif MAPPA_ATTUALE == MAPPA1_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA2_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA3_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA_FINALE and REGNO == 2 then
        
                forked.warp_all_in_map(MAPPA_ATTUALE, 21, 0, 102400, 10);
            
            elseif MAPPA_ATTUALE == MAPPA1_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA2_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA3_WAR_REGNI_INDEX or MAPPA_ATTUALE == MAPPA_FINALE and REGNO == 3 then


                forked.warp_all_in_map(MAPPA_ATTUALE, 41, 921600, 204800, 10);
            
            end
            
        elseif sel == 3 then


        return
            
        end
        
        end
    
            when 11001.chat."Guerra Tra Regni" or 11003.chat."Guerra Tra Regni" or 11005.chat."Guerra Tra Regni" with game.get_event_flag("threeway_war") == 1 begin
        
                say_title("Guerra Tra Regni")
                say("Ciao!")
                say("Sei pronto ad affrontare questa grande battaglia?!")
                say("Allora vieni?")
                
                sel = select("Si","No!")
                
                if sel == 1 then
            
                if pc.get_level() < 50 then
                say("Non sei al livello giusto.Torna quando sarai al 50!");
                return
                end
                
                if pc.get_empire() == 1 then
                    if game.get_event_flag("threeway_war_open_gate1" ) == 0 then
                        say("In questo momento non puoi entrare, devi aspettare!" );
                    end
                elseif pc.getempire() == 2 then
                    if game.get_event_flag("threeway_war_open_gate2" ) == 0 then
                        say("In questo momento non puoi entrare, devi aspettare!" );
                    end
                elseif pc.getempire() == 3 then
                    if game.get_event_flag("threeway_war_open_gate3" ) == 0 then
                        say("In questo momento non puoi entrare, devi aspettare!" );
                    end
                else
                    say("Guerra tra regni non attiva!")
                end
                
                mappa = game.get_event_flag("war_regni")
                regno = pc.get_empire()
                
                if mappa == 1 then
                
                -- MAPPA 1 GUERRA TRA REGNI --
                
                cord_rossi="974900"
                cord2_rossi="134300"
                
                cord_gialli="976600"
                cord2_gialli="149100"
                
                cord_blu="1019200"
                cord2_blu="149100"
                
                if regno == 1 then
                
                    pc.warp(cord_rossi, cord2_rossi)
                    
                elseif regno == 2 then
                
                    pc.warp(cord_gialli, cord2_gialli)
                    
                elseif regno == 3 then
                
                    pc.warp(cord_blu, cord2_blu)
                    
                end
                
                
                elseif mappa == 2 then
                
                -- MAPPA 2 GUERRA TRA REGNI --
                
                cord_rossi="923700"
                cord2_rossi="185000"
                
                cord_gialli="925900"
                cord2_gialli="199500"
                
                cord_blu="967500"
                cord2_blu="200700"
                
                if regno == 1 then
                
                    pc.warp(cord_rossi, cord2_rossi)
                    
                elseif regno == 2 then
                
                    pc.warp(cord_gialli, cord2_gialli)
                    
                elseif regno == 3 then
                
                    pc.warp(cord_blu, cord2_blu)
                    
                end
                
                elseif mappa == 3 then
                
                -- MAPPA 3 GUERRA TRA REGNI --
                
                cord_rossi="976800"
                cord2_rossi="185300"
                
                cord_gialli="978600"
                cord2_gialli="199600"
                
                cord_blu="1019100"
                cord2_blu="199300"
                
                if regno == 1 then
                
                    pc.warp(cord_rossi, cord2_rossi)
                    
                elseif regno == 2 then
                
                    pc.warp(cord_gialli, cord2_gialli)
                    
                elseif regno == 3 then
                
                    pc.warp(cord_blu, cord2_blu)
                    
                end
                
                end


                elseif sel == 2 then
                    
                    return
                    
                end
                
            end


            
        when 1306.kill with game.get_event_flag("threeway_war") == 1 begin


            if pc.get_map_index() == 181 or pc.get_map_index() == 182 or pc.get_map_index() == 183 then
            
            regno = pc.get_empire()
            
                if regno == 1 then
                
                    set_state("teleporta_rossi")
                    
                elseif regno == 2 then
                
                    set_state("teleporta_gialli")
                    
                elseif regno == 3 then
                
                    set_state("teleporta_blu")
                
                end
            
            end
            
        end
        
    end
        
        state teleporta_rossi begin
        
            pc.warp(47000, 45000)
        
        end
        
        state teleporta_gialli begin
        
            pc.warp(20500, 55700)
        
        end
        
        state teleporta_blu begin
        
            pc.warp(45400, 83500)
        
        end


end

Ecco la war tra regni :D

Salva tutto in un file chiamato threeway_war.quest

Upp !!!!!!!!!!

A me dà il seguente errore:
STATE : teleporta_rossi
expecting 'when' or 'function'
threeway_war.quest:298:Abort (core dumped)
come risolvo? (+1)
 
Stato
Discussione chiusa ad ulteriori risposte.
Indietro
Top Bottom