Jump to content
  • 0
Masao

Lightpillar effect on makeitem script command?

Question

Hello everyone

 

I was wondering if it would be somehow possible to add the lightpillar feature from item_flag.txt to the makeitem script command? Like would it be possible to add another parameter to the script command to add the flag from item_flag.txt so when the item is generated / droped next to the character via the makeitem command it behaves like it would've droped from a normal monster and generate the coloured lightpillar?

 

---------------------------------------

*makeitem(<item id>, <amount>, "<map name>", <X>, <Y>)
*makeitem("<item name>", <amount>, "<map name>", <X>, <Y>)

This command will create an item lying around on a specified map in the
specified location.

	itemid   - Found in 'db/(pre-)re/item_db.txt'
	amount   - Amount you want produced
	map name - The map name
	X        - The X coordinate
	Y        - The Y coordinate.

This item will still disappear just like any other dropped item. Like
getitem(), it also accepts an 'english name' field from the database and
creates apples if the name isn't found.
If the map name is given as "this", the map the invoking character is on
will be used.

---------------------------------------

So I thought about adding after the <Y>, <Flag>) where you then can put in the number like explained inside the item_flag.txt for ex.:


makeitem(12123,1,.@map$,.@x,.@y,2048)

 

So this would drop the item next to the character with the orange pillar effect.

 

Screen attached to show what I mean with lightpillar effect.


Thanks in advance for any help!

screenLotusRO006.jpg

Share this post


Link to post
Share on other sites

1 answer to this question

Recommended Posts

  • 1

Hmmm, you could enable light pillar drop through make item script command but the color code control is in item database which makes it hard.

 

with simple source modification of makeitem source and just enable the showdropeffect for the item you want to have drop effect.

 

or maybe someone can enlighten me as well with this. :D

 

Edit:

 

instead of modifying source, maybe you could just use the setoption script

 

prontera,124,201,1	script	trialNPC	4_F_JOB_BLACKSMITH,{

	.@item = 501;		//Set Item Here
	.@itemeffect = 3;	//Set Drop Effect Here (1-5)
	.@item_amount = 1;	//Set Item Amount Here
	.@loop = 100;		//Set How Many Times it will drop
	
	getmapxy(.@mapname$, .@mapx, .@mapy, UNITTYPE_PC, strcharinfo(0));
	
	setiteminfo(.@item, ITEMINFO_FLAG_SHOWDROPEFFECT, 1);	//Set shadow effect on for the said item
	setiteminfo(.@item, ITEMINFO_DROPEFFECT_MODE, .@itemeffect); //Set the drop effect based on the config
	
	for (.@i = 0; .@i <= .@loop; .@i++) {
		makeitem(.@item, .@item_amount,.@mapname$, .@mapx + 1, .@mapy + 1);
	}
	setiteminfo(.@item, ITEMINFO_FLAG_SHOWDROPEFFECT, 0);	//Set shadow effect off for the said item (to bring it back again to normal)
	setiteminfo(.@item, ITEMINFO_DROPEFFECT_MODE, 0);	//Set drop effect off for the said item (to bring it back again to normal)
	close;
}


Just came back from coding, could be a little messy. Lol

Edited by Samuel

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.