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
Can't use my acid on web
Lizard Offline
Member

Posts: 174
Threads: 23
Joined: Jul 2012
Reputation: 5
#1
Can't use my acid on web

Hi guys.

I've used AddUseItemCallback many times before, with no errors, but this time it just wont work, and i can't really see why.
I keep getting "Cannot use item this way"

Im hoping that you guys would help me a little


void OnEnter()
{
AddUseItemCallback("", "glass_container_1", "acid_container_1", "giveacid", true);

AddUseItemCallback("", "glass_container_mix_done", "web_1", "burnweb", true);

}


void giveacid(string &in asItem, string &in asEntity)
{
RemoveItem("glass_container_1");
GiveItem("", "glass_container_mix_done", "glasscontainermixdone", "glass_container_mix_done.tga", 1);
}


void burnweb(string &in asItem, string &in asEntity)
{
SetPropHealth("web_1", 0);
}

I've also checked for name errors

I've also tryed, to change name of the container used in the burnweb function "glass_container_mix_done" to "glass_container_mix_done_1"

CURRENT PROJECT:
A Fathers Secret == Just started
(This post was last modified: 10-04-2012, 03:08 PM by Lizard.)
10-04-2012, 12:09 PM
Find
Ongka Offline
Member

Posts: 225
Threads: 3
Joined: Nov 2010
Reputation: 20
#2
RE: Can't use my acid on web

Try using SetPropActiveAndFade("web_1", false, 3); instead of SetPropHealth.
This will make it "dissolve".

[Image: 18694.png]
10-04-2012, 12:32 PM
Find
Lizard Offline
Member

Posts: 174
Threads: 23
Joined: Jul 2012
Reputation: 5
#3
RE: Can't use my acid on web

(10-04-2012, 12:32 PM)Ongka Wrote: Try using SetPropActiveAndFade("web_1", false, 3); instead of SetPropHealth.
This will make it "dissolve".
thanks i might consider that Smile

But my problems is when try to use my acid on the web its says "Cannot use this item this way!"

CURRENT PROJECT:
A Fathers Secret == Just started
10-04-2012, 12:41 PM
Find
Ongka Offline
Member

Posts: 225
Threads: 3
Joined: Nov 2010
Reputation: 20
#4
RE: Can't use my acid on web

Create an area instead and place it on the web. You have to tick the box which says "ItemInteraction" and use the item on the script area. This should work fine.

[Image: 18694.png]
10-04-2012, 01:14 PM
Find
Lizard Offline
Member

Posts: 174
Threads: 23
Joined: Jul 2012
Reputation: 5
#5
Photo  RE: Can't use my acid on web

(10-04-2012, 01:14 PM)Ongka Wrote: Create an area instead and place it on the web. You have to tick the box which says "ItemInteraction" and use the item on the script area. This should work fine.
Is still say "Cannot use this item this way"

This is what i have now:
void OnEnter()

{

AddUseItemCallback("", "glass_container_1", "acid_container_1", "giveacid", true);
AddUseItemCallback("", "glass_container_mix_done1", "ScriptArea_1", "burnweb", true);
}

void giveacid(string &in asItem, string &in asEntity)
{
RemoveItem("glass_container_1");
GiveItem("", "glass_container_mix_done1", "glasscontainermixdone", "glass_container_mix_done.tga", 1);
}

void burnweb(string &in asItem, string &in asEntity)
{
SetPropActiveAndFade("web_1", false, 3);
}

picture of web and area:
[attachment=3411]

CURRENT PROJECT:
A Fathers Secret == Just started
(This post was last modified: 10-04-2012, 01:40 PM by Lizard.)
10-04-2012, 01:40 PM
Find
The chaser Offline
Posting Freak

Posts: 2,486
Threads: 76
Joined: Jun 2012
Reputation: 113
#6
RE: Can't use my acid on web

Try using it with the web itself. Every single entity can be interacted by a puzzle item. So, as acid appears in the screen, why not using the acid on the web directly? This may solve the problem.

Try doing easy things. If they don't work, use hard. Yep, that's it.

THE OTHERWORLD (WIP)
[Image: k6vbdhu]

Aculy iz dolan.
10-04-2012, 01:49 PM
Find
Lizard Offline
Member

Posts: 174
Threads: 23
Joined: Jul 2012
Reputation: 5
#7
RE: Can't use my acid on web

(10-04-2012, 01:49 PM)The chaser Wrote: Try using it with the web itself. Every single entity can be interacted by a puzzle item. So, as acid appears in the screen, why not using the acid on the web directly? This may solve the problem.

Try doing easy things. If they don't work, use hard. Yep, that's it.
Using it on the web directly was the first thing i did Sad

CURRENT PROJECT:
A Fathers Secret == Just started
10-04-2012, 01:51 PM
Find
Your Computer Offline
SCAN ME!

Posts: 3,456
Threads: 32
Joined: Jul 2011
Reputation: 235
#8
RE: Can't use my acid on web

It doesn't work because you didn't give the item a name.

Tutorials: From Noob to Pro
10-04-2012, 02:03 PM
Website Find
Lizard Offline
Member

Posts: 174
Threads: 23
Joined: Jul 2012
Reputation: 5
#9
RE: Can't use my acid on web

(10-04-2012, 02:03 PM)Your Computer Wrote: It doesn't work because you didn't give the item a name.


GiveItem("", "glass_container_mix_done", "glasscontainermixdone", "glass_container_mix_done.tga", 1);



i guess its the first bracket you were talking about?


I just tryed to enter the name and add it so it goes whit the script, but still not make it work

(10-04-2012, 02:10 PM)ZereboO Wrote:
(10-04-2012, 02:03 PM)Your Computer Wrote: It doesn't work because you didn't give the item a name.


GiveItem("", "glass_container_mix_done", "glasscontainermixdone", "glass_container_mix_done.tga", 1);



i guess its the first bracket you were talking about?


I just tryed to enter a name and add it so it goes whit the script, but still dosen't work

CURRENT PROJECT:
A Fathers Secret == Just started
(This post was last modified: 10-04-2012, 02:11 PM by Lizard.)
10-04-2012, 02:10 PM
Find
Your Computer Offline
SCAN ME!

Posts: 3,456
Threads: 32
Joined: Jul 2011
Reputation: 235
#10
RE: Can't use my acid on web

What name did you give it?

Tutorials: From Noob to Pro
10-04-2012, 02:15 PM
Website Find




Users browsing this thread: 1 Guest(s)