Exemple #1
0
func SetBottom2(object host)
{
	SetGraphics("Bottom");
	SetAction("Bottom", host);
	SetShape(0,0,32,4);
	SetPosition(host->GetX()+13, host->GetY()+12);
	SetSolidMask(0,0,32,4);
	SetVertexXY(0,1-29,-27);
	return true;
}
Exemple #2
0
func SetLeft(object host)
{
	SetGraphics("Left");
	SetAction("Left", host);
	SetShape(0,0,4,32);
	SetPosition(host->GetX()-16, host->GetY()-16);
	SetSolidMask(0,0,2,32);
	SetVertexXY(0,1,1);
	return true;
}
Exemple #3
0
func SetTop(object host)
{
	SetGraphics("Top");
	SetAction("Top", host);
	SetShape(0,0,32,4);
	SetPosition(host->GetX()-16, host->GetY()-16);
	SetSolidMask(0,0,32,4);
	SetVertexXY(0,1,1);
	return true;
}
Exemple #4
0
func SetRight2(object host)
{
	SetGraphics("Right");
	SetAction("Right", host);
	SetShape(0,0,4,32);
	SetPosition(host->GetX()+15, host->GetY()-48);
	SetSolidMask(0,0,2,32,2,0);
	SetVertexXY(0,-27-3,1+32);
	return true;
}
Exemple #5
0
func Set(i)  {
   
  if(i == 1) {
    SetAction("PicOne");
    SetSolidMask(0,0,51,30);
    return(1);
    }
  
  if(i == 2) {
    SetAction("PicTwo");
    SetSolidMask(51,0,83-51,30);
    return(1);
    }
  
  if(i == 3) {
    SetAction("PicThree");
    SetSolidMask(83,0,147-83,30);
    return(1);
    }
    
  return(0);
  }
Exemple #6
0
protected func Construction()
{
	SetSolidMask(0,0,GetDefWidth(GetID()), GetDefHeight(GetID()));
}
Exemple #7
0
protected func Initialize()
{
	SetAction("Closed");
	SetSolidMask(0, 0, 40, 20);
}
Exemple #8
0
func Initialize() {

  SetSolidMask(0,0,51,30);
  return(1);
  }
Exemple #9
0
func Initialize()
{
	SetSolidMask();
	if(GBackSolid())
	{
		RemoveObject();
		return 0;
	}
	SetSolidMask(0,0,10,10);
	
	var random = Random(5);
	if(random)
	{
		SetGraphics(Format("%d", random));
	}
	SetR(Random(360));
	SetRDir(2);
	SetAction("Travel");
	AddEffect("Particles", this, 20, 1, this);
	
	for(var o in FindObjects(Find_OCF(OCF_Alive), Find_Distance(10)))
	{
		o->Unstuck();
	}
	
	var smoke = 
	{
		ForceX = PV_Wind(200 - 180),
		DampingX = 900, DampingY = 900,
		Alpha = PV_Linear(255, 0),
		R = 100, G = 100, B = 100,
		Size = PV_Linear(PV_Random(4, 10), PV_Random(20, 30)),
		Phase = PV_Random(0, 15)
	};
	CreateParticle("Smoke", PV_Random(-5,5), PV_Random(-5,5), PV_Random(-15, 15), PV_Random(-15, 15), 30, smoke, 15);
	
	
	sharpflame =
	{
		Size = 10,
		R = 50,
		G = 255,
		B = 50,
		Alpha = 20,
		Rotation = PV_Random(0, 360),
		Phase = PV_Random(0, 5),
		OnCollision = 0,
		BlitMode = GFX_BLIT_Additive,
	};
	
		
	lightning =
	{
		Prototype = Particles_ElectroSpark2(),
		Size = PV_Linear(PV_Random(2,5),0),
		BlitMode = GFX_BLIT_Additive,
		Rotation = PV_Random(0,360),
		R = 50,
		G = 255,
		B = 50,
	};
}