+ Reply to Thread
Page 2 of 2 FirstFirst 12
Results 11 to 18 of 18

Thread: E2: sound help

  1. #11
    Wirererer MixZim's Avatar
    Join Date
    Jul 2008
    Posts
    157

    Default Re: E2: sound help

    Aww
    I just want an answear to my question

    "Must precede an input/output/persistent variable which has a subtraction operator. Returns the current value of the variable minus the value of the variable at the end of the last execution. Note: Acceleration == $Velocity only when intervals are one second apart. "

    And I don't get it

    David Bowie is very disappointed in you!

    You probably didn't know that David Bowie is very disappointed in you, but...now you do. And no, we don't know why

  2. #12
    Developer Matte's Avatar
    Join Date
    Jan 2009
    Location
    Norway
    Posts
    3,109

    Default Re: E2: sound help

    Quote Originally Posted by nescalona View Post
    Aw dang you're right. What's wrong with me. Confused it with $. Try this:

    if (!clk() & Use == 1 & $Use == 1)

    EDIT: yeah Matte's is less redundant than mine. Don't need to check Use==1.
    That won't work either. First you check if clk is false, which it never is, because there is nothing else triggering the E2. Then you check if Use has increased by one which it never has when you ruled out interval in the first argument.
    "If anybody says he can think about quantum physics without getting giddy, that only shows he has not understood the first thing about them."
    -- Niels Bohr

  3. #13
    Wire Sofaking nescalona's Avatar
    Join Date
    Apr 2007
    Location
    Shoreline, Washington
    Posts
    1,299

    Default Re: E2: sound help

    @Matte: Sigh.

    @MixZim: "Returns the current value of the variable minus the value of the variable at the end of the last execution." $A == A - PrevA

  4. #14
    Wirererer MixZim's Avatar
    Join Date
    Jul 2008
    Posts
    157

    Default Re: E2: sound help

    Thanks, now I get it =)

    Any answear how to get my request working?

    I need interval() to make E:keyUse() change from 0-1
    with interval() the sound is repeating
    with !clk() no sound...

    David Bowie is very disappointed in you!

    You probably didn't know that David Bowie is very disappointed in you, but...now you do. And no, we don't know why

  5. #15
    Banned Nicolai1's Avatar
    Join Date
    Nov 2008
    Location
    Denmark.
    Posts
    1,251

    Default Re: E2: sound help

    if (Sound & $Sound) {
    soundPlay(Index, Length, String)
    }

    Sound being a variable (Input, persist, whatever)

    Edit:
    Fuck it I'll just give you the code for what you wanted in the post above.

    Code:
    interval(10)
    A = owner():keyUse()
    if (A & $A) {
        soundPlay(1, 0, "file/path")
    }

  6. #16
    Wire Sofaking nescalona's Avatar
    Join Date
    Apr 2007
    Location
    Shoreline, Washington
    Posts
    1,299

    Default Re: E2: sound help

    Two have been posted in this thread already. (just one works though heh)

    http://www.wiremod.com/forum/help-su...tml#post124379

    EDIT:Nicolai's works too

  7. #17
    Developer Matte's Avatar
    Join Date
    Jan 2009
    Location
    Norway
    Posts
    3,109

    Default Re: E2: sound help

    Try this:
    Code:
    @persist E:entity Use
    
    runOnTick(1)
    
    E=owner()
    Use=E:keyUse()
    
    if ($Use>0) {E:soundPlay(1,1,"Whatever")}

    EDIT: Wah! Triple ninja'd
    Last edited by Matte; 08-07-2009 at 04:06 PM.
    "If anybody says he can think about quantum physics without getting giddy, that only shows he has not understood the first thing about them."
    -- Niels Bohr

  8. #18
    Wirererer MixZim's Avatar
    Join Date
    Jul 2008
    Posts
    157

    Default Re: E2: sound help

    Yep, it works perfectly. Exactly how I wanted it

    Thank you for the support

    David Bowie is very disappointed in you!

    You probably didn't know that David Bowie is very disappointed in you, but...now you do. And no, we don't know why

+ Reply to Thread
Page 2 of 2 FirstFirst 12

Similar Threads

  1. Adding sound files to sound emitter
    By Dragonheart in forum Installation and Malfunctions Support
    Replies: 2
    Last Post: 07-04-2009, 10:33 PM
  2. Adding A Sound To The Sound Emitter?
    By SneakyTaco in forum Installation and Malfunctions Support
    Replies: 3
    Last Post: 04-16-2009, 05:47 PM
  3. Sound Emitter Sound level.
    By ICDWILL117 in forum Wiremod General Chat
    Replies: 5
    Last Post: 11-18-2008, 05:06 PM
  4. advanced sound emitter emits only 1 sound
    By rickumans in forum Installation and Malfunctions Support
    Replies: 0
    Last Post: 02-27-2008, 06:41 AM
  5. Is It Possible To End A Looping Sound From The Sound Emitter?
    By hizzeh in forum Installation and Malfunctions Support
    Replies: 0
    Last Post: 05-06-2007, 09:13 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
proceed-collector
proceed-collector
proceed-collector
proceed-collector
linguistic-parrots
linguistic-parrots
linguistic-parrots
linguistic-parrots