Complex in/output system to control sound speed with intelligence distance

Discussion in 'Mapping Questions & Discussion' started by Harry64, Oct 3, 2011.

  1. Harry64

    Harry64 L1: Registered

    Messages:
    6
    Positive Ratings:
    1
    Hello everybody!
    This is my first Thread here so if this Thread does not fit here please excuse me.


    I am mapping now for years and I know how to map complex in/output systems in maps.
    but now I found a problem that I cannot solve alone.

    I want to make an easter map for tf2.
    In this map the intelligence will be an big Easteregg and it is hidden on the map somewere. I have now 42 possible places where the Intelligence (Egg) could be hidden randomly by teleporting.

    I will change the hud texture so that the hud dont show where the neutral Egg is hidden. only a silent sound should be played from the egg and a little sparkling particle script should point where its hidden.

    you need do bring the egg to the center of the map.

    ok. that will all work but I want something special in the map when picking up the intelligence. MUSIK.
    and now the problems begin. 3 days now I work on this problem with no solution. :crying:

    I want that these things to happen:

    * when looking to the egg if you not too far away the teams should hear a sound like ( the enemy has discovert the easter egg)
    (( tested now and works with no problems. ))

    * Pick up the intelligence (egg) the musik plays. (from the intelligence so other players know where they should search for the player holding the egg)
    * Getting closer to the center of the map the musik should play faster. 3 changes or more till it reaches the center.
    * on drop, the musik should have a pitch of 30.
    * on pickup again the musik should play with the right pitch again.
    * every theam should have ther own musik.

    1)) try:

    I build func_triggers with an filter_name. that should it recognize. right? WRONG!!!
    I dont know why but the triggers dont recognize the Intelligence.
    I tryed everything, every possible setting but the func_triggers dont recognize the intelligence. I even parented a info_target to the intelligence and put the name of that in the filter for the triggers... dont work.

    2)) next try:

    point_proximity_sensor.
    works for me. it detects the intelligence and so I could work with it.
    I used it with a logic_compare so I got a OnGreaterThan and a OnLessThan output that worked.

    with these outputs I sended them to two logic_relays so I could disable them (cause to set the sound to pitch 30 at dropping the intelligence I needed to disable them first or the pitch would be set instantly to the value of the logic_relays cause the logic_compare sends the signal non stop to the logic_relays. (logic_case and logic_compare cant be enabled or disabled so I use relays instead)

    now its like that:

    if I drop the intelligence the logic_relays will be disabled and after that the sound will be set to pitch 30. if picked up the intelligence the logic_relays will be enabled and the sound plays in the right speed. on capture the logic_relays will be disabled and after that the sound will be stopped. (if not done in this order the sound will not be controllable anymore cause of a bug in the sound system. never change the pitch of a stopped sound... you cant stop it anymore.)

    but.....
    I wanted 3 sound speed changes or if possible much more.... and with only one logic_compare I cant get more outputs out of it. so I need a entity that could compare more values with the imput value.


    3)) next try:

    I sended the point_proximity_sensor output as pitch change directly to the ambient_generic. (that has a funny, really fast changing and seamless pitch change.) but way toooooo fast. i cant go 2 steps from the point_proximity_sensor away till the pitch is like hamsters on helium.

    I have never tryed somthing like math_remap..... I dont know if it would be possible to combine them to get results like pitch 50 - 140.



    my opinion:

    the first try would allow me to set as many speed changes as a want if the triggers would recognize the intelligence.

    the second try would be an easy, functionally and accurate way to create what I want if someone has an idea how to make more pitch changes.

    the third try would be the beautifullest way if someone has an idea how to get only these outputs 50 - 140.


    I hope I dont talked too much but I dont have anyone in my friendslist that could help me.


    thanks for listening and hopefully someone of you could help me. that would be awesome ^^ :wow:
    Harry64
     
    Last edited: Oct 3, 2011
  2. Terwonick

    Terwonick L6: Sharp Member

    Messages:
    278
    Positive Ratings:
    88
    While I will be of no help to you, you should join our steam chat and see if Grazr is in there, I know he likes complex entity stuff. a link to the steam chat is in the top bar, under the featured maps. Good luck, and I hope you can get it working, it sounds like a fun addition to the tf2 gamemodes.
     
  3. Harry64

    Harry64 L1: Registered

    Messages:
    6
    Positive Ratings:
    1
    thanks for the info! I will join tomorrow if I find some time. ^^
     
  4. Fr0Z3nR

    aa Fr0Z3nR Creator of blackholes & memes. Destroyer of forums

    Messages:
    6,391
    Positive Ratings:
    4,902
    I think A Boojum Snark or Snacks would also be equally as helpful...

    but posing the question to the general chat would also suffice.
     
  5. Harry64

    Harry64 L1: Registered

    Messages:
    6
    Positive Ratings:
    1
    I did not found the time to chat but now I think I found a solution. I tried it now and it works. fine tuning is needed but it works and now I have 5 pitch changes and be able to add much more.

    I will post the solution soon and thanks for the hint with the chat. ^^
     
  6. Harry64

    Harry64 L1: Registered

    Messages:
    6
    Positive Ratings:
    1
    So I finally removed the new bug that I had with my new system. when I drop the intelligence when I stand on one of the other team then it did not stop the drop pitch change from me. it was I think just a timing error. now I got some pictures for you so that you can take a look at my new sound system.
    this is the system for both teams, red and blue.

    [​IMG]

    you see from left to right the point_proximity_sensor and then the logic_timer that will trigger the compare command to the logic_compare next to it. then you see 5 logic_relays, these relays are enabled or disabled by the logic_compare and after that they are triggered by the logic_timer.
    ( the one in the middle is there to send a 0 to the math_counter to trigger it... but I think I remove it and send the signal directly from the logic_timer.)

    so the logic_relays that was enabled sends now the trigger signal "add 1" to the math_counter and these 2 sends a outValue - inValue signal to the logic_case. if red has taken the intelligence only the red math_counter is enabled and sends the signal to the logic_case. in the logic_case is then set the pitch for the ambient_generic. ^^

    here are some ingame pictures from the signals.


    in this one you see every relay is enabled cause the intelligence is far away and a blue is holding it.
    [​IMG]


    in this one I have the intelligence and stand very close. you can clearly see that the 0 trigger in the center is the only trigger that sends a signal to the math_counters and it plays the red sound very fast.
    [​IMG]


    in this one I was also holding the intelligence but I was a bit further away.
    [​IMG]


    so now everything looks good so far. I hope I find the time to create the map for this new mod I made.
    so good night. ^^
     
    • Thanks Thanks x 1
    Last edited: Oct 7, 2011