Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How combine two Items?
Shives Offline
Member

Posts: 154
Threads: 41
Joined: Jan 2012
Reputation: 1
#5
RE: How combine two Items?

It doesn't work
It doesn't says that you can't combine the items but nothing happens Huh

What I've done wrong there?

////////////////////////////
// Run first time starting map
void OnStart()
{
SetLightVisible("PointLight_8", false);
SetEntityPlayerInteractCallback("Expoxy", "Interact", true);
AddUseItemCallback("", "Spreng", "compound_1", "Bunsenbrenner", true);
AddCombineCallback("", "Flasche", "Chemie", "Sprenger", false);
AddUseItemCallback("", "chemical_container_expoxy_1", "cave_in_1", "Sprengsatz", true);
AddEntityCollideCallback("Player", "ScriptArea_22", "Damage", true, 1);
}
void Sprenger(string &in asItemA, string &in asItemB)
{
RemoveItem("Chemie");
RemoveItem("Flasche");
GiveItem("Spreng", "chemical_container_half.ent", "", "chemical_container_half.tga", 1);
}
void Bunsenbrenner(string &in asItem, string &in asEntity)
{
FadeInSound("Bun", 0.5f, true);
SetEntityActive("Bunsa", true);
PlaySoundAtEntity("Bun", "puzzle_gas.snt", "Bunsa", 0, false);
AddTimer("", 1.6, "Finished");
}
void Finished(string &in asTimer)
{
RemoveItem("Spreng");
GiveItem("", "chemical_container_expoxy_1", "", "chemical_container_epoxy.tga", 1);
SetEntityActive("Bunsa", false);
StopSound("Bun", 2.0f);
}
void Sprengsatz(string &in asItem, string &in asEntity)
{
SetEntityActive("Expoxy", true);
PlaySoundAtEntity("", "step_run_dirt.snt", "ScriptArea_20", 0, false);
StartPlayerLookAt("ScriptArea_20", 2, 4, "StopPlayerLookAt");
}
void Interact(string &in asEntity)
{
AddTimer("", 3, "Explosion");
PlaySoundAtEntity("", "12_epoxy_blow.snt", "ScriptArea_20", 0, false);
}
void Explosion(string &in asTimer)
{
SetEntityActive("ScriptArea_22", true);
SetEntityActive("web_1", false);
SetEntityActive("Destroyer", true);
SetEntityActive("cave_in_1", false);
CreateParticleSystemAtEntity("", "Explosion.ps", "ScriptArea_21", false);
CreateParticleSystemAtEntity("", "ps_dust_elevator_crash.ps", "ScriptArea_21", false);
SetEntityActive("Box", false);
PlaySoundAtEntity("", "explosion_rock_large.snt", "ScriptArea_20", 0, false);
SetLightVisible("PointLight_8", true);
AddTimer("", 1, "LightOut");
}
void LightOut(string &in asTimer)
{
SetEntityActive("ScriptArea_22", false);
SetLightVisible("PointLight_8", false);
}
void Damage(string &in asItem, string &in asEntity)
{
GivePlayerDamage(120.9f, "damage_bloodsplat0.tga", true, true);
}
////////////////////////////
// Run when entering map
void OnEnter()
{

}

////////////////////////////
// Run when leaving map
void OnLeave()
{

}

My Custom Story
http://www.frictionalgames.com/forum/thread-12587.html

Sorry for bad English


04-06-2012, 10:37 AM
Find


Messages In This Thread
How combine two Items? - by Shives - 04-04-2012, 02:33 PM
RE: How combine two Items? - by Xanthos - 04-04-2012, 03:00 PM
RE: How combine two Items? - by Datguy5 - 04-04-2012, 03:06 PM
RE: How combine two Items? - by SilentStriker - 04-04-2012, 09:54 PM
RE: How combine two Items? - by Shives - 04-06-2012, 10:37 AM
RE: How combine two Items? - by zombiehacker595 - 04-06-2012, 11:11 AM
RE: How combine two Items? - by Shives - 04-06-2012, 11:17 AM
RE: How combine two Items? - by zombiehacker595 - 04-06-2012, 11:21 AM
RE: How combine two Items? - by Cranky Old Man - 04-06-2012, 11:26 AM
RE: How combine two Items? - by Shives - 04-06-2012, 11:39 AM
RE: How combine two Items? - by Shives - 04-06-2012, 01:51 PM
RE: How combine two Items? - by Cranky Old Man - 04-06-2012, 01:55 PM
RE: How combine two Items? - by SilentStriker - 04-06-2012, 03:54 PM
RE: How combine two Items? - by Shives - 04-06-2012, 02:06 PM
RE: How combine two Items? - by Your Computer - 04-06-2012, 05:32 PM



Users browsing this thread: 1 Guest(s)