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
Combining A Drill?
Amnesiaplayer Offline
Senior Member

Posts: 539
Threads: 105
Joined: Jun 2014
Reputation: 0
#11
RE: Combining A Drill?

PHP Code: (Select All)
void OnGameStart()
{
AddCombineCallback("DrillAB""DrillA""DrillB""CombineDrill"true);
AddCombineCallback("DrillBC""DrillB""DrillC""CombineDrill"true);
AddCombineCallback("DrillCA""DrillC""DrillA""CombineDrill"true); 
}
 
void CombineDrill(string &in asItemAstring &in asItemB)
{
        
RemoveItem(asItemA);
        
RemoveItem(asItemB);    
      
        
GiveSanityBoost();
 
        
PlayGuiSound("12_make_drill"1);
 
        
GiveItem("Drill""Puzzle""Drill""hand_drill.tga"1);


and if i add RemoveItem(asItemC);
It will not combine Sad (the drill)
09-25-2014, 04:44 PM
Find
FlawlessHappiness Offline
Posting Freak

Posts: 3,980
Threads: 145
Joined: Mar 2012
Reputation: 171
#12
RE: Combining A Drill?

That's because there is nothing in that script called asItemC.
You only have asItemA and asItemB as stated in the parameters: (string &in asItemA, string &in asItemB)

What you're gonne do is you're gonna use this instead:
PHP Code: (Select All)
RemoveItem("DrillA");
RemoveItem("DrillB");
RemoveItem("DrillC"); 

Trying is the first step to success.
09-25-2014, 04:54 PM
Find
Amnesiaplayer Offline
Senior Member

Posts: 539
Threads: 105
Joined: Jun 2014
Reputation: 0
#13
RE: Combining A Drill?

I knooowww but what i said...
if i do THAT (copy paste) it still doesn't COMBINE...
so if i have THIS script

PHP Code: (Select All)
void OnGameStart()
{
AddCombineCallback("DrillAB""DrillA""DrillB""CombineDrill"true);
AddCombineCallback("DrillBC""DrillB""DrillC""CombineDrill"true);
AddCombineCallback("DrillCA""DrillC""DrillA""CombineDrill"true); 
}
 
void CombineDrill(string &in asItemAstring &in asItemB)
{
        
RemoveItem("DrillA");
        
RemoveItem("DrillB");
        
RemoveItem("DrillC");  
      
        
GiveSanityBoost();
 
        
PlayGuiSound("12_make_drill"1);
 
        
GiveItem("Drill""Puzzle""Drill""hand_drill.tga"1);


it will NOT combine. (the parts) for the third time Tongue
09-25-2014, 05:02 PM
Find
FlawlessHappiness Offline
Posting Freak

Posts: 3,980
Threads: 145
Joined: Mar 2012
Reputation: 171
#14
RE: Combining A Drill?

As I'm looking at the script right now, everything should work fine.
Are the entities named correctly?

What happens when you try to combine them?

Trying is the first step to success.
09-25-2014, 05:08 PM
Find
Amnesiaplayer Offline
Senior Member

Posts: 539
Threads: 105
Joined: Jun 2014
Reputation: 0
#15
RE: Combining A Drill?

Yes they all are correct.
if i combine nothing happens. just message :

Can't combine items.
09-25-2014, 05:17 PM
Find
Mudbill Offline
Muderator

Posts: 3,881
Threads: 59
Joined: Apr 2013
Reputation: 179
#16
RE: Combining A Drill?

You said you could combine them fine before, but that you still had the drill parts in your inventory. How did it break? You haven't changed anything but those RemoveItem lines, right?

(This post was last modified: 09-25-2014, 06:00 PM by Mudbill.)
09-25-2014, 06:00 PM
Find
Amnesiaplayer Offline
Senior Member

Posts: 539
Threads: 105
Joined: Jun 2014
Reputation: 0
#17
RE: Combining A Drill?

yes... i have Everything what you said.. and it DOESN'T combine Sad
but if i erase the Blabla C line.... it could work.... (tested) maybe i need somethingg ?? Sad
09-25-2014, 06:15 PM
Find
Mudbill Offline
Muderator

Posts: 3,881
Threads: 59
Joined: Apr 2013
Reputation: 179
#18
RE: Combining A Drill?

DOES it work if you remove that line then?

Cause if so, there's no reason for it not to after adding that line.

09-25-2014, 06:27 PM
Find
FlawlessHappiness Offline
Posting Freak

Posts: 3,980
Threads: 145
Joined: Mar 2012
Reputation: 171
#19
RE: Combining A Drill?

(09-25-2014, 06:15 PM)Amnesiaplayer Wrote: yes... i have Everything what you said.. and it DOESN'T combine Sad
but if i erase the Blabla C line.... it could work.... (tested) maybe i need somethingg ?? Sad

"Could" is not enough. You need to test it.

Trying is the first step to success.
09-25-2014, 06:32 PM
Find
Amnesiaplayer Offline
Senior Member

Posts: 539
Threads: 105
Joined: Jun 2014
Reputation: 0
#20
RE: Combining A Drill?

yes i forgot about it. i tested it like 5 times :S it's working if i erase the C line Sad
i really don't understand... the name MUST be good.. if the C name isn't good it wasn't possible to combine :S (it's good the names)
09-25-2014, 06:34 PM
Find




Users browsing this thread: 2 Guest(s)