auto-open gift bag on level?

Runes of Magic/Radiant Arcana (http://www.runesofmagic.com)
Post Reply
Message
Author
imartynasi
Posts: 19
Joined: Thu Sep 10, 2009 8:32 am

auto-open gift bag on level?

#1 Post by imartynasi » Thu Sep 10, 2009 1:07 pm

hello, im asking if its possible to set, when u level up it will auto open a gift bag.

d003232
Posts: 1252
Joined: Wed Jun 03, 2009 4:27 pm

Re: auto-open gift bag on level?

#2 Post by d003232 » Thu Sep 10, 2009 3:54 pm

imartynasi wrote:hello, im asking if its possible to set, when u level up it will auto open a gift bag.
Yes. Update to the current SVN version. There is a demo profile 'l1-10.xml'. There you find:

Code: Select all

	<onLeaveCombat>

		-- thats a demo for opening the gift bags from Lvl 1-10
		-- and levelup the skills for a new mage character
		-- you can delete that lines

		if( player.Level > player.free_counter1) then
			player.free_counter1 = player.Level;

			-- open giftbag and equipt content
			-- updates first 18 bag slots / update all if empty
			openGiftbag(player.Level, 18);

			-- levelup skills
			-- mage: 4 = third skill tab, 2 = mage flame
			-- priest: 2,1 (rising tide) 2,2 (urgent heal)
			-- CAUTION: addressing a invalid skill will crash the RoM client
			if(player.Class1 == CLASS_MAGE) then
				if(	player.Level == 2 ) then
					sendMacro("SetSpellPoint( 4, 2 );");
					yrest(1000);
					sendMacro("SetSpellPoint( 4, 2 );");
				else
					player.free_counter1 = player.Level;
					sendMacro("SetSpellPoint( 4, 2 );");
				end
			end

		end
The

Code: Select all

openGiftbag(player.Level, 18);
function is just beta. It is only complete for level 1-10 and at the moment only for 'cloth' classes (mage, priest). The database file 'giftbags.xml' have to be filled for other classes and the class depending coding lacks.
The RoM Bot Online Wiki needs your help!

d003232
Posts: 1252
Joined: Wed Jun 03, 2009 4:27 pm

Re: auto-open gift bag on level?

#3 Post by d003232 » Thu Sep 10, 2009 6:40 pm

Code: Select all

openGiftbag();
now works for all classes from lvl 1 - 10.
The RoM Bot Online Wiki needs your help!

imartynasi
Posts: 19
Joined: Thu Sep 10, 2009 8:32 am

Re: auto-open gift bag on level?

#4 Post by imartynasi » Fri Sep 11, 2009 3:33 am

i had updated with SVN, but then bot not worked for me, so i downloaded and replaced everything, and now works without SVN

User avatar
droppen
Posts: 179
Joined: Mon Aug 03, 2009 10:32 pm

Re: auto-open gift bag on level?

#5 Post by droppen » Sun Sep 13, 2009 3:09 am

d003232 wrote:

Code: Select all

openGiftbag();
now works for all classes from lvl 1 - 10.
I think openGiftbag(); should be inventory:openGiftbag() since its an inventory function, don't you think?

d003232
Posts: 1252
Joined: Wed Jun 03, 2009 4:27 pm

Re: auto-open gift bag on level?

#6 Post by d003232 » Sun Sep 13, 2009 3:33 am

droppen wrote:
d003232 wrote:

Code: Select all

openGiftbag();
now works for all classes from lvl 1 - 10.
I think openGiftbag(); should be inventory:openGiftbag() since its an inventory function, don't you think?
Yes. That would be a good idea. I suppose users will ask to open higher level gift bags too. If we move it ... and if we add giftbags greater lvl 10, then we should add a option to only open the bag and not to eqipt something. Now the function is very specialiced in supporting the automatic leveling from 1-10.
The RoM Bot Online Wiki needs your help!

d003232
Posts: 1252
Joined: Wed Jun 03, 2009 4:27 pm

Re: auto-open gift bag on level?

#7 Post by d003232 » Sun Sep 13, 2009 4:15 am

I now renamed openGiftbag() to openGiftbags1To10(), to prepare the creation of a general inventory:openGiftbag and to make clear, that openGiftbags1To10 is something special.

So we can change/create the function inventory:openGiftbag later without disturbing the users.
The RoM Bot Online Wiki needs your help!

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot], Bing [Bot] and 1 guest