Author Topic: [XP] Berans' iPod script v1.15-final  (Read 15369 times)

Offline Berans

  • Awakened Visionist
  • **
  • Posts: 75
  • LV: 10
  • Gender: Male
  • Corn = win...it's yellow
    • View Profile
[XP] Berans' iPod script v1.15-final
« on: August 08, 2008, 07:06:21 PM »
iPod script
Authors: Berans
Version: 1.15-final
Type: Music Player
Key Term: Misc Add-On


Introduction

I made this script as a response to a request on a different forum, and decided it was my first script decent enough to post up here.
It simply displays a nice "iPod" graphic, and lets you pick songs to play from a list.

Features

  • Relatively easy setup
  • IPod Graphic
  • Allows for as many songs as you wish
  • Allows for author and genre names
  • Allows unlockable songs
  • Currently selected song is remembered, and saved in your save game
  • Unlocked songs saved in save game
  • Entirely Lag-free
  • Map as background
  • Option to have the current BGM change with your selected song
  • iPod menu with some for-fun, customizable options
  • NEW: iPod menu now features a "sort-by" option (title, author or genre). Your selected option is saved with your game

Screenshots



If you do not want to download the demo, save the following 2 images to your computer, and import them into your game as outlined in the script
(click to show/hide)

Demo

New Demo:
iPod Demo v1.00-beta

Note: No new demo for v1.12, just paste the new script in the old demo to test functionality.

Script

The script should be placed somewhere above main, and below Scene_Debug
(click to show/hide)

Instructions

Instructions in the script

Compatibility

Warning, WILL corrupt old savegames.
Otherwise, should be compatible with just about anything, including the SDK

Credits and Thanks

  • Berans - Creating the script
  • Blizzard - Learnt a lot from his scripts in terms of general knowledge and scripting conventions
  • Sniper308 - For requesting the script and suggesting many of the great features
  • LandOfShadows - Use of one of his windowskins in the demo

Author's Notes

Feel free to ask me any questions and PLEASE tell me if you find a bug.
I'm also quite willing to make customizations and such for this, provided they are within reason, and I have the time.

Have fun with it people ^_^

Don't forget to credit me if you use this in your game :P
« Last Edit: February 21, 2009, 12:52:47 PM by shdwlink1993 »

Offline Blizzard

  • This sexy
  • Administrator
  • has over 9000 posts
  • *****
  • Posts: 19930
  • LV: 642
  • Gender: Male
  • Magic midgets.
    • View Profile
    • You're already on it. (-_-')
Re: [XP] Berans' IPod script v0.98-beta
« Reply #1 on: August 08, 2008, 07:24:45 PM »
I fixed a thing or two in your post. :)
Check out Daygames and our games:

King of Booze      King of Booze: Never Ever      Pet Bots
Drinking Game for Android      Never have I ever for Android      Pet Bots for Android
Drinking Game for iOS      Never have I ever for iOS      Pet Bots for iOS
Drinking Game on Steam


Quote from: winkio
I do not speak to bricks, either as individuals or in wall form.

Quote from: Barney Stinson
When I get sad, I stop being sad and be awesome instead. True story.

Offline Berans

  • Awakened Visionist
  • **
  • Posts: 75
  • LV: 10
  • Gender: Male
  • Corn = win...it's yellow
    • View Profile
Re: [XP] Berans' IPod script v0.98-beta
« Reply #2 on: August 08, 2008, 07:26:42 PM »
Thanks lol...I need sleep :P
But I want feedback...I'm so conflicted

Offline Fantasist

  • Lexima Warrior
  • *******
  • Posts: 2222
  • LV: 146
  • Gender: Male
    • View Profile
    • Blog
Re: [XP] Berans' IPod script v0.98-beta
« Reply #3 on: August 08, 2008, 08:01:40 PM »
Wow! Nice! :clap:

I've downloaded the demo, but I'm a bit busy to try it out. I'll post my feedback.

And a power up for you :)
Do you like ambient/electronic music? Then you should promote a talented artist! Help out here. (I'm serious. Just listen to his work at least!)

The best of freeware reviews: Gizmo's Freeware Reviews



Offline Berans

  • Awakened Visionist
  • **
  • Posts: 75
  • LV: 10
  • Gender: Male
  • Corn = win...it's yellow
    • View Profile
Re: [XP] Berans' IPod script v0.98-beta
« Reply #4 on: August 08, 2008, 08:07:17 PM »
I guess I'll just go to sleep and patiently await people's responses  :negative:

Offline Juan

  • Ethereal Devastator
  • ****
  • Posts: 409
  • LV: 47
  • Gender: Male
  • Evil Twin
    • View Profile
Re: [XP] Berans' IPod script v0.98-beta
« Reply #5 on: August 08, 2008, 10:04:01 PM »
Looks good. *Adds to the form script listing*
Dropbox Who need luck when you can make your own.
(click to show/hide)

Offline Berans

  • Awakened Visionist
  • **
  • Posts: 75
  • LV: 10
  • Gender: Male
  • Corn = win...it's yellow
    • View Profile
Re: [XP] Berans' IPod script v0.98-beta
« Reply #6 on: August 09, 2008, 12:03:59 AM »
*wheee* I'm honoured lol. Once it's not so cold anymore I'll start working on a better demo to display all the features better XD

Offline Diokatsu

  • Wind God
  • Lexima Warrior
  • *******
  • Posts: 2805
  • LV: 52
  • Gender: Male
  • Fuck yes.
    • View Profile
Re: [XP] Berans' IPod script v0.98-beta
« Reply #7 on: August 09, 2008, 12:32:26 AM »
Wows!!! Epic win!!!!!!



*powers up*

Offline Berans

  • Awakened Visionist
  • **
  • Posts: 75
  • LV: 10
  • Gender: Male
  • Corn = win...it's yellow
    • View Profile
Re: [XP] Berans' IPod script v0.98-beta
« Reply #8 on: August 09, 2008, 01:35:40 AM »
I'm glad people like it. And remember to report any bugs you find :P
Any suggestions for improvement? I'm considering having the "BGM_CHANGER" option also remember the song when you change map, if another option is on, not sure if I can do it though. I'll have to look...breakfast comes first :P

EDIT: After some consideration, I think I'll leave out the option for now. It would complicate an otherwise simplish script a lot.
I may still consider it in the future, but, consider this a final version for now. Still some minor tweaks to go, but the functionality will remain the same unless someone has a good idea for me to add.

UPDATED  to version 0.99-beta, with an extra implemented features and some near-invisible glitches worked out. Please tell me if something's wrong.

UPDATED to version 1.00-beta, another extra feature added and the code cleaned up somewhat. This is the final beta release, and won't be changed unless someone finds bugs. I'll still happily take customization requests though ;)

UPDATED to version 1.12-final. Another new features, song sorting. Allows you to sort your song list by either Title, Author or Genre. Also saves your last selected sort option with your savegame. Enjoy, and please report any bugs you find.

EDIT2: It appears I've left a rather huge bug in the last version of my script. I don't suggest using v1.12 until I've fixed this, as things go haywire when you don't unlock songs in order or have initial songs with gaps in between. I'm about halfway through fixing that up, so please bare with me

EDIT3: Finally, the forum's back up, the script's updated and well and, so far as I can tell, working flawlessly. Thanks for your patience XD

EDIT4: Made a quick bugfix involving unlocking songs before the iPod's been opened at least once. Since all it was, was relocating 3 lines of code, it wasn't worthy of its own version number

UPDATED with another minute fix for my own stupidity
« Last Edit: August 15, 2008, 04:04:03 AM by Berans »

Offline Starrodkirby86

  • Kirby de Varita Estelar
  • Guardian of Chaos
  • ********
  • Posts: 3282
  • LV: 194
  • Gender: Male
  • ~!
    • View Profile
    • The Archive of Starrodkirby86
Re: [XP] Berans' iPod script v1.13-final
« Reply #9 on: August 15, 2008, 04:23:08 AM »
I taken a gander at the Ipod script. I love the overlays, and I thought that was quite interesting. Now, if you're going to be playing a game that Ipods weren't created or aren't in the correct generation, it would turn into a sound test or something. Would the coordinates required for a graphic change and all, can they be edited via Spriteset_Ipod and Ipod_Dummy, or am I just being a total idiot and getting it off the mark?  :???:

What's osu!? It's a rhythm game. Thought I should have a signature with a working rank. ;P It's now clickable!
Still Aqua's biggest fan (Or am I?).



Offline Berans

  • Awakened Visionist
  • **
  • Posts: 75
  • LV: 10
  • Gender: Male
  • Corn = win...it's yellow
    • View Profile
Re: [XP] Berans' iPod script v1.13-final
« Reply #10 on: August 15, 2008, 04:33:39 AM »
you're correct. Spriteset_iPod actuallly draws the iPod graphics, Ipod_Dummy draws the cursor graphic on the iPod. if you change the script around a bit, you can remove those altogether if you want just a plain window

Offline Starrodkirby86

  • Kirby de Varita Estelar
  • Guardian of Chaos
  • ********
  • Posts: 3282
  • LV: 194
  • Gender: Male
  • ~!
    • View Profile
    • The Archive of Starrodkirby86
Re: [XP] Berans' iPod script v1.13-final
« Reply #11 on: August 15, 2008, 04:37:44 AM »
Hmmm...How hard would it be to have some sort of add-on like pop-up showing an album/genre cover? Sort of like a picture overlay, except it'll change depending on the song you are playing? It's going to require a lot of text depending on the overall song count and you need to supply enough album art, but how difficult would that be? (And it might be non-Ipod ethical, I don't have one so I don't know...)

What's osu!? It's a rhythm game. Thought I should have a signature with a working rank. ;P It's now clickable!
Still Aqua's biggest fan (Or am I?).



Offline Fantasist

  • Lexima Warrior
  • *******
  • Posts: 2222
  • LV: 146
  • Gender: Male
    • View Profile
    • Blog
Re: [XP] Berans' iPod script v1.13-final
« Reply #12 on: August 15, 2008, 11:27:49 AM »
Making that popup system is possible, even if you don't have the album art. What does media player do? It uses a default image if no album art is used ;)
Do you like ambient/electronic music? Then you should promote a talented artist! Help out here. (I'm serious. Just listen to his work at least!)

The best of freeware reviews: Gizmo's Freeware Reviews



Offline Berans

  • Awakened Visionist
  • **
  • Posts: 75
  • LV: 10
  • Gender: Male
  • Corn = win...it's yellow
    • View Profile
Re: [XP] Berans' iPod script v1.13-final
« Reply #13 on: August 17, 2008, 05:50:44 AM »
if you could give me a mockup picture of what you're after I might give it a go

Offline Starrodkirby86

  • Kirby de Varita Estelar
  • Guardian of Chaos
  • ********
  • Posts: 3282
  • LV: 194
  • Gender: Male
  • ~!
    • View Profile
    • The Archive of Starrodkirby86
Re: [XP] Berans' iPod script v1.13-final
« Reply #14 on: August 17, 2008, 07:55:15 AM »
Sorry it doesn't follow the Ipod format. However, you can simply have some pop-up to the "right" or "left" of the machine to make it look nice. I'm never one that is good with mock-ups.
(click to show/hide)
This can even be a whole completely new layout request. 0_0 By the way, I gave up at the end, and then just ripped the Windows Media Player skin. It's meant to be the whole play stuff, so exclude any foreign features.

What's osu!? It's a rhythm game. Thought I should have a signature with a working rank. ;P It's now clickable!
Still Aqua's biggest fan (Or am I?).



Offline Berans

  • Awakened Visionist
  • **
  • Posts: 75
  • LV: 10
  • Gender: Male
  • Corn = win...it's yellow
    • View Profile
Re: [XP] Berans' iPod script v1.13-final
« Reply #15 on: August 17, 2008, 08:16:07 AM »
hmmm....I could probably cook up something like that...Wouldn't even be THAT much work...I think. But not for today, I'm flooded with work for university and need to help get the house ready for inspection by the owner....loads to do, little time :P

Offline Starrodkirby86

  • Kirby de Varita Estelar
  • Guardian of Chaos
  • ********
  • Posts: 3282
  • LV: 194
  • Gender: Male
  • ~!
    • View Profile
    • The Archive of Starrodkirby86
Re: [XP] Berans' iPod script v1.13-final
« Reply #16 on: August 17, 2008, 08:19:07 AM »
There's no particular deadline, okay Berans? So finish all you can. Just don't start making it like five months after this post was created. XD That would be a travesty. Godspeed Berans, godspeed. :P

What's osu!? It's a rhythm game. Thought I should have a signature with a working rank. ;P It's now clickable!
Still Aqua's biggest fan (Or am I?).



Offline Hellfire Dragon

  • Astral Trancist
  • *****
  • Posts: 768
  • LV: 24
  • Gender: Male
    • View Profile
Re: [XP] Berans' iPod script v1.13-final
« Reply #17 on: August 18, 2008, 05:58:15 PM »
This script is awesome! However...it worked fine in the dmeo but when i put into my project and added my own songs, authors etc,. I get this

 :???: :(

Offline Berans

  • Awakened Visionist
  • **
  • Posts: 75
  • LV: 10
  • Gender: Male
  • Corn = win...it's yellow
    • View Profile
Re: [XP] Berans' iPod script v1.13-final
« Reply #18 on: August 19, 2008, 04:04:31 AM »
hmmm.....could you tell me exactly when the error happened, and could you also paste a copy of your  "config" section of the script, AND a copy of line 228+ (probably 3-4 lines after 228 will do) since my script has been changed so much that I'm very unsure what line 228 is with you. That would help a lot. It might just be that you set up your songs wrong. Or maybe it's something different.

PS: I'm updating my script shortly after I post this to make setup easier on people, v1.15 will include a tiny bugfix to do with the mute function and will have an all-new way to set up your songs. Quick explanation:
Any songs in your project's "Audio/BGM" folder, will automatically be included in the list of unlockable/playable songs. Any songs from the RTP you want to be played can be added in 2 ways
a) simply copy them to your "Audio/BGM" folder to have them automatically added, or,
b) Put their exact name in the "PLAYBACK1" array, as you would have with all your songs before.
The order of the songs for when you want to set up initial songs/author/genre etc. will be all the songs in your "Audio/BGM" folder arranged in alphabetical order (easy enough to see if you simply arrange that folder alphabetically) followed by any songs you've specified from the RTP in the order you've put them. This is just a testing fase for that system, and I can easily convert it back again if it's not well-liked XD, I just thought that most people probably want all their custom songs to be available anyway, so I'd save them the trouble of setting each and every one of them up correctly.

Offline Hellfire Dragon

  • Astral Trancist
  • *****
  • Posts: 768
  • LV: 24
  • Gender: Male
    • View Profile
Re: [XP] Berans' iPod script v1.15-final
« Reply #19 on: August 19, 2008, 11:48:42 AM »
Alright here's the config section

Code: [Select]
#==============================================================================
#Begin Configuration
#==============================================================================

module Playback
  UNLOCKABLES = true
  BGM_CHANGER = true
  PLAYBACK = [ "Asterisk", "D-technolife",   "Ichirin no Hana",
               "Tonight, Tonight, Tonight",   "Rolling Star",     "ALONES",
                 "After Dark",   "", "",
              "",   ""]
 
  PLAYBACK_INITIAL = []
 
  PLAYBACK_AUTHOR = {1  => "Orange Range", 2  => "UVERworld", 3 => "Unknown",
                     4  => "Unknown", 5  => "Unknown", 6 => "Aqua Timez",
                     7  => "", 8  => "Unknown", 9 => "Unknown",
                     10 => "Unknown", 12 => "Unknown"}
 
  PLAYBACK_GENRE = {1 => ""}, {2 => ""}, {3 => ""}, {4 => ""}, {5 => ""},
  {6 => ""}, {7 => ""},
 
#==============================================================================
#End Configuration
#==============================================================================
And line 288 + 4 lines after it

Code: [Select]
288        Playback::PLAYBACK[$game_system.unlocked_songs[i]]
289      end
290    end
291  end
292 
I using unlock songs. If there is no unlocked when I use the call script to bring up the Ipod i works, but when there is songs unlocked I get the error.

EDIT: I tried again, I only get the error when I use my own songs. The RTP songs work fine :huh:
« Last Edit: August 19, 2008, 12:13:16 PM by Hellfire Dragon »