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 / Show Image when player enters Trigger Zone?

Author
Message
Barty Games
8
Years of Service
User Offline
Joined: 26th May 2016
Location:
Posted: 29th Nov 2020 01:53
Hi, My name is Jared, and i'm new to this forum and this game engine. I discovered it was free and open source 2 days ago, and i've been having a blast playing around with it making my own levels and stuff, but i've run into a roadblock. When the player enters a trigger zone, I want an image to display on the screen (HUD) and when he leaves the zone, to delete the GameObject. Or even text would be great, but not sure how to do this. I've found this old community guide and followed this tutorial:



I've messed with everything and tried just about everything to my knowledge, am i missing something? This isn't like unity and doesnt show any errors or any debug logs, so i dont understand what im missing or what its not showing. And guides or a little explanation would probably help me the most. Thanks so much!

Attachments

Login to view attachments
ncmako
12
Years of Service
User Offline
Joined: 19th Feb 2012
Location: Hendersonville,NC
Posted: 29th Nov 2020 12:56 Edited at: 29th Nov 2020 12:59
[href]null[/href]Hi Barty, and welcome Your on the right track. The community guide has a wealth of useful info to help you.
I assume your using vanilla fpsc V1.20 ? To help you better understand what these commands do/mean grab the complete Syntax list here... https://forum.thegamecreators.com/thread/180924
It is located at the top on this forum. To display a simple image/hud make sure your file path is correct in the script and centered on screen ( x & y =50 )
Note: use only .dds .tga .png for now until you become familiar


To display a simple image when player enters a triggerzone follow the guide on page #75, player steps into zone show image.

Here when the player steps into zone, condition is met, then show image.
Then move to next state where it waits until player steps OUT of the zone and image is not displayed anymore and moves back to state=1 to cycle again.

The whole working script would look like this...

Displaying simple text is a little more in depth but the same approach. Any problems just ask
** WHERE'S MY eXplosys ? **
Barty Games
8
Years of Service
User Offline
Joined: 26th May 2016
Location:
Posted: 29th Nov 2020 15:19
Hey, thanks for the response! I'm using the BlackIce Mod actually (for the menu editor lol), would this have any interference with this script? I'm going to try it a bit later when I get a chance and I'll let you know how it goes. Thanks!
ScooT9
7
Years of Service
User Offline
Joined: 29th Mar 2017
Playing:
Posted: 29th Nov 2020 15:41
for faster help you can join the FPSC discord server https://discord.gg/uSVey7EHhG
hi, i'm a random guy who's making random games with random game engines for random reasons

ncmako
12
Years of Service
User Offline
Joined: 19th Feb 2012
Location: Hendersonville,NC
Posted: 29th Nov 2020 16:47
@ Barty As ScooT9 said, join us at Discord. There are way more members now to help you then here.
I see, your using Black Ice Mod. Good. Much more advanced. No, the same commands work with BIM, it just has more commands added
and many extra features than vanilla fpsc. One thing I forgot to mention is fpsc uses DX9. Its always good idea to run the DX9c installer
(located in the "tools" folder dxwebsetup.exe) just to make sure if any missing DX files are installed.
** WHERE'S MY eXplosys ? **

Login to post a reply

Server time is: 2024-11-21 08:36:34
Your offset time is: 2024-11-21 08:36:34