The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 906 - File: showthread.php PHP 7.2.24-0ubuntu0.18.04.17 (Linux)
File Line Function
/showthread.php 906 errorHandler->error



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
Script Help trouble with combining items
PixelHurricane Offline
Junior Member

Posts: 24
Threads: 8
Joined: Jul 2012
Reputation: 0
#1
trouble with combining items

what I want to happen is have the hammer (found in the level) be use on the bed to chip of a piece of metal (stone chipper) an then be able to combine those to produce a crowbar and hammer (kind of bend the metal and what not) getting the chipper works fine. it's the AddCombineCallback that seems to be not working at all

PHP Code: (Select All)
////////////////////////////
// Run when entering map
void OnEnter()
{
AddUseItemCallback("""stone_hammer_1""bed_simple_1""getiron"true);
}
void getiron(string &in asItemstring &in asEntity)
{
GiveItem("stone_chipper""stone_chipper""stone_chipper""stone_chipper.tga"1);
RemoveUseItemCallback("stone_hammer_1");
AddCombineCallback("makecrowbar""stone_hammer_1""stone_chipper""makecrowbar"false);
SetMessage("Messages""Jail1"2);
CreateParticleSystemAtEntity("""ps_hit_metal.ps""bed_simple_1"false);
}
void makecrowbar(string &in asItemAstring &in asItemB)
{
GiveItem("crowbar""crowbar""crowbar""crowbar.tga"1);
RemoveItem("stone_chipper");
}

////////////////////////////
// Run when leaving map
void OnLeave()
{
 
}[/
php 
]
03-14-2013, 10:35 PM
Find


Messages In This Thread
trouble with combining items - by PixelHurricane - 03-14-2013, 10:35 PM
RE: trouble with combining items - by NaxEla - 03-14-2013, 10:46 PM



Users browsing this thread: 1 Guest(s)