Register for your free account! | Forgot your password?

You last visited: Today at 19:24

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[Mini-Release] LUA Orakel

Discussion on [Mini-Release] LUA Orakel within the Metin2 PServer Guides & Strategies forum part of the Metin2 Private Server category.

Reply
 
Old   #1

 
elite*gold: 83
Join Date: Nov 2013
Posts: 2,891
Received Thanks: 2,765
[Mini-Release] LUA Orakel

Vielleicht kann es ja jemand gebrauchen

Code:
local question_data = {
	[{"WER", "HAT", "WELT", "ERSCHAFFEN"}] = "LUA"
}

function get_answer(question, minequal)
	local minequal = minequal or 100
	local question = string.upper(question)
	for keywords,answer in pairs(question_data) do
		local equalcount = 0
		for _,keyword in ipairs(keywords) do
			if string.find(question, keyword) then
				equalcount = equalcount+1
			end
		end
		if equalcount >= (table.getn(keywords)/100*minequal) then
			return answer
		end
	end
	return "Ich konnte keine Antwort finden. (PS: LUA hat die Welt erschaffen)"
end

print(get_answer("LUA, bitte sage mir, wer hat die Welt erschaffen?"))
--> LUA

print(get_answer("LUA, bitte sage mir, wer hat die Welt?", 50))
--> LUA

print(get_answer("LUA, bitte sage mir, wer hat die Welt?", 76))
--> Ich konnte keine Antwort finden. (PS: LUA hat die Welt erschaffen)
rollback is offline  
Thanks
6 Users
Old   #2
 
elite*gold: 0
Join Date: Jun 2015
Posts: 98
Received Thanks: 225
Ich faste um Lua zu preisen.
Für Lua sterbe ich auch gerne an einer Hitzewelle.
[Remix] is offline  
Thanks
5 Users
Old   #3
 
DasSchwarzeT's Avatar
 
elite*gold: 399
Join Date: Sep 2011
Posts: 5,323
Received Thanks: 3,937
local question_data = {
[{"SINNVOLL", "RELEASE", "DAS", "IST"}] = "Nein"
}
print(get_answer("Ist das Release sinnvoll?"))
--> Nein

Danke für das sinnvolle Release!
DasSchwarzeT is offline  
Thanks
6 Users
Old   #4
 
Yiv's Avatar
 
elite*gold: 47
Join Date: Feb 2012
Posts: 2,282
Received Thanks: 2,579
Ok.
Danke.
Yiv is offline  
Thanks
1 User
Old   #5
 
nybu's Avatar
 
elite*gold: 0
Join Date: May 2011
Posts: 2,806
Received Thanks: 8,536
Coole Quest aber schlechte Schleife.
Eigentlich poste ich hier nur um Thanks zu bekommen
nybu is offline  
Thanks
11 Users
Old   #6
 
Alekos's Avatar
 
elite*gold: 6
The Black Market: 125/0/0
Join Date: Feb 2010
Posts: 2,779
Received Thanks: 4,267
Quote:
Originally Posted by nybυ View Post
Coole Quest aber schlechte Schleife.
Hat er diesmal ohne meine Hilfe versucht, sieht man ja wie das in die Hose geht.
Trotzdem danke für deine Mühe
Alekos is offline  
Thanks
3 Users
Old   #7
 
iYoshix3's Avatar
 
elite*gold: 0
Join Date: Jun 2010
Posts: 1,264
Received Thanks: 2,021
Statt dem break könntest du noch eine %ige Wahrscheinlichkeit prüfen, um auch bei
10 von 11 Treffern eine Lösung bieten zu können

Mfg,
Yoshix3
iYoshix3 is offline  
Thanks
1 User
Old   #8

 
elite*gold: 83
Join Date: Nov 2013
Posts: 2,891
Received Thanks: 2,765
Quote:
Originally Posted by iYoshix3 View Post
Statt dem break könntest du noch eine %ige Wahrscheinlichkeit prüfen, um auch bei
10 von 11 Treffern eine Lösung bieten zu können

Mfg,
Yoshix3
Gemacht
rollback is offline  
Old   #9
 
Fydes's Avatar
 
elite*gold: 0
Join Date: Mar 2014
Posts: 1,620
Received Thanks: 984



Gutes Release, danke.
Fydes is offline  
Thanks
5 Users
Reply


Similar Threads Similar Threads
[Mini-Mini-Release] Balkit Textur für Wordeditor etc.
03/05/2015 - Metin2 PServer Guides & Strategies - 3 Replies
closed
[Mini-Release] Mini Grinder-Helper + Source
09/03/2014 - Aion Hacks, Bots, Cheats & Exploits - 8 Replies
Hi everyone, just made a small Mini-Tool in C# that displays XP,HP,MP and a small information (if XP changed between 2 update-rates) how much repeats are needed for lvl up. XP,TP,MP are also given in Progressbars. E.G.: You are doing repeatables for leveling, this shows at finishing quests, the amount, of how often u would need to finish it again until level up. I also give you the current sourcecode of this mini-tool. .Net-Version: 4.5 Visual-Studio-Version: Visual Studio 2013 Also...
[mini mini Release] Warning for IE for heni script
09/19/2011 - Metin2 PServer Guides & Strategies - 14 Replies
this is nothing special I just i see a lots of people have troubles with the Internet Explorer browser on the almost all HP have be release on epvp so i will explain a bether way to warning the user he is using the internet explorer and you recomend use firefox or chrone without using enterpage 1 put this code inside the <head> </head> tag <!--> <script type="text/javascript">



All times are GMT +1. The time now is 19:25.


Powered by vBulletin®
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2026 elitepvpers All Rights Reserved.