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 / scancodekeypressed = now working

Author
Message
xplosys
18
Years of Service
User Offline
Joined: 5th Jan 2006
Playing: FPSC Multiplayer Games
Posted: 19th Sep 2006 00:37
Airslide brought this up in the V1.03 RC1 thread and I just had time to test it. In case anyone missed it, I just wanted to let you know that it works.

SCANCODEKEYPRESSED=X is true when X=the key code of a pressed key

Example: SCANCODEKEYPRESSED=5 is true when the TAB key is pressed

Now we have more keys to play with. I\'ve attached an image of the key codes if you need it.

Happy game making.

The forum provides a means to hide our true identity. Too bad we always screw up and let it be seen.

Attachments

Login to view attachments
Mr Flowerkohl
19
Years of Service
User Offline
Joined: 19th Jan 2005
Location: Deutschland - Germany
Posted: 19th Sep 2006 01:34
Wonderful News !!!!

so this means that some things could be possible now eh ?

- Buy menu like in counterstrike

imagine you press the B key and kind of a menu pops up in the hud
where more keys are listed to buy several weapons....or to spawn
several weapons in front of the player. maybe its possible ?! but
therefore it should have the capability to disable keys and only
let them be typed in the menu.

- Sound files like in Duke Nukem ? You press a key and your player
says "Good, bad, i`m the guy with the gun" ^^

- Hud toggle functions. Well, you could define several huds by
pressing a key, right ? disable or hide the old one and switch
to the new one.

- night vision by pressing N ? You press the N key, and all lights
set to maximum ambience and your huds getting a green transparent
overlay.

- my super mega screen wiper idea. everytime you shoot an enemy,
blood splatters onto the screen. and of course after lets say
20 enemies your screen is full of blood splatters. then you press
a key and an animation of a wiper is playing which wipes the
blood away

- interaction with NPCS. you walk to a NPC and talk to him. in a
given message box, you now can decide wether hes commiting
suicide or not. by pressing Y or N for yes or no. all scriptable


- maybe even cheating ??? you type in a special word or phrase
and the player got all weapons or 500 Health.

only a few ideas

should be possible now.

Greetings

yeah...thats the ticket !
xplosys
18
Years of Service
User Offline
Joined: 5th Jan 2006
Playing: FPSC Multiplayer Games
Posted: 19th Sep 2006 16:03
Quote: "- night vision by pressing N ? You press the N key, and all lights set to maximum ambience and your huds getting a green transparent
overlay."


Yes, and this one sounds easy to do. I don't think you would need a hud. Just up the green ambiance.

The forum provides a means to hide our true identity. Too bad we always screw up and let it be seen.

brummel
18
Years of Service
User Offline
Joined: 26th Nov 2005
Location: Sweden
Posted: 19th Sep 2006 16:59
@Mr Flowerkohl

Yes, yes, everything you sa can be done, even the buy menu thatnks to te var1=x - and var2=xcommands!

Mega FPSCpack coming soon!

Textures for MagicFPS and music.
xplosys
18
Years of Service
User Offline
Joined: 5th Jan 2006
Playing: FPSC Multiplayer Games
Posted: 19th Sep 2006 17:22
Quote: "var1=x - and var2=xcommands"


If I am not mistaken, these variable are only availible in empty's MOD. If they are available in V1.03 RC1 from TGC, please let me know.

The forum provides a means to hide our true identity. Too bad we always screw up and let it be seen.

brummel
18
Years of Service
User Offline
Joined: 26th Nov 2005
Location: Sweden
Posted: 22nd Sep 2006 17:12
Oops, i missed that this thread was about 1.03. I guess it will not work then.

Mega FPSCpack coming soon!

Textures for MagicFPS and music.
Luke314pi
18
Years of Service
User Offline
Joined: 11th Apr 2006
Location: Minneapolis, MN
Posted: 22nd Sep 2006 17:15
Does this mean we could have keypads that require a special code to unlock a door?
xplosys
18
Years of Service
User Offline
Joined: 5th Jan 2006
Playing: FPSC Multiplayer Games
Posted: 22nd Sep 2006 19:33 Edited at: 22nd Sep 2006 19:40
I want to say yes, because I can see the code in head, but testing will prove whether or not it really works. What we see or think is sometimes completely different from the way fpi scripts react.

I have already tested single keystrokes and the program detects and acts accordingly. Therefore a simple loop :STATE=1,SCANCODEKEYPRESSED=X:STATE=2 should be able to detect the first key press and if correct, be redirected to the next state to do it again, and so on.

But like I said. If you try it let me know.

I remember playing a game (The Journeyman Project, one of my all time favorites) where you had to enter a code to access some information. When you pressed a number, the program would play a "ding" sound if correct and a "buzzer" sound if wrong. Then you had to start over again but you could eventually get the code if you kept trying.

The forum provides a means to hide our true identity. Too bad we always screw up and let it be seen.

Conjured Entertainment
AGK Developer
19
Years of Service
User Offline
Joined: 12th Sep 2005
Location: Nirvana
Posted: 23rd Sep 2006 04:48 Edited at: 23rd Sep 2006 04:51
Most Excellent!
Thanks for the ScanCode Reference xplosys.


@Mr Flowerkohl
Yes, this improvement does offer countless possibilities.
Combine this with the save/load and shazam, my world is right now!

Thanks again TGC!


Don't forget to visit Conjured Entertainment
xplosys
18
Years of Service
User Offline
Joined: 5th Jan 2006
Playing: FPSC Multiplayer Games
Posted: 23rd Sep 2006 18:00
Attached is a simple Night Vision Goggle script using scancodekepressed. Works very well. License and instructions are in the script.

Remember, V1.03 is required for this to work.

The forum provides a means to hide our true identity. Too bad we always screw up and let it be seen.

Attachments

Login to view attachments

Login to post a reply

Server time is: 2024-11-23 01:32:07
Your offset time is: 2024-11-23 01:32:07