Jump to content

Photo

Change bomb place sfx


  • Please log in to reply
10 replies to this topic

#1 Christian

Christian

    Summoner

  • Members
  • Real Name:Chris
  • Location:New Jersey

Posted 27 November 2008 - 12:46 AM

So i decided to be smart and made an item script that change the sfx of a bomb being place. I ran without luck because it seems that the "original" sfx of a bomb being place still ran on top of the script i made.
CODE

Const int SFX_BOMB = 0;//Sfx sound to play when a bomb is placed

item script sfxbombplaced{
        Void run(){
    Game->PlaySound(SFX_BOMB);
     }
}

help asap!

Edited by drzchulo973, 27 November 2008 - 02:29 AM.


#2 Elmensajero

Elmensajero

    Doyen(ne)

  • Members
  • Real Name:John
  • Location:Raleigh, North Carolina

Posted 27 November 2008 - 12:57 AM

Why don't you just change the sound effect directly with the sound effect editor? I don't think you can prevent the original sound from playing with scripting.

#3 Christian

Christian

    Summoner

  • Members
  • Real Name:Chris
  • Location:New Jersey

Posted 27 November 2008 - 01:05 AM

Because i want to reserve that spot for a sound effect to play everytime i press a button on the active subscreen to select an item. And yes there is a way, by making scripted L_WEAPON bombs. But im not that experienced with zscript yet.

#4 Joe123

Joe123

    Retired

  • Members

Posted 27 November 2008 - 03:10 AM

Script bombs.
That's what I did.

#5 Christian

Christian

    Summoner

  • Members
  • Real Name:Chris
  • Location:New Jersey

Posted 27 November 2008 - 03:21 AM

I'll try to script an L_WEAPON bombs. It will take me a bit long, while I learn how to script more in depth..but it should'nt be that difficult to do anyways.

#6 Gleeok

Gleeok

    It's dangerous to dough alone, bake this.

  • Members
  • Real Name:Pillsbury
  • Location:Magical Land of Dough

Posted 27 November 2008 - 07:06 AM

I thought you could change theitem SFX in the item editor? I could be wrong though.

If not, then why not just switch the order of the sfx for those two sounds? move SFX_21 to the 70 (or whatever) slot, and have slot 21 custom.

#7 Christian

Christian

    Summoner

  • Members
  • Real Name:Chris
  • Location:New Jersey

Posted 27 November 2008 - 07:22 AM

QUOTE(Gleeok @ Nov 27 2008, 07:06 AM) View Post

I thought you could change theitem SFX in the item editor? I could be wrong though.

If not, then why not just switch the order of the sfx for those two sounds? move SFX_21 to the 70 (or whatever) slot, and have slot 21 custom.


No you can't, it only has the"explosion" slot in the item editor. That's the only sfx you can change from the bombs item...

As far as switching the sfx slot to have slot 21 custom..I believe you can't do that. If I make slot_21 to have the sfx to play when I select an item, then that same sfx slot will be used each time a bomb is placed.

The only way around it, is if I create scripted bombs just like joe suggested icon_shrug.gif

#8 Gleeok

Gleeok

    It's dangerous to dough alone, bake this.

  • Members
  • Real Name:Pillsbury
  • Location:Magical Land of Dough

Posted 27 November 2008 - 07:33 AM

QUOTE(drzchulo973 @ Nov 27 2008, 04:22 AM) View Post

No you can't, it only has the"explosion" slot in the item editor. That's the only sfx you can change from the bombs item...


Hehe, That's right. The bombs should have two action sfx, not one. Perhaps was overlooked in the implementation of the editor.


But, you know that you can overwrite any existing sxf right? They're not really hardcoded into the game as they're kept neatly in sfx.dat.



I will say that rescripted bombs have a certain flair to them.

Edited by Gleeok, 27 November 2008 - 07:33 AM.


#9 Christian

Christian

    Summoner

  • Members
  • Real Name:Chris
  • Location:New Jersey

Posted 27 November 2008 - 07:39 AM

QUOTE(Gleeok @ Nov 27 2008, 07:33 AM) View Post

But, you know that you can overwrite any existing sxf right? They're not really hardcoded into the game as they're kept neatly in sfx.dat


You can? How the hell do you do that?? icon_confused2.gif

#10 Joe123

Joe123

    Retired

  • Members

Posted 27 November 2008 - 02:02 PM

You can, but it's certainly not worth your effort.

Re-scripting the bombs just for the sake of having two different SFX probably isn't either though; you need a section in your global script to change the damage the explosion deals too otherwise they'll deal 0 damage.

I scripted mine so that they'd fall down when Link's on Epona; I wouldn'tve done it just for the sake of the sfx.
It is quite nice to have the item not dissapear from the subscreen when you have no bombs left too though admitedly.

#11 Christian

Christian

    Summoner

  • Members
  • Real Name:Chris
  • Location:New Jersey

Posted 27 November 2008 - 07:10 PM

You're probably right. I have to admit, that sfx that plays everytime you choose an item on the subscreen, its quite annoying. Can't stand it. But hey there's nothing we or i can do to change that. Or if the developers decide to give us another slot for a custom selector item. ^_^.


0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users