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
How to combining items?
giacomo9 Offline
Junior Member

Posts: 37
Threads: 11
Joined: Nov 2012
Reputation: 0
#1
How to combining items?

The player has an empty container, a bottle of acid and a bottle of glycerin - to create an explosive mixture, it must pour acid and glycerin into the empty container.
- Player gets "unfinished potion" when poured the contents of any bottle.
- Player gets the "explosive mixture" when combined "unfinished potion" with the other component.

How to do it? Big Grin
12-02-2012, 01:20 PM
Find
The chaser Offline
Posting Freak

Posts: 2,486
Threads: 76
Joined: Jun 2012
Reputation: 113
#2
RE: How to combining items?

void OnStart()
{
AddUseItemCallback("", "acid", "empty", "Unfinished", true);
AddUseItemCallback("", "Glycerin", "empty", "Unfinished", true);
}
void Unfinished(string &in asItem, string &in asEntity)
{
SetEntityActive("unfinished", true);
SetEntityActive("empty", false);
AddUseItemCallback("", "Glycerin", "unfinished", "To_complete", true);
AddUseItemCallback("", "acid", "unfinished", "To_complete", true);
}
void To_complete (string &in asItem, string &in asEntity)
{
SetEntityActive("Complete_yay", true);
SetEntityActive("unfinished", false);
}


Feel free to add screen efects so it doesn't look fake.

THE OTHERWORLD (WIP)
[Image: k6vbdhu]

Aculy iz dolan.
(This post was last modified: 12-02-2012, 04:19 PM by The chaser.)
12-02-2012, 04:16 PM
Find
giacomo9 Offline
Junior Member

Posts: 37
Threads: 11
Joined: Nov 2012
Reputation: 0
#3
RE: How to combining items?

When I tried to connect, for example, glycerin with an empty container, there was a message "combination does not work"...
12-02-2012, 11:00 PM
Find
NaxEla Offline
Senior Member

Posts: 415
Threads: 5
Joined: Dec 2012
Reputation: 28
#4
RE: How to combining items?

I would suggest taking a look at this video: http://www.youtube.com/watch?v=VtgSk36Sa8E

In Ruins [WIP]
12-03-2012, 05:35 AM
Find
The chaser Offline
Posting Freak

Posts: 2,486
Threads: 76
Joined: Jun 2012
Reputation: 113
#5
RE: How to combining items?

(12-02-2012, 11:00 PM)giacomo9 Wrote: When I tried to connect, for example, glycerin with an empty container, there was a message "combination does not work"...
That's a name problem. Check the names so they fit.

THE OTHERWORLD (WIP)
[Image: k6vbdhu]

Aculy iz dolan.
12-03-2012, 09:20 AM
Find
giacomo9 Offline
Junior Member

Posts: 37
Threads: 11
Joined: Nov 2012
Reputation: 0
#6
RE: How to combining items?

I do not have the file "Inventory.hps" can there be a problem?
12-03-2012, 05:08 PM
Find
giacomo9 Offline
Junior Member

Posts: 37
Threads: 11
Joined: Nov 2012
Reputation: 0
#7
RE: How to combining items?

Ok, problem solved Smile
12-03-2012, 06:28 PM
Find




Users browsing this thread: 2 Guest(s)