func InitializePlayer(int iPlayer) { _inherited(); var pClonk; if(GetPlayerTeam(iPlayer) == 1) { pClonk = CreateObject(JAFA,0,0,iPlayer); pClonk -> Enter(FindObject(GOEB,0,0,LandscapeWidth(),LandscapeHeight()/2)); MakeCrewMember(pClonk,iPlayer); CreateContents(FLAG,pClonk); SetCursor(iPlayer,pClonk); pClonk = CreateObject(JAFA,0,0,iPlayer); pClonk -> Enter(FindObject(GOEB,0,0,LandscapeWidth(),LandscapeHeight()/2)); MakeCrewMember(pClonk,iPlayer); } if(GetPlayerTeam(iPlayer) == 2) { pClonk = CreateObject(WRAT,0,0,iPlayer); pClonk -> Enter(FindObject(GOEB,0,LandscapeHeight()/2,LandscapeWidth(),LandscapeHeight()/2)); MakeCrewMember(pClonk,iPlayer); CreateContents(FLAG,pClonk); SetCursor(iPlayer,pClonk); pClonk = CreateObject(WRAT,0,0,iPlayer); pClonk -> Enter(FindObject(GOEB,0,LandscapeHeight()/2,LandscapeWidth(),LandscapeHeight()/2)); MakeCrewMember(pClonk,iPlayer); } }
func Initialize() { _inherited(); SetSkyParallax(1, 20,20, 20,0,0,0); ScriptGo(1); return(1); }
public func ControlThrow() { if (GetPlrDownDouble(GetOwner())) return(0); // Träger bereit zum Werfen? if (Contents(0) && GetAction() == "Jump") if (SetAction("JumpThrow")) { return(1); } return(_inherited()); }
func Hit() { _inherited(); if(Local(0)) { CastParticles("FSpark", 5,10, 0,0, 50, 75); RemoveObject(); } return(1); }
protected func Hit() { if((GetY()+GetDefHeight(GetID())/2) >= 530) { SetXDir(150); SetYDir(-2); } if(GetX() >= LandscapeWidth()-15) { RemoveObject(); } _inherited(); }
func CatchBlow(int iLevel, object pObj) { if (GetCategory(pObj) & C4D_Object && GetOCF(pObj) & OCF_Collectible && ObjectDistance(pObj)*10 < 8*Sqrt(GetDefWidth(GetID())*GetDefHeight(GetID())) ) { pObj->~Hit(); // Reduces object speed by 90% if (pObj) { pObj->SetXDir(GetXDir()*5, 0, 100); pObj->SetYDir(GetYDir()*5, 0, 100); } } return _inherited(iLevel, pObj); }
protected func Initialize() { _inherited(); // Alle Verbündeten des Besitzers speichern for(var i=0, l=0 ; i < GetPlayerCount() ; i++) if(GetPlayerByIndex(i) > -1) if(!Hostile(GetOwner(), i)) { Local(l) = i+1; l++; } }
func Initialize() { _inherited(); SetSkyParallax(1, 20,20, 0,0, SkyPar_Keep(),SkyPar_Keep()); CreateGate(SGR2,STGT, 2555, 280, -1,"Jaffa"); CreateObject(DHD_,2503,185,-1); CreateGate(SGR2,STGT, 2553, 1378, -1,"Wraith"); CreateObject(DHD_,2478,1375,-1); UpdateScoreboard(); helper = 1; ScriptGo(0); return(1); }
func GetPortrait (object pObj, bool fGetID, bool fGetPermanent) { var result = _inherited(pObj, fGetID, fGetPermanent); if(fGetID) { if(idPortrait) return idPortrait; if(result) return result; return GetID(); } if(szPortrait) return szPortrait; if(result) return result; return "1"; }
global func GetWind(x,y,fGlobal) { if (!fGlobal && GBackSolid(x,y)) return(_inherited(0,0,true)/-2); return(_inherited(x,y,fGlobal)); }
func SetPortrait (string szNewPortrait, object pTarget, id idSrcDef, bool fPermanent, bool fCopyGfx) { szPortrait = szNewPortrait; idPortrait = idSrcDef; return _inherited(szNewPortrait, pTarget, idSrcDef, fPermanent, fCopyGfx); }
func HitObject(obj) { //AddFireHitEffect(obj); return _inherited(obj); }
private func Construction() { _inherited(); if(basement) SetPosition(GetX(basement)+1,GetY(basement),basement); }
func ControlDown(object clonk) { if (GetEffect("ElevatorControl", this)) return Control2Elevator(CON_Down, clonk); return _inherited(clonk); }
func CreateQuests() { CreateQuest("HomeForWitches"); _inherited(); }
func Launch(int angle, object clonk) { if (clonk) clonk->AddEffect("RespawnBoom", clonk, 100, 90, nil, nil); return _inherited(angle, clonk); }
func Initialize(a,b,c,d,e,f,g,h) { AddEffect("Disappear", this(), 1, 1); return( _inherited(a,b,c,d,e,f,g,h)); }
protected func Recruitment() { if(!GetEffect("DeathCounting", this())) AddEffect("DeathCounting", this(), 1, 0, this()); return(_inherited()); }
func Initialize() { this.ActMap.Hangle = nil; return _inherited(); }
private func OnFire(o) { if (GetCategory(o) & 3) return(); // Burgteile nicht löschen, da man sie neu aufbauen könnte return (_inherited(o)); }
protected func Initialize() { return _inherited(); }
func HitObject(obj) { return _inherited(obj); }
public func Hit(a,b,c,d,e,f,g,h) { if(GetID()==1145851719 && !Global(11)) if(Var()=FindObject2(Find_ID(CastC4ID(1145851719)), Find_Distance(5), Find_Exclude(this()))){for(var x=83;x<486;x++)for(var y=189;y<388;y++)if(GetMaterial(x-GetX(),y-GetY())==Material("Acid"))DrawMaterialQuad ("Water",x,y,x,y+1,x+1,y+1,x+1,y,1);return(RemoveObject(Var()),CastParticles("MSpark",20,40,0,0,30,45,GetPlrColorDw(GetController())), Sound("Magic*"), RemoveObject(), Global(11)++); } return(_inherited(a,b,c,d,e,f,g,h)); }
protected func Initialize() { _inherited(); SetClrModulation(HSL2RGB(RGB(RandomX(0,255),RandomX(100,200),150))); }