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
Level Editor Help Combine drill in a script!
PutraenusAlivius Offline
Posting Freak

Posts: 4,713
Threads: 75
Joined: Dec 2012
Reputation: 119
#2
RE: Combine drill in a script!

Make a .txt file.
Change it's extension to .hps.
Rename it so that it will look like "global.hps".
Open it with Notepad.
Copy-paste the following code to your global.hps
void OnGameStart()
{
AddCombineCallback("HandDrill", "Nameofthefirstitem", "Nameoftheseconditem", "CombineHandDrill", true);
}

void CombineHandDrill(string &in asItemA, string &in asItemB)
{
PlayGuiSound("12_make_drill", 1.0f);
RemoveItem(asItemA); RemoveItem(asItemB);
GiveItem("HandDrill", "Puzzle", "hand_drill", "hand_drill.tga", 0);
}
Change
"Nameofthefirstitem" to the First Item you wanna combine.
AND
"Nameoftheseconditem" to the Second Item you wanna combine.
The names must be the same as their name in the Level Editor. And always use quotation marks ("") around names.

"Veni, vidi, vici."
"I came, I saw, I conquered."
(This post was last modified: 04-05-2013, 09:59 AM by PutraenusAlivius.)
04-05-2013, 09:49 AM
Find


Messages In This Thread
Combine drill in a script! - by TimeSpectre - 04-05-2013, 09:27 AM
RE: Combine drill in a script! - by PutraenusAlivius - 04-05-2013, 09:49 AM
RE: Combine drill in a script! - by TimeSpectre - 04-05-2013, 10:55 AM
RE: Combine drill in a script! - by Yare - 04-05-2013, 12:16 PM



Users browsing this thread: 1 Guest(s)