Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

FPSC Classic Scripts / Free scripts for talking npc/character, having conversations and such.

Author
Message
Benjamin A
19
Years of Service
User Offline
Joined: 31st Oct 2005
Location: The Netherlands
Posted: 19th Nov 2005 01:00 Edited at: 14th Apr 2006 00:47
I've created three different talking npc / conversation scripts. I'm guessing I'm not the only one who could use such scripts.

You can use them to have characters display messages or have a conversation and such. Whenever you walk up to the player he will first rotate towards you. When coming closer he will start talking to you.

All of the scripts are suitable for audio speech + text subtitles situations, except script 3.

For all scripts: You can add more messages if you want to and take out the sounds if not needed. All of the message loop, if you walk up to the character again, the message will display again. To stop the looping, just take out :state=2,plrdistfurther=60:state=10 at the end of the script. You can change the hudx=50,hudy=50 for a different position of the text displayed, at the moment there centered.

IMPORTANT NOTE: If you're going to use more then one character to have a conversation with, then make sure you create a seperate script for each character and change the hudname=talk1 hudname=talk2 hudname=talk3 to something else in each script, otherwise the correct texts will not display! If you use 3 characters for example change it into hudname=p1talk1 hudname=p1talk2 hudname=p1talk3 for the first character, hudname=p2talk1 hudname=p2talk2 hudname=p2talk3 for the second character and hudname=p3talk1 hudname=p3talk2 hudname=p3talk3 for the last one.

Have fun with them!

1. Walk up to an character and he will display three messages in a row. Change the time to slow down or quicken the message appearance.

You can use it like this for example:
Message 1: Hi, I'm Benjamin, I'm not supposed to tell this....
Message 2: .....but, there's a key hidden in the blue room.....
Message 3: .....that will open the red room.

or

Message 1: Benjamin: Hi, I'm Benjamin, how are you doing today?
Message 2: Player: I'm fine thank you, how about you?
Message 3: Benjamin: Great, I've just created 3 cool scripts for you!



2. Walk up to an character and he will display a message. Walk away and the message will dissappear. Walk up to the character again and a different message will appear. Walk away and the message will dissappear. Walk up to the character once more and a different message will appear. Walk away and the message will dissappear.

You could use it like this for example:

Message 1: Hi, I'm Benjamin, I love FPSC
Message 2: Oh, it's you again. I've got nothing more to say to you.
Message 3: What you again? Stop bothering me!



3. Basically the same as 1, but instead of the messages appearing automatically, the player has to press enter after each message. Once the player presses enter, a sound is heard to afirm the enter being pressed.



4. Basically the same as 3, but the sound comes as soon as the text appears too. 4 can be used for audio-speach characters, 3 can't.



As suggested I'll add variations to this original thread, makes it easier to find everything.

Variation 1:

When the player walks up to the character the message will show. When the player presses Enter or walks away, the message will dissappear and never come back!



Variation 2 (modified by Trotter):
Walk up to an character and...nothing happens. You have to use the "action" button to make him speak. When the user presses enter once more, the last message will display. Sounds come after pressing enter.



Bored of indoor? Add outdoor to your FPSC games!
http://www.aeilkema.dds.nl/mega/index.html
Need music for your games? Check the above link also!
flashing snall
19
Years of Service
User Offline
Joined: 8th Oct 2005
Location: Boston
Posted: 19th Nov 2005 01:18
INCREDIBLE! dude, thanks a lot. i just have one question. Inthe scripts, it says for the hud image, insert your image here. can thay be png. or bmp. or jpeg?

dont assune cause u make an ass out of u and me
Benjamin A
19
Years of Service
User Offline
Joined: 31st Oct 2005
Location: The Netherlands
Posted: 19th Nov 2005 01:21
png or tga is best. That way you can add transparency also, like with the you picked up a key and such texts.

Also you can change the position of the images/texts displayed, in the scripts they are centered in the screen.

FPSC is way to cool, you can create even more then a fps with it!
flashing snall
19
Years of Service
User Offline
Joined: 8th Oct 2005
Location: Boston
Posted: 19th Nov 2005 01:37 Edited at: 19th Nov 2005 01:38
so, can i use paint?
in my, game, i can now have doors that can talk to you, like "show I.D. please" " or "please insert 2000$, or i wont open punk!" ha, this will be so much fun...

dont assune cause u make an ass out of u and me
Benjamin A
19
Years of Service
User Offline
Joined: 31st Oct 2005
Location: The Netherlands
Posted: 19th Nov 2005 01:47
Paint does save png files, but if it uses transparent backgrounds I don't know. If tranpsarency doesn't work in paint, just make sure you don't create screen filling huds, but more banner like ones. That way the player can still see what's going on and walk away from the characters or whatever you attach the script to.

I provide the scripts, you've got to create the pics and find out what works best.

Well, I'm off to bed now..... getting late.

FPSC is way to cool, you can create even more then a fps with it!
Jason Webb
19
Years of Service
User Offline
Joined: 2nd Nov 2005
Location: Southampton, UK
Posted: 19th Nov 2005 02:13
Nice work Benjamin!

So from looking at the script I'm assuming that you have audio speech plus text subtitles?

That's pretty neat and something that I've been thinking about recently. Well done!

Best Regards

Jason

Owner - Music Genius Publishing
http://www.musicgenius.co.uk
flashing snall
19
Years of Service
User Offline
Joined: 8th Oct 2005
Location: Boston
Posted: 19th Nov 2005 03:41
good night oh slpeeing one. and thank you for your kindness

dont assune cause u make an ass out of u and me
Benjamin A
19
Years of Service
User Offline
Joined: 31st Oct 2005
Location: The Netherlands
Posted: 19th Nov 2005 08:51
Quote: "So from looking at the script I'm assuming that you have audio speech plus text subtitles?"


Yes, you could with the first 2 scripts, but the third one would need some changing to accomplish this. It plays a sound after you press enter, but it can be changed to do so before. If I do have some time today or tomorrow I'll try to add a 4th script to the list. If I'm not getting around doing so this weekendm it will be next week for sure.

FPSC is way to cool, you can create even more then a fps with it!
Vlad
19
Years of Service
User Offline
Joined: 5th Oct 2005
Location:
Posted: 19th Nov 2005 13:54
Wonderful work Benjamin!

V
Havok
19
Years of Service
User Offline
Joined: 29th Jul 2005
Location: In a box
Posted: 19th Nov 2005 14:16
To do a lipsync, coudn't you add a speak animation to the character entities and make a trigger zone that plays the animation when you step into it?

I know Karate, Kung Fu, and 47 other dangerous words...

Benjamin A
19
Years of Service
User Offline
Joined: 31st Oct 2005
Location: The Netherlands
Posted: 19th Nov 2005 15:11
You probably could. I created this scripts to get away from trigger zones though.... more flexibility this way. Next week I'm going to try to add walking to the scripts, even more fun.

FPSC is way to cool, you can create even more then a fps with it!
dpharaoh
19
Years of Service
User Offline
Joined: 2nd Nov 2005
Location: SouthEast MA
Posted: 19th Nov 2005 19:42
What a great idea, thanks for posting these!
Benjamin A
19
Years of Service
User Offline
Joined: 31st Oct 2005
Location: The Netherlands
Posted: 19th Nov 2005 23:03
PLEASE NOTE: I've added a fourth script as requested. The new one can be used for audio speech plus text subtitles also.

FPSC is way to cool, you can create even more then a fps with it!
Jason Webb
19
Years of Service
User Offline
Joined: 2nd Nov 2005
Location: Southampton, UK
Posted: 21st Nov 2005 12:38
Thanks Benjamin, that's going to come in very handy. Nice work!

Best Regards

Jason

Owner - Music Genius Publishing
http://www.musicgenius.co.uk
gh1
19
Years of Service
User Offline
Joined: 4th Oct 2005
Location:
Posted: 21st Nov 2005 20:56
This is using the #4 script...

I created 1.png, 2.png, and 3.png and placed them in the texturebank\user folder.

I put 1.wav, 2.wav, and 3.wav in the audiobank\user folder.

Everything works well except the sounds. Can anyone give me a clue as to what I'm doing incorrectly?
gh1
19
Years of Service
User Offline
Joined: 4th Oct 2005
Location:
Posted: 22nd Nov 2005 03:53
Here's what I have for the script (looks like it didn't post correctly in the last message).

Benjamin A
19
Years of Service
User Offline
Joined: 31st Oct 2005
Location: The Netherlands
Posted: 22nd Nov 2005 13:33
Should work fine, mine looks the same and works. Perhaps there's something wrong with sound files? Try it with one or more of the sounds provided with FPSC to see what will happen then.

Or, you could upload one of the sounds to a reply for us to try it?

FPSC is way to cool, you can create even more then a fps with it!
gh1
19
Years of Service
User Offline
Joined: 4th Oct 2005
Location:
Posted: 22nd Nov 2005 14:38
Yep, the sounds I was trying to use were junk. Everything works perfectly with good sound files. Thanks Benjamin
=ChrisB=
19
Years of Service
User Offline
Joined: 23rd Jun 2005
Location: starring into a viewfinder
Posted: 22nd Nov 2005 21:27
May I put them on my web site?

Your signature has been erased by a mod
Benjamin A
19
Years of Service
User Offline
Joined: 31st Oct 2005
Location: The Netherlands
Posted: 22nd Nov 2005 22:48
@all, thanks for the comments! I'm glad you all find it usefull.

@ChrisB, sure no restriction on them, so go ahead.

FPSC is way to cool, you can create even more then a fps with it!
Arness
19
Years of Service
User Offline
Joined: 26th Sep 2005
Location: on my computer what do you think?
Posted: 26th Nov 2005 19:03
ummmmmmmmmmmmmmmm....
can you make it so if you pick up a item example red pad
can you make it so it will show the text i have seen it done i cant figure it out

Fps creator forever!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
and ever and ever and ever and ever and ever....
Jason Webb
19
Years of Service
User Offline
Joined: 2nd Nov 2005
Location: Southampton, UK
Posted: 19th Dec 2005 15:37 Edited at: 19th Dec 2005 15:38
If anybody wants to see these scripts in operation, I've just added
a movie to my screenshots thread in "Showcase".

Thanks once again to Benjamin A for providing these.

Best Regards

Jason

Owner - Music Genius Publishing
http://www.musicgenius.co.uk
Jason Webb
19
Years of Service
User Offline
Joined: 2nd Nov 2005
Location: Southampton, UK
Posted: 19th Dec 2005 18:02 Edited at: 19th Dec 2005 18:03
I'm attempting to modify the script so that when you are within
speaking range of the NPC a "talkicon" is displayed on the screen.
Obviously I also want the icon to vanish once the conversation is
over or you move out of range.

It seems to work fine once but when you approach the NPC again
the talkicon doesn't show. Everything else, the actual speech etc.,
works exactly as I want it to. It's just "talkicon" which is
misbehaving.



Any ideas from anybody?

Best Regards

Jason

Owner - Music Genius Publishing
http://www.musicgenius.co.uk
Acolyte Entertainment
19
Years of Service
User Offline
Joined: 28th Dec 2004
Location: Oregon, US
Posted: 22nd Dec 2005 02:42
Benjamin A. can you please make a script just to display ONE. message so when yo walk to an item
it shows the message when you walk away it goes away and you can walk up again
and it shows the same message. what im getting at is that i want a script where it only
displays one message. thanks

- The trick to level design is leave you real life behind... follow your imagination in a winding path threw fiction.
Acolyte Entertainment
19
Years of Service
User Offline
Joined: 28th Dec 2004
Location: Oregon, US
Posted: 24th Dec 2005 21:00
dude benjamin A. please respond

Benjamin A
19
Years of Service
User Offline
Joined: 31st Oct 2005
Location: The Netherlands
Posted: 24th Dec 2005 21:32
Sorry for not responding.... I'm having a vacation

Quote: "Benjamin A. can you please make a script just to display ONE. message so when yo walk to an item it shows the message when you walk away it goes away and you can walk up again and it shows the same message. what im getting at is that i want a script where it only displays one message."


I could, but I'm not going too. Why? It is very easy to edit the scripts to achieve what you want them to do. All you need to do is take out the messages and their corresponding state you don't need. It's as simple as that.

All I do is create scripts I need for my projects and I'm happy to release some of them to the public, so they can use them in their projects also. I'm not going to edit, create or adapt scripts for all that need it. Sorry, I simply don't have time for that.

Between having a part-time job, a part-time bussiness to run, a family to spent time with, friends, pets, trying to live with a physical disability and so on, I've got little time left to do stuff, so I need to make choices. That's why you don't see me much on this (or any other) forum. Editing, creating, adapting scripts for others isn't one of the choices I've made, sorry.

MegaMusic Pack 01.... 31 original soundtracks for your games!
http://www.aeilkema.dds.nl/mega/index.html
Conjured Entertainment
AGK Developer
19
Years of Service
User Offline
Joined: 12th Sep 2005
Location: Nirvana
Posted: 25th Dec 2005 18:33
Quote: "so, can i use paint?"


Yes.
You can use MS-Paint if you use a JPG format for your HUD.
True Black (0,0,0 RGB) will be transparent.

I used Paint to create the Hud for my Flashlight.




Whatever you can imagine, you can animate. --- Walt Disney
All too easy. --- Darth Vader
Just do it! --- Nike
Gamerboy
18
Years of Service
User Offline
Joined: 25th Dec 2005
Location:
Posted: 3rd Jan 2006 22:47 Edited at: 3rd Jan 2006 22:49
i have four questions.
1:can i have the text be in notepad format?
2:how would i make it so after he says text3 he would reapet it every time you try to talk to him again?
3:were do i put this script? in main? in shoot? what?
4:how would i make it so he faces the player when talking?
Benjamin A
19
Years of Service
User Offline
Joined: 31st Oct 2005
Location: The Netherlands
Posted: 4th Jan 2006 07:19
1. yes.... as long as you save it as an .fpi file and not .txt!
2. depends on which of the four you use, but you need to change the line :state=2,plrdistfurther=60:state=10 The last state=10 action needs to refer to a different state.
3. Attach it to the main script of the entitie.
4. Already does so.
5. Read the manual before you start working with fpsc, it really helps!

MegaMusic Pack 01.... 31 original soundtracks for your games!
http://www.aeilkema.dds.nl/mega/index.html
Gamerboy
18
Years of Service
User Offline
Joined: 25th Dec 2005
Location:
Posted: 4th Jan 2006 18:26
ok i made 3 text formats and saved them as .bmp with paint but when i go up to the guy and hit enter he dos nothing. do i need to delete the [] on the sides of my pathes?
Benjamin A
19
Years of Service
User Offline
Joined: 31st Oct 2005
Location: The Netherlands
Posted: 4th Jan 2006 19:26
yes you do need to delete those.

MegaMusic Pack 01.... 31 original soundtracks for your games!
http://www.aeilkema.dds.nl/mega/index.html
Gamerboy
18
Years of Service
User Offline
Joined: 25th Dec 2005
Location:
Posted: 4th Jan 2006 21:24 Edited at: 4th Jan 2006 21:25
ok i deleted them but still nothing cononel x just stands there when i press enter what am i doing wrong this is the script

please note mike king is not my real name i must have fake names on this forum due to privacy reasons.
Gamerboy
18
Years of Service
User Offline
Joined: 25th Dec 2005
Location:
Posted: 5th Jan 2006 16:49
im guessing noone knows?
Rockdrala
18
Years of Service
User Offline
Joined: 15th Dec 2005
Location:
Posted: 16th Jan 2006 07:31
how are you applying the script to the entity?

Jordan Siddall
20
Years of Service
User Offline
Joined: 1st Mar 2004
Location: UK
Posted: 21st Jan 2006 02:36 Edited at: 21st Jan 2006 02:43
Benjamin A,

I don't mean to be rude but would you be able to make the script with some changes for me?

Could you make the script so when the player walks up to a person that is following waypoints, they stop and look at you. When you back off, they continue walking.

Also when "Enter" is pressed, it plays an audio clip. ONLY when the audio has finished, you are able to press enter again and get a differant message. It's annoying when you press enter loads of times and it loads up a ton of audio clips all jumbled up.

Again when you back up they following waypoints.

This would be much usful for me and I'm sure many users.

Thanks, Jordan Siddall.
Benjamin A
19
Years of Service
User Offline
Joined: 31st Oct 2005
Location: The Netherlands
Posted: 23rd Jan 2006 16:37
I'm still working on the walking npc script, that may still take a while, got some other projects to finish first, sorry. I'm not even promising I'll ever get it done. I don't need it desperately at the moment, but I may need it in the future. So who knows, one day I may do so or it may never be done by me. For more explanation read about 8 posts above yours.....

As for the enter pressing stuff, you need to change the timing when you use different audio file lenghts. I've just but in a random number. you need to change the value to the wanted number in all the lines with " timergreater=500 "

MegaMusic Pack 01.... 31 original soundtracks for your games!
http://www.aeilkema.dds.nl/mega/index.html
Mismatch
18
Years of Service
User Offline
Joined: 10th Jan 2006
Location:
Posted: 28th Jan 2006 13:37
A little Help Please,
This Scripts do not work correct! A texture of a Wall segment or whatever appears constantly on the upper left corner, not the images I have put in the script (I've put 3 different .png images in the script).

Can you Help?

Also can someone provide the Animation 121(climbing_idle) for download, cause It is not included in my version? I want to create a siting Npc but I cannot. Animation 31 and 10 do not work!

Thanks!
Mismatch

- Even A broken Clock can Show the Time Correct, 2 times a Day... -
trotter
18
Years of Service
User Offline
Joined: 4th Feb 2006
Location:
Posted: 4th Feb 2006 17:46
Hi, i've modified your code a bit and i want to share :
5 - Walk up to an character and...nothing appen.
You have to use then "action" button to make him speak.
trotter
18
Years of Service
User Offline
Joined: 4th Feb 2006
Location:
Posted: 5th Feb 2006 02:50
Here it is :

FredP
Retired Moderator
18
Years of Service
User Offline
Joined: 27th Feb 2006
Location: Indiana
Posted: 12th Mar 2006 09:13
Nice work,Benjamin.Thanks

Not changing this sig until I get rich
mproducer
18
Years of Service
User Offline
Joined: 12th Mar 2006
Location:
Posted: 12th Mar 2006 23:02
I tried all of the code shared here, Thanks!
The 5th one is the one I would like to use, but I have a problem with it. If I use the action key anywhere on the map I still hear the converstation script running. The first four scripts don't do that but I do not see what is causing it. Obviously I am missing something. Any ideas?
lozza
18
Years of Service
User Offline
Joined: 9th Mar 2006
Location: Somewhere over the rainbow
Posted: 17th Mar 2006 08:57
This may sound like a stupid question, but since I'm young and unexperienced, how do you make the text you want to appear, appear?
For example, if you want, what you did...

Message 1: Benjamin: Hi, I'm Benjamin, how are you doing today?
Message 2: Player: I'm fine thank you, how about you?
Message 3: Benjamin: Great, I've just created 3 cool scripts for you!

How can you display the message you want?
lozza
18
Years of Service
User Offline
Joined: 9th Mar 2006
Location: Somewhere over the rainbow
Posted: 11th Apr 2006 10:23
Hey could someone help me!
Whenever I go up to the person nothing happens! He just stands there looking at me!
I don't think I did anything wrong, but can you check!
Here's the code I put in:



Is it right?
Benjamin A
19
Years of Service
User Offline
Joined: 31st Oct 2005
Location: The Netherlands
Posted: 11th Apr 2006 16:59
Change the paths, take out Program Files\The Game Creators\FPS Creator\ You only need to point to the files folder and whatever else is behind that.

Bored of indoor? Add outdoor to your FPSC games!
http://megagaming.taken.to
Need music for your games? Check the above link also!
Lizblizz
18
Years of Service
User Offline
Joined: 13th Dec 2005
Location:
Posted: 12th Apr 2006 02:18
banjanin can you do this with objects to? nice work also seems cool

Silent Hill
lozza
18
Years of Service
User Offline
Joined: 9th Mar 2006
Location: Somewhere over the rainbow
Posted: 12th Apr 2006 10:43
Nope, still doesn't work and I've got a sort of hud in the top-left corner, it looks like lipstick and diamonds! Oh, well!
Benjamin A
19
Years of Service
User Offline
Joined: 31st Oct 2005
Location: The Netherlands
Posted: 12th Apr 2006 15:53
Lizblizz, Yes it works with obkects, just take out the lines with state=xxxxx,plrdistwithin=160:rotatetoplr and it should work fine. This prevents the object from rotating towards the player.

lozza, I'll reply later, I'm on my laptop now.

Bored of indoor? Add outdoor to your FPSC games!
http://www.aeilkema.dds.nl/mega/index.html
Need music for your games? Check the above link also!
Benjamin A
19
Years of Service
User Offline
Joined: 31st Oct 2005
Location: The Netherlands
Posted: 12th Apr 2006 18:54
lozza, I've checked my scripts and compared them to yours.

Change all hudimagefile refering to png lines with these:

hudimagefine=myhuds\xxxxxxxxxxxxx.png

and the sound lines with:

sound=audiobank\hud speach\xxxxxxxxxxxxxxxx.wav

Replace the xxxxxxxxxxxx with the proper names. This should work as long as the needed files are in those 2 folders refered to.

Bored of indoor? Add outdoor to your FPSC games!
http://www.aeilkema.dds.nl/mega/index.html
Need music for your games? Check the above link also!
Tom0001
18
Years of Service
User Offline
Joined: 30th Dec 2005
Location:
Posted: 13th Apr 2006 16:38
Benjamin A,
Could you post the first script so it does only one message, with no sounds-just one message which does not repeat? PLEASE? I keep editing the script and trying and trying to get the damn thing to work but it won't. Please could you post one?

Tom

Support your local Riker 9 Chapter.
Benjamin A
19
Years of Service
User Offline
Joined: 31st Oct 2005
Location: The Netherlands
Posted: 13th Apr 2006 18:13
Tom, I normaly don't do custom scripts, but your in luck......

When the player walks up to the character the message will show. When the player presses Enter or walks away, the message will dissappear and never come back!



Bored of indoor? Add outdoor to your FPSC games!
http://www.aeilkema.dds.nl/mega/index.html
Need music for your games? Check the above link also!

Login to post a reply

Server time is: 2024-11-27 02:14:29
Your offset time is: 2024-11-27 02:14:29