BlubBlab's Lyliya

Additional botting resources. Addons may be either for the game itself or for the RoM bot.
Forum rules
Only post additional bot resources here. Please do not ask unrelated questions.
Message
Author
Sasuke
Posts: 503
Joined: Mon May 17, 2010 3:40 pm
Location: Poland

Re: BlubBlab's Lyliya

#41 Post by Sasuke » Wed Nov 20, 2013 5:04 am

guys i have a problem in this minigame ....when i enter i activte the fly and when game start mt player speak with npc and srat,but only few seconds after i have an error with rombot ...i post it ty

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: BlubBlab's Lyliya

#42 Post by rock5 » Wed Nov 20, 2013 5:20 am

Read the first post. It tells you what the requirements are for this script.
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

wiedzmin97
Posts: 44
Joined: Wed Jul 03, 2013 1:37 pm

Re: BlubBlab's Lyliya

#43 Post by wiedzmin97 » Thu Dec 12, 2013 11:18 am

Is it possible to create this waypoint without swimhack and teleporthack? I' just afraid that i'll get ban :D

User avatar
Ego95
Posts: 564
Joined: Tue Feb 28, 2012 12:38 pm
Contact:

Re: BlubBlab's Lyliya

#44 Post by Ego95 » Thu Dec 12, 2013 3:37 pm

I think it would be possible, but the script would not be very reliable because there would be many objects the bot could get stuck. But you are right when thinking about a ban. GMs are looking very often into the minigames last time. I know about 4 people which were asked by a GM to remove their model file, while they ran through some objects or doors in minigames.

kuripot
Posts: 493
Joined: Mon Nov 07, 2011 9:14 pm

Re: BlubBlab's Lyliya

#45 Post by kuripot » Mon Dec 30, 2013 12:03 am

why next waypoint are not loaded when done in Lyliya

Code: Select all

<?xml version="1.0" encoding="utf-8"?>
<waypoints>
<onload>
	-- V1.0.8 by BlubBlab
	local When_Finished = "survivalR5"
	-- move the hammer to IS bag
	local movehammer   = true	
	
	
	
  local tablesize = 0
  local furniture = {}
  local objectList = nil
  local objSize = 0;
	

local function telelyliya()
	 local lyliz;
	repeat
			lyliyz = player:findNearestNameOrId(120993)
	until lyliyz ~= nil
	lylx = lyliyz.X
	lyly = lyliyz.Y
	lylz = lyliyz.Z
	teleport(lylx,lylz,lyly+15)
end
local function movetoBag()
	yrest(1000)
	inventory:update()
	item = inventory:findItem(201014,"bag")		
	if(item)then
		item:moveTo("itemshop")
	end
end
local function faceit()

		player:updateTargetPtr()
		local target = CPawn.new(player.TargetPtr)
		target:updateXYZ()
		local angle = math.atan2(target.Z - player.Z, target.X - player.X);
		local yangle = math.atan2(target.Y - player.Y, ((target.X - player.X)^2 + (target.Z - player.Z)^2)^.5 );
		player:faceDirection(angle, yangle);
		camera:setRotation(angle);
end
local proc = getProc()
local function checkcoordinate(obj)
	 for kb,vb in ipairs(furniture) do
		if(vb.Name == obj.Name and (1 > math.abs(obj.X - vb.X)  and 1 > math.abs (obj.Z - vb.Z)))then
			--if they have the same name and if their have the same coordinate from the original scan then skip it.
			return false;
		end
	 end
	 return true;
end
local function checkclicked(address)
	local tmp = memoryReadRepeat("int", proc, address + addresses.pawnAttackable_offset) or 0;
	if bitAnd(tmp,0x8) then
		return true
	else
		return false
	end
end
local function checkfading(address)
	return memoryReadRepeat("float", getProc(), address + addresses.pawnFading_offset) == 0
end

local function newOne(ID)
	local succesflag = false;
	local objectListK = CObjectList();
	objectListK:update();
	local objSize = objectListK:size()
	for i = 0,objSize do 
		local obj = objectListK:getObject(i)
		if(obj ~= nil)then
			obj:update()
			if (obj.Id == ID and checkclicked(obj.Address) and checkfading(obj.Address) ) then 
				if(checkcoordinate(obj)== true) then
					player:target(obj)
					faceit()
					RoMScript("UseExtraAction(1)")
					yrest(1000)	
					succesflag = true;
				end
			else
				if (obj.Id == ID)then
					return false;
				end
			end
		
			obj:update()
		end
	end
	return succesflag;
end
local function localize(myObject)
	print("Go to ".. myObject)
	local targetObject;	
	
	--targetObject = player:findNearestNameOrId(myObject)
	local objectListK = CObjectList();
	objectListK:update();
	local objSize = objectListK:size()
	for i = 0,objSize do 
		local obj = objectListK:getObject(i)
		if(obj ~= nil)then
			obj:update()
			if (obj.Name == myObject ) then 
				if(checkcoordinate(obj)== true) then
					targetObject = obj;
				end
			end
		end
	end
	
	if targetObject then
		targetObject:update();
		player:update()
		print("Object has coordinates :"..math.ceil(targetObject.X).." :"..math.ceil(targetObject.Z).." :"..math.ceil(targetObject.Y).."");
		local slowteleport = false;
		local x1 = targetObject.X - player.X
		local z1 = targetObject.Z - player.Z
		local y1 = targetObject.Y - player.Y
		
		local length = math.sqrt( math.pow(x1,2) + math.pow(z1,2))
		local fraction = (length-5)/length
		x1 = x1 * fraction
		z1 = z1 * fraction
		
		local x2 = x1 + player.X
		local z2 = z1 + player.Z
	
		if((targetObject.Y + 15) > (player.Y + 15))then
			local m = 1;
			while( distance(player.X, player.Z,player.Y, player.X, player.Z, targetObject.Y+15 ) > 2 ) do
				teleport(player.X,player.Z,targetObject.Y+15)
				if( m >= 3)then
					break;
				end
				m = m + 1;
				player:updateXYZ();
			end
			yrest(50)
			slowteleport = true;
		end
		
		local j = 1;
		-- I think 10 step are enough
		if( slowteleport == true)then
			local parts = 10
			local xpart = x1/parts;
			local zpart = z1/parts;
			local px = player.X
			local pz = player.Z
			local p = 1;
			-- so much vector calculations
			while ( (parts-1) > p) do
				teleport(((xpart *p) + px),((zpart *p ) + pz),targetObject.Y+20)
				yrest(150)
				p = p + 1;
				player:updateXYZ();
			end
		end
		player:updateXYZ();
		yrest(50)
		while( distance(player.X, player.Z,player.Y, x2, z2, targetObject.Y+15 ) > 2 ) do
			teleport(x2,z2,targetObject.Y+15)
			j = j + 1;
			if(j >= 5)then
				break;
			end
			yrest(50)
			player:updateXYZ();
		end
		if(distance(player.X, player.Z,player.Y, x2, z2, targetObject.Y+15 ) > 2)then
			player:moveTo( CWaypoint(x2, z2, targetObject.Y+15), true);
			if( distance(player.X, player.Z,player.Y, x2, z2, targetObject.Y+15 ) > 2)then
				teleport(x2,z2,targetObject.Y+15)
			end
		end
		player:updateXYZ();
		if(distance(player.X, player.Z,player.Y, x2, z2, targetObject.Y+15 ) > 2)then
			 print("Sorry object is too far away all efforts failed");
		else
			local z = 1;
			local i = 1;
			repeat
				if(newOne(targetObject.Id)== false)then
					i = i + 1;
				end
				if( i >= 3)then
					break;
				end
				if( z >= 5)then
					break;
				end
				z = z + 1;
			until not player:findNearestNameOrId(targetObject.Id)
		end
		if(	slowteleport == true)then
			teleport(nil,nil,targetObject.Y + 20)
			teleport(lylx,lylz,targetObject.Y + 20)
			yrest(50)
		end
		teleport(lylx,lylz,lyly + 15)
		yrest(50)
		player:updateXYZ();
		if( distance(player.X, player.Z,player.Y, lylx, lylz, lyly +15 ) > 2)then
			--we got stuck
			local py = player.Y;
			local counterb = 1;
			while( 15 > counterb )do
				teleport(nil, nil,py + counterb)
				counterb = counterb + 1;
			end
		end
		teleport(lylx,lylz,lyly +15)
   else
      print("not found!")
   end
end
local function memorize()

	repeat
		objectList = CObjectList();
		objectList:update();
		objSize = objectList:size()
	until objectList~=nil and objSize~=nil and objSize > 1
      for i = 0,objSize do
         local obj = objectList:getObject(i);
         obj:update()
         if obj.Name and obj.Name ~= "" and obj.Id ~= 120993 and obj.Id ~= 120992 and obj.Type == PT_NODE then
            print(obj.Name .." "..obj.Type.." ".. math.ceil(obj.X) .. " " .. math.ceil(obj.Z) .. " " .. math.ceil(obj.Y))
            table.insert(furniture, table.copy(obj))
            tablesize = tablesize + 1
         end
         player:update();
      end
end
local function takeaction()
	local tablesize2 = 0
	local furniture2 = {}
	 fly()
	repeat
		objectList:update();
		objSize = objectList:size()
	until objectList~=nil and objSize~=nil and objSize > 1
	
	for i = 0,objSize do
         local obj = objectList:getObject(i);
         obj:update()
         if obj.Name and obj.Name ~= "" and obj.Id ~= 120993 and obj.Id ~= 120992 and obj.Type == PT_NODE  then
            print(obj.Name .. " "..obj.Type.." " .. math.ceil(obj.X) .. " " .. math.ceil(obj.Z) .. " " .. math.ceil(obj.Y))
            table.insert(furniture2, table.copy(obj))
            tablesize2 = tablesize2 + 1
         end
         player:update();
	end
	print("Action")
	for ka,va in ipairs(furniture2) do
        local cc = 0
		local foundflag = false
         for kb,vb in ipairs(furniture) do
            cc=cc+1
            if va.Name == vb.Name then
               -- object was here and is here again
               print(va.Name)
               if 1 > math.abs(va.X - vb.X)  and 1 > math.abs (va.Z - vb.Z) then
                  -- it is on same position as before
				  foundflag = true
               else
					localize(va.Name)
					foundflag = true
                   break
				end
            end
			   
         end
		if(   foundflag == false)then
            localize(va.Name)
        end
		 
	end
	
	tablesize = 0
	tablesize2 = 0
	furniture = {}
	furniture2 = {}
	
end
local function mainroutine()
	while true do
	
		yrest(4500)
		print("Memorize room")
		memorize()
    
		repeat
			yrest(100)
		until RoMScript("TimeKeeperFrame:IsVisible()")
		
		yrest(1000)
		print("compare room")
		takeaction()
	
		repeat
			yrest(100)
		until not RoMScript("TimeKeeperFrame:IsVisible()")
		
		print("We go to lyliya")
		yrest(100)
		telelyliya()
		yrest(500)
		
		repeat
			yrest(100)
		until player:target_NPC(120993);
		yrest(500)
		if( RoMScript("GetNumSpeakOption()")> 2)then
			yrest(500)
			sendMacro("ChoiceOption(2);");
		else
			break;
		end
   end
end
	if getZoneId() == 2 then
		repeat
			yrest(100)
		until player:target_NPC(120992) or  player:target_NPC(120993) ;
		if(RoMScript("GetNumSpeakOption()") > 2)then
			sendMacro("ChoiceOption(2);");
		else
			sendMacro("ChoiceOption(1);");
		end
		waitForLoadingScreen(30);
	end
	if getZoneId() == 361  then
		 local lyliya;
		repeat
			lyliya = player:findNearestNameOrId(120993)
		until lyliya ~= nil
		lylx = lyliya.X
		lyly = lyliya.Y
		lylz = lyliya.Z
		teleport(lylx,lylz,lyly+15)
		yrest(500)
		print("Start game")
		repeat
			yrest(100)
		until player:target_NPC(120993);
		if(RoMScript("GetNumSpeakOption()")> 2)then
			sendMacro("ChoiceOption(2);");
			fly()
			mainroutine()
		else
			flyoff()
			
		end
	else
		flyoff()
	loadPaths("survivalR5")
	end
	
	
	flyoff()
	
	repeat
		yrest(100)
	until player:target_NPC(120993);
	sendMacro("ChoiceOption(1);");
	waitForLoadingScreen(30);
	repeat
		yrest(100)
	until player:target_NPC(120992) or  player:target_NPC(120993);
	if(movehammer)then
		movetoBag()
	end
</onload>
</waypoints>

User avatar
Ego95
Posts: 564
Joined: Tue Feb 28, 2012 12:38 pm
Contact:

Re: BlubBlab's Lyliya

#46 Post by Ego95 » Mon Dec 30, 2013 11:52 am

Maybe survivalr5 is in a subfolder?? I keep my minigame scripts in a subfolder called minigames. So I have to use "minigames/survivalR5

User avatar
L33t_Of_Lag
Posts: 38
Joined: Thu Jan 02, 2014 7:34 am

Re: BlubBlab's Lyliya

#47 Post by L33t_Of_Lag » Thu Jan 02, 2014 7:37 am

Hiya, have an error. Yes, i have all the required things to make this work.

The bot talks to girl, memorises, then i see rombot spam something (looks like coords) then an error stating something about XYZ.

Then of course, the script fails.

Any ideas?

cokebot
Posts: 54
Joined: Wed Oct 19, 2011 7:47 am

Re: BlubBlab's Lyliya

#48 Post by cokebot » Thu Jan 02, 2014 10:09 am

Great Waypoint, thank you.

Is it possible to stop the Waypoint after 6-7 rounds to get the transparent pearls?

User avatar
BlubBlab
Posts: 948
Joined: Fri Nov 30, 2012 11:33 pm
Location: My little Pony cafe

Re: BlubBlab's Lyliya

#49 Post by BlubBlab » Thu Jan 02, 2014 2:26 pm

@cokebot
By simply counting the main loop it should be possible make simple a break then
@L33t_Of_Lag
To help you I need to see the error message.
Jack-of-all-trades, but master-of-only of a few :D

My Reps:
https://github.com/BlubBlab/Micromacro-with-OpenCV (My version of MM2 with OpenCV and for MS Visual Studio)
https://github.com/BlubBlab/rom-bot (rombot with no stop WP and advanced human emulation mode and some other extensions)
https://github.com/BlubBlab/Micromacro-2-Bot-Framework ( A work in progress )
My Tools : viewtopic.php?f=10&t=6226

User avatar
L33t_Of_Lag
Posts: 38
Joined: Thu Jan 02, 2014 7:34 am

Re: BlubBlab's Lyliya

#50 Post by L33t_Of_Lag » Thu Jan 02, 2014 9:45 pm

Alright, after server reset ill screeny it

Braziliano
Posts: 82
Joined: Fri Apr 19, 2013 2:36 pm

Re: BlubBlab's Lyliya

#51 Post by Braziliano » Tue Jan 07, 2014 1:35 pm

Image

which line in the file do i have change/edit?

mark16
Posts: 4
Joined: Tue Jan 07, 2014 1:41 pm

Re: BlubBlab's Lyliya

#52 Post by mark16 » Tue Jan 07, 2014 1:53 pm

hey everyone its my 1st time using rombot & micromacro , i managed to run the bot and the script but the 1st error i got was the global 'teleport' nil value so i search again and i found a userfunction_teleport.lua by "Rock5" and i managed to start the waypoint of the minigame and then after the minigame started, it asked me about global 'fly' nil value so i did 1st round manually on my own and then i searched and found a swim hack lua file
i put with the other userfunction_teleport.lua folder but renamed it to "userfunction_fly.lua" and then i run the script again and the waypoint it didnt send any yellow error messages but all i can see is my character was going like 1 point higher up each second and then got error messages i took screenshots of all my micromacro messages. hope its something easy to fix and thanks in adavance.
Attachments
4.png
3.png
2.png
1.png

User avatar
BlubBlab
Posts: 948
Joined: Fri Nov 30, 2012 11:33 pm
Location: My little Pony cafe

Re: BlubBlab's Lyliya

#53 Post by BlubBlab » Tue Jan 07, 2014 6:32 pm

@Braziliano update your rombot
@mark16
I'm not sure what happening but it is so that sometimes it fail I wouldn't care so much about it you can have 1 fail and you will get still 100%, so long this happens not too often It's okay
Jack-of-all-trades, but master-of-only of a few :D

My Reps:
https://github.com/BlubBlab/Micromacro-with-OpenCV (My version of MM2 with OpenCV and for MS Visual Studio)
https://github.com/BlubBlab/rom-bot (rombot with no stop WP and advanced human emulation mode and some other extensions)
https://github.com/BlubBlab/Micromacro-2-Bot-Framework ( A work in progress )
My Tools : viewtopic.php?f=10&t=6226

mark16
Posts: 4
Joined: Tue Jan 07, 2014 1:41 pm

Re: BlubBlab's Lyliya

#54 Post by mark16 » Tue Jan 07, 2014 8:20 pm

BlubBlab wrote:@Braziliano update your rombot
@mark16
I'm not sure what happening but it is so that sometimes it fail I wouldn't care so much about it you can have 1 fail and you will get still 100%, so long this happens not too often It's okay
No mate , after it failed 1st,2nd and 3rd round to indentify even 1 furniture. i know i'm doing something wrong is it possible to send me ur userfunctions addons, and i removed all the skill from my profile since im using the bot only for this minigame.

User avatar
BlubBlab
Posts: 948
Joined: Fri Nov 30, 2012 11:33 pm
Location: My little Pony cafe

Re: BlubBlab's Lyliya

#55 Post by BlubBlab » Wed Jan 08, 2014 2:39 am

Those are my 2th version of teleport and swimhack. I don't think it make a big difference but you can try
Attachments
userfunction_teleport.lua
(3.25 KiB) Downloaded 271 times
userfunction_swimhack.lua
(888 Bytes) Downloaded 260 times
Jack-of-all-trades, but master-of-only of a few :D

My Reps:
https://github.com/BlubBlab/Micromacro-with-OpenCV (My version of MM2 with OpenCV and for MS Visual Studio)
https://github.com/BlubBlab/rom-bot (rombot with no stop WP and advanced human emulation mode and some other extensions)
https://github.com/BlubBlab/Micromacro-2-Bot-Framework ( A work in progress )
My Tools : viewtopic.php?f=10&t=6226

User avatar
Ego95
Posts: 564
Joined: Tue Feb 28, 2012 12:38 pm
Contact:

Re: BlubBlab's Lyliya

#56 Post by Ego95 » Wed Jan 08, 2014 7:25 am

Uhm. What are the differences to rock/lisas swim and teleport userfunction?

User avatar
BlubBlab
Posts: 948
Joined: Fri Nov 30, 2012 11:33 pm
Location: My little Pony cafe

Re: BlubBlab's Lyliya

#57 Post by BlubBlab » Wed Jan 08, 2014 7:51 am

Nothing but older. He has may temper with his and he requested them so I give it to him.
Jack-of-all-trades, but master-of-only of a few :D

My Reps:
https://github.com/BlubBlab/Micromacro-with-OpenCV (My version of MM2 with OpenCV and for MS Visual Studio)
https://github.com/BlubBlab/rom-bot (rombot with no stop WP and advanced human emulation mode and some other extensions)
https://github.com/BlubBlab/Micromacro-2-Bot-Framework ( A work in progress )
My Tools : viewtopic.php?f=10&t=6226

mark16
Posts: 4
Joined: Tue Jan 07, 2014 1:41 pm

Re: BlubBlab's Lyliya

#58 Post by mark16 » Fri Jan 10, 2014 9:45 pm

BlubBlab wrote:Nothing but older. He has may temper with his and he requested them so I give it to him.
Thank you so much just did it now, and completed all rounds without doing 1 single mistake , also i noticed that u made the script to put the hammer into the itemshop bag you are awesome.

thanks to you again and others who contribute.

User avatar
L33t_Of_Lag
Posts: 38
Joined: Thu Jan 02, 2014 7:34 am

Re: BlubBlab's Lyliya

#59 Post by L33t_Of_Lag » Thu Jan 16, 2014 9:16 pm

This has been asked by 2 people now with no response from anyone, so i'll ask again, because Dr Google can't seem to tell me.

What on earth are Lylia's Colorful Glass Bead for. Someone told me that you can trade them with her once you favourite is high, but for the life of me, can't seem to find out how to do so.

So, anyone know what to do with Lylia's Colorful Glass Bead?

ZZZZZ
Posts: 513
Joined: Sun Oct 21, 2012 1:42 am

Re: BlubBlab's Lyliya

#60 Post by ZZZZZ » Thu Jan 16, 2014 9:38 pm

Once you get 90 of the beads Lyliya gives another option that allows you to trade 30 beads for a random Xmasy furniture. Not sure but i think its 90 all up (of both types of beads) or could be 90 of either.

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot] and 8 guests