Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Scripting (https://forums.graalonline.com/forums/forumdisplay.php?f=8)
-   -   a Flute (https://forums.graalonline.com/forums/showthread.php?t=81537)

Knightmare1 08-28-2008 07:03 PM

a Flute
 
my computer is too bad to play graal, and i wanted to make something, so i thought i would try a flute.

PHP Code:

function onPlayerEnters()
{
  
setimg"test_flute.png" );
}

function 
onWeaponFired()
{
  while(!
this.keydown(6))
  {
    for(
this.0this.<4this.k++)
    {
      if(
keydown(this.k))
      {
        
setani("test_flute","")
        
play("test_flute_"@this.k@".wav")
      }
    }
  }



Codein 08-28-2008 07:05 PM

Nice and simple. I suppose you could add more keys and stuff for different notes :)

Deas_Voice 08-28-2008 07:26 PM

Quote:

Originally Posted by Codein (Post 1418678)
Nice and simple.

^
what he said ^_^

but, thats a Weapon NPC right?
to me it nerly look like a gani script >;o


All times are GMT +2. The time now is 09:25 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.