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


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
I need help getting maps made
Acies Offline
Posting Freak

Posts: 1,643
Threads: 60
Joined: Feb 2011
Reputation: 73
#3
RE: I need help getting maps made

You can use random timers to trigger lightning sounds + effects. Combining that with sanity loss and character sounds.. Well start out with adding a timer:
For example when entering the map - or entering an area - or option C of your choice.
AddTimer("LightingStrike", RandFloat(8.0, 15.5), "LightingStrikeT");

The RandFloat means what it will randomize a value between 8-15 seconds. You can change this to whatever you want. The difference between RandInt and RandFloat is that "Float" allows for values with decimals ~ 9.3 seconds for example. "Int" is numbers without decimals.



void LightingStrikeT(string &in asTimer)
{AddTimer("LightingStrike", RandFloat(8.0, 15.5), "LightingStrikeT");
//Play various sounds
//Remove sanity



Adding the timer within the function it executes will allow it to repeat itself. To remove the timer - simply have a
RemoveTimer(etc. etc.) within another function. You might also want to check for the general location of the player (optimizing in case you have a large map / or want localized sounds). Simply create large scriptareas and change a variable from 0 to 1 upon entering the area. Change that value back to 0 if the player leaves the area.

Adding this within your timer function will execute lines below this if the value is set to 1 (ergo player is in that area).
if(GetLocalVarInt("PlayerInAreaX") == 1)


That would allow you to play sounds near the player, and possibly have lightning effects (turning a flickering pointlight on and off for example) which occur where the player is, at a random time.


To get a female voice for your character you will need to perform a full conversion. This link might help you further:
http://www.frictionalgames.com/forum/thread-19019.html

[Image: mZiYnxe.png]


(This post was last modified: 12-07-2012, 01:23 AM by Acies.)
12-07-2012, 01:23 AM
Find


Messages In This Thread
I need help getting maps made - by AveryLuna - 12-06-2012, 09:52 PM
RE: I need help getting maps made - by AveryLuna - 12-07-2012, 12:13 AM
RE: I need help getting maps made - by AveryLuna - 12-07-2012, 03:39 AM
RE: I need help getting maps made - by Acies - 12-07-2012, 01:23 AM
RE: I need help getting maps made - by AveryLuna - 12-07-2012, 02:34 AM
RE: I need help getting maps made - by AveryLuna - 12-07-2012, 04:12 AM
RE: I need help getting maps made - by AveryLuna - 12-07-2012, 04:58 AM
RE: I need help getting maps made - by AveryLuna - 12-07-2012, 05:11 AM
RE: I need help getting maps made - by AveryLuna - 12-07-2012, 05:48 AM
RE: I need help getting maps made - by AveryLuna - 12-07-2012, 06:26 AM



Users browsing this thread: 1 Guest(s)