Graal Forums  

Go Back   Graal Forums > General Forums > Graal Main Forum (English)
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 04-14-2014, 12:17 PM
Xadis Xadis is offline
Registered User
Join Date: Feb 2014
Posts: 14
Xadis is on a distinguished road
How do I add music

How can I add music to a server..
Reply With Quote
  #2  
Old 04-14-2014, 05:13 PM
Jakov_the_Jakovasaur Jakov_the_Jakovasaur is offline
Deleted by Darlene159
Jakov_the_Jakovasaur's Avatar
Join Date: Sep 2013
Location: Deleted by Darlene159
Posts: 354
Jakov_the_Jakovasaur has much to be proud ofJakov_the_Jakovasaur has much to be proud ofJakov_the_Jakovasaur has much to be proud ofJakov_the_Jakovasaur has much to be proud ofJakov_the_Jakovasaur has much to be proud ofJakov_the_Jakovasaur has much to be proud ofJakov_the_Jakovasaur has much to be proud of
hello!

first you need to ensure that custom music files can be downloaded by the clients of other players, to do this you need to add an entry to your servers 'Folderconfig'

for the sake of an example, i am currently creating a server called Lardene (after my great grandmother, bless her soul ), so in folder config i have added:

file music/lardene_*.mp3

'file' means that this is a custom file rather than a level/sword/shield/head/body, 'music' is the name of the folder i have assigned for music because i like to keep my server organised, 'lardene_' is the prefix i use because you should always identify your servers files to avoid conflict (and force them to download to a convenient folder), and the '*' is a wildcard which allows any filename beyond the prefix, and ending it with 'mp3' means this only works for mp3 files

then you want to ensure that you can actually upload music files to this folder, so in rc type '/openrights', then click the 'Folder Rights' tab, and add a line such as 'rw levels/music/lardene_*.mp3', and finally save your rights

once this is setup and you have uploaded the file to the specified folder you can now play the music file clientside through script, a very basic example of how to do this within a singular level npc is as follows:

PHP Code:
//#CLIENTSIDE
function onPlayerEnters()
  
playlooped("lardene_inside_01.mp3"); 
i personally recommend joining a class script to npcs rather than playing files directly, so that if you want to change the way music plays you dont then have to go back and edit a lot of different npcs, an alternative would be to play music within a weapon npc according to what level you are within, which is helpful for playing music on gmaps

happy to be of help!
__________________
This signature has been deleted by Darlene159.

Last edited by Jakov_the_Jakovasaur; 04-14-2014 at 05:27 PM..
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 01:38 AM.


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