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
inventory.hps just doesnt work.
Cherubeal Offline
Junior Member

Posts: 5
Threads: 2
Joined: Oct 2012
Reputation: 0
#1
inventory.hps just doesnt work.

Im trying to make two items combine together. The code im using is here:


void OnGameStart()
{
AddCombineCallback("", "Piracetam", "SalvinaDinorum", "MadPotFun", true);
}
void MadPotFun(string &in asItemA, string &in asItemB)
{
RemoveItem("Piracetam");
RemoveItem("SalvinaDinorum");
GiveItem("MadnessPotion", "Puzzle", "MadnessPotion", "chemical_container_full.tga", 1);
}


Its currently in inventory.hps in my maps file. The names of all the items are definitely correct. The code doesnt work when moved into the main hps file (moving the on game start function to the OnStart section). I tried entering wrong syntax on purpose into my inventory file to see if its even running because i figured an error would return. The game doesnt report back an error. Ive tried renaming, moving, recreating, shifting, refreshing and editing the inventory.hps file to try and connect it and nothing. Is. Working. This is driving me insane. And yes it is called "inventory.hps" with lowercase i.


<Entry Name="ItemDesc_SalvinaDinorum">"A jar of powdered Salvina Dinorum"</Entry>
<Entry Name="ItemName_SalvinaDinorum">"Salvina Dinorum"</Entry>

<Entry Name="ItemDesc_Piracetam">"A jar of concentrated Piracetam"</Entry>
<Entry Name="ItemName_Piracetam">"Concentrated Piracetam"</Entry>

My lang file entry that DOES work to show all the names are correct. All i get when trying to combine is "That combination doesnt work". The function never calls. The file is never linked. What on earth to i do.

Thanks in advance. Im going to destroy my computer at this rate.
10-31-2012, 10:42 PM
Find


Messages In This Thread
inventory.hps just doesnt work. - by Cherubeal - 10-31-2012, 10:42 PM
RE: inventory.hps just doesnt work. - by Lizard - 10-31-2012, 10:52 PM



Users browsing this thread: 1 Guest(s)