Jump to content

[Quest] Sistema de matar con sonido


Robert

Mensajes recomendados

Bueno me encontre con esto hace ya semanas no me acuerdo ni donde y os lo traigo a vosotros tambien. Lo que hace el sistema es que a cada muerte que hagas dice un sonido como monsterkill, ultrakill, pentakill etc. Y para que sigan tienes que matar en un intervalo de 20 segundos. Esto solo lo vas a escuchar tu la otra persona no, solo si te mata ella primero.


 


Entrais en game.py y buscais:



"PlayMusic" : self.__PlayMusic,

Debajo de ella añadireis esto:



"PlayMusicxd" : self.__PlayMusicxd,

Allí os copiáis de los TAB que trae el de arriba.


Después buscáis esto:



snd.FadeInMusic("BGM/" + musicInfo.fieldMusic)

Y debajo añadiréis esto:



[TAB]def __PlayMusicxd(self, filename):
[TAB][TAB]snd.PlaySound("BGM/" + filename)

Aquí los [TAB] es la tecla tab no la copiéis :)


 


Ahora la quest:



quest pentakillxd begin
state start begin
when kill with npc.is_pc() begin
if get_time()< pc.getqf("grupo") then
pc.delqf("grupo")
pc.setqf("one", get_time()+20)
cmdchat("PlayMusicxd onekill.mp3")
elseif get_time()< pc.getqf("one") then
pc.setqf("doble", get_time()+20)
cmdchat("PlayMusicxd doublekill.mp3")
elseif get_time()< pc.getqf("doble") then
pc.setqf("triple", get_time()+20)
cmdchat("PlayMusicxd triplekill.mp3")
elseif get_time()< pc.getqf("triple") then
pc.setqf("quadra", get_time()+20)
cmdchat("PlayMusicxd quadra.mp3")
elseif get_time()< pc.getqf("quadra") then
pc.setqf("pentakill", get_time()+20)
cmdchat("PlayMusicxd pentakill.mp3")
elseif get_time()< pc.getqf("pentakill") then
pc.setqf("hexakill", get_time()+20)
cmdchat("PlayMusicxd hexakill.mp3")
elseif get_time()< pc.getqf("hexakill") then
pc.setqf("dominating", get_time()+20)
cmdchat("PlayMusicxd dominating.mp3")
elseif get_time()< pc.getqf("dominating") then
pc.setqf("neutralized", get_time()+20)
cmdchat("PlayMusicxd neutralized.mp3")
elseif get_time()< pc.getqf("neutralized") then
pc.setqf("unstoppable", get_time()+20)
cmdchat("PlayMusicxd unstoppable.mp3")
elseif get_time()< pc.getqf("unstoppable") then
pc.setqf("unstoppable", get_time()+20)
cmdchat("PlayMusicxd unstoppable.mp3")
else
pc.setqf("grupo", get_time()+10)
cmdchat("PlayMusicxd onekill1.mp3")
end
end
end
end

Y por ultimo los sonidos que los meteis en la carpeta BGM.


Debes iniciar sesión para ver el contenido del enlace en esta publicación.


Enlace para comentar
Compartir en otros sitios

  • 5 years later...
  • 3 weeks later...

Unirse a la conversación

Puedes publicar ahora y registrarte más tarde. Si tienes una cuenta, regístrate para publicar con su cuenta.

Guest
Responder a este tema...

×   Has pegado contenido con formato .   Eliminar formato

  Only 75 emoji are allowed.

×   Tu enlace se ha incorporado automáticamente.   Mostrar un enlace en su lugar

×   Se ha restaurado el contenido anterior. .   Borrar editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recientemente navegando por este tema   0 miembros

    • No hay usuarios registrados visitando esta página.
×
×
  • Crear nuevo...