summaryrefslogtreecommitdiffstats
path: root/DTParticles.c
blob: 537313487f4f915bef622c0dd3b8a86ef840aeac (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#strict 2

global func DrawParticleRect(string name, array rect, int dist, int a, b, int yDir)
{
	var ret = 0;
	if(GetType(b) != C4V_Array)
	{
		b = [b, b, b, b];
	}
	ret  = DrawParticleLine(name, rect[0], rect[1], rect[0] + rect[2], rect[1], dist, a, b[0], b[1], yDir);
	ret += DrawParticleLine(name, rect[0] + rect[2], rect[1], rect[0] + rect[2], rect[1] + rect[3], dist, a, b[1], b[2], yDir);
	ret += DrawParticleLine(name, rect[0] + rect[2], rect[1] + rect[3], rect[0], rect[1] + rect[3], dist, a, b[2], b[3], yDir);
	ret += DrawParticleLine(name, rect[0], rect[1] + rect[3], rect[0], rect[1], dist, a, b[3], b[0], yDir);
	return ret;
}