//---------------------------------------------------------------------------------------------
//
//	Chromatic Wing Mod
//	
//	Item drop from enemy - cause we have power item BAAAAAAAAA!
//	Include to enemy file only - I HATE stage system rightnow - damm
//
//	Type
//	0	= Score
//	1	= Point
//	2	= 1UP
//	3	= Power (Small) +5
//	4	= Power (Large) +50
//	5	= Power (Perfect) +100
//	6	= Fever
//	
//	Type - indicate item type as above.
//	num - number of item to drop
//	X, Y 1-5 - diffirent from other, this will be random number to drop from 
//	GetX, GetY cause I'll loop inside function instead. So they'll spam on themself.
//	If type is any power and charector is max power, it'll become point instead.
//	
//--------------------------------------------------------------------------------------------

	function EnemyDropItem(type, num)
	{
	// If power = max, drop other item instead. 0 for [3-6-15 score] 1 for [1-2-5 point]
	let ne_dropother = 1;


	let ne_dropX = 0;
	let ne_dropY = 0;
	loop (num)
		{
		ne_dropX = rand(-25-num,25+num);
		ne_dropY = rand(-25-num,25+num);
		
		if ((GetCommonDataDefault("CD_Power",0) >= 500) && ((type == 3) || (type == 4) || (type == 5)))
			{
			let ne_drop = 0;
			if (type == 3)	{	ne_drop = 1;	}
			else if (type == 4)	{	ne_drop = 2;	}
			else if (type == 5)	{	ne_drop = 5;	}
			
			if (ne_dropother == 0)	
				{
				ne_drop = ne_drop*3;
				loop (ne_drop)
					{
					ne_dropX = rand(-25-num,25+num);
					ne_dropY = rand(-25-num,25+num);
					CreateEnemyFromFile(GetCurrentScriptDirectory~"..\function\glo_item.txt",GetX+ne_dropX,GetY+ne_dropY,0,0,0);
					}
				}
			else
				{
				loop (ne_drop)
					{
					ne_dropX = rand(-25-num,25+num);
					ne_dropY = rand(-25-num,25+num);
					CreateEnemyFromFile(GetCurrentScriptDirectory~"..\function\glo_item.txt",GetX+ne_dropX,GetY+ne_dropY,0,0,1);
					}
				}
			}
		else
			{
			CreateEnemyFromFile(GetCurrentScriptDirectory~"..\function\glo_item.txt",GetX+ne_dropX,GetY+ne_dropY,0,0,type);
			}
		}
	}
