Scripts / Play video if entity shot?

Author
Message
Crankenstein
9
Years of Service
User Offline
Joined: 1st Dec 2015
Location:
Posted: 9th Feb 2016 20:06
Hi is it possible to play a video if an entity is shot at.
I would like player to shoot a camera which would trigger the video.
Thanks in anticipation.
Martin(Crankenstein)
Pirate Myke
Forum Support
14
Years of Service
User Offline
Joined: 31st May 2010
Location: El Dorado, California
Posted: 9th Feb 2016 20:52
Not sure we can call the video path from script yet. I will have to do some research.

Might only be able to assign the video thru the story zone.
Intel(R) Core(TM)2 Quad CPU Q6600 @ 2.40GHz, 2400 Mhz, 4 Core(s), 4 Logical Processor(s), 8gb RAM, Nvidia gtx660, Windows 7 Pro 64bit, Screen resolution 1680 x 1050.

Belidos
3D Media Maker
9
Years of Service
User Offline
Joined: 23rd Nov 2015
Playing: The Game
Posted: 9th Feb 2016 21:55
I think at the best you can do is script it so that a hidden storyzone is spawned when you hit the enemy at the moment, I might be wrong though.
cybernescence
GameGuru Master
11
Years of Service
User Offline
Joined: 28th Jan 2013
Playing: Cogwheel Chronicles
Posted: 9th Feb 2016 22:51 Edited at: 10th Feb 2016 11:52


Edit: I forgot to add some instructions. Copy the script above into a file and name it playvideoifhit.lua in the scriptbank folder. Then open properties of your camera entity and assign this script in the 'Main' property. Also set 'Static Mode' to 'No' (to make it active and able to run the script), make sure 'Strength' (health) has a value, say 25. And add your video into the 'Sound1' property slot at the bottom (place your video in the videobank folder and select it from there).

Cheers.
Leaning Objects To The Side
17
Years of Service
User Offline
Joined: 3rd Jan 2007
Location:
Posted: 12th Feb 2016 21:21
Awesome Script!!
Quote: "cybernescence"
Great Job!! thanks for the share. keep up the good work. I hope you have a great day.
I hope all have a Great day!
Crankenstein
9
Years of Service
User Offline
Joined: 1st Dec 2015
Location:
Posted: 15th Feb 2016 12:58
Brilliant script thankyou very much.
This opens a whole new realm of possibilities
Crankenstein

Login to post a reply

Server time is: 2024-12-22 13:14:38
Your offset time is: 2024-12-22 13:14:38