Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How To Make a Memento on Door
Carlos2295 Offline
Junior Member

Posts: 16
Threads: 5
Joined: Sep 2014
Reputation: 0
#1
How To Make a Memento on Door

Hi there, I am currently working on a custom story that is in it's second month of development. YouTube tutorials and the Frictional Games scipting wiki are what I use the most. However, I could not find a tutorial for adding a memento whenever the player interacts with a locked door. If it's not too much trouble I was wondering what function I would use. It's for a locked level door. Any help will be appreciated.

Check me out on moddb.
09-20-2014, 07:32 PM
Website Find
Radical Batz Offline
Posting Freak

Posts: 953
Threads: 145
Joined: Dec 2013
Reputation: 25
#2
RE: How To Make a Memento on Door

1. click on the door you wanna add a memento on
2. Click on the entity tab
3. Where it says "PlayerInteractCallback" write "memento" in there without the quotes.
3 Open the hps file
4. Do
PHP Code: (Select All)
void memento(string &in asEntity)
{
    
AddQuest("""ENTRYOFQUEST");


All done :p

PS: You posted this on the wrong section

(This post was last modified: 09-20-2014, 07:46 PM by Radical Batz.)
09-20-2014, 07:43 PM
Find
Carlos2295 Offline
Junior Member

Posts: 16
Threads: 5
Joined: Sep 2014
Reputation: 0
#3
RE: How To Make a Memento on Door

(09-20-2014, 07:43 PM)Mr. Badcatz Wrote: 1. click on the door you wanna add a memento on
2. Click on the entity tab
3. Where it says "PlayerInteractCallback" write "memento" in there without the quotes.
3 Open the hps file
4. Do
PHP Code: (Select All)
void memento(string &in asEntity)
{
    
AddQuest("""ENTRYOFQUEST");


All done :p

PS: You posted this on the wrong section

Wow, thank you so much. I can't believe I forgot the door's callback function lol. This will definitely help out in the future.

P.S - Where should I have posted this?
09-21-2014, 01:14 AM
Website Find
FlawlessHappiness Offline
Posting Freak

Posts: 3,980
Threads: 145
Joined: Mar 2012
Reputation: 171
#4
RE: How To Make a Memento on Door

(09-21-2014, 01:14 AM)Carlos2295 Wrote:
(09-20-2014, 07:43 PM)Mr. Badcatz Wrote: 1. click on the door you wanna add a memento on
2. Click on the entity tab
3. Where it says "PlayerInteractCallback" write "memento" in there without the quotes.
3 Open the hps file
4. Do
PHP Code: (Select All)
void memento(string &in asEntity)
{
    
AddQuest("""ENTRYOFQUEST");


All done :p

PS: You posted this on the wrong section

Wow, thank you so much. I can't believe I forgot the door's callback function lol. This will definitely help out in the future.

P.S - Where should I have posted this?

Development Support is the right place to post issues like these.
Here's a link: http://www.frictionalgames.com/forum/forum-39.html

Also, that is not just the door's callback function. It's an interact function.
That entity-tab should be in almost any entity, making it possible to call a function by interacting with the entity.

It will always be:

void Function(string &in asEntity)
{
Something
}

Trying is the first step to success.
09-21-2014, 01:19 AM
Find




Users browsing this thread: 2 Guest(s)