xboxscene.org forums

Pages: [1] 2

Author Topic: Things You Can Add To Nexgen's Skin  (Read 626 times)

neo-dilly

  • Archived User
  • Jr. Member
  • *
  • Posts: 57
Things You Can Add To Nexgen's Skin
« on: February 23, 2004, 02:05:00 AM »

This thread is for things that can be added to neXgen skins to make them better (or worse). I suggest you don't do this if it is your default dash. Make regular backups so if you screw up you can revert it back. I am going to be releasing skinning documentation soon which will show how powerful the lua skinning engine especially when it is finished!

Disclaimer: I do not accept (neither does Team Xboxopensource) any responsibility for any damage caused to your xbox hardware or software for the use of these addons.

Notes:      
CODE
SYSTEM:\\  >>  C:\
STORAGE:\\   >>  E:\
EXTENDED:\\  >>  F:\
EXTENDEDG:\\  >>  G:\
TEMPX:\\  >>  X:\
TEMPY:\\  >>  Y:\
TEMPZ:\\  >>  Z:\
SKINS:\\  >>  neXgen skins folder
              

-----------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------

Skin thingy no1: Add IP address to main menu.

It gets annoying if your using DCHP and can't see your ip address (well you can using the system info menu in settings) but it's much nicer to see it on the main menu. I also shortened the work sountrack so the text don't look cluttered at the bottom of the screen, i also shifted the text up so it doesn't get partially cut off on my screen.

In the Skins/xdash folder

open mainmenu.lua in a text editor

Find

CODE
rendertext(DriveStatus ,470,420)


and highlight that and keep going down highlighting lines until the end of this line

CODE
rendertext("Soundtrack:" .. SoundTrack .. "\nSong: ".. Song ,65,420)


then replace with this...

CODE
XBOXConnected()
     rendertext(DriveStatus ,410,410)
     rendertext("IP: " .. xboxip ,410,390)
     Playing = MusicPlaying()
     if Playing>0 then
     --GetSongInfo()
     --settextargb(255,255,255,255)
     rendertext("ST:" .. SoundTrack .. "\nSong: ".. Song ,65,410)
   


-----------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------

Skin Thingy No 2:

The cool thing is now sounds have been incorporated into the dashboard you can assign them to alot of things. Here is how to assign a new sound to play when you move up and down in the games, apps and emulators menu. I will show you how to add a new sound to your skin.

Copy a wav file into your Skins/Waves folder (it has to be ADPCM encoded, easiest way just copy a file from the ms dash audio folder).

In your Skins folder open xdash.skin in a text editor

Find:

CODE
LoadSound("menuleave", "Games Main Menu Out_LR.wav")


and underneath put this

CODE
LoadSound("(mysound1)", "(name of sound copied).wav")


not forgetting to change the name of the wav to whatever you placed in the audio folder. Also for every new sound you add the first entry (mysound1) has to be different. You have now defined a wav file.

To use the wav in a function (in my case games etc menu up and down)

open game.lua/emus.lua/apps.lua in a text editor

find:

CODE
if (contAy>0.5 or contApushup>0) and TargetItem>0 then


then a few lines underneath there should be
CODE
framecnt=30


above this type

CODE
PlaySound("mysound1")


(mysound1) is whatever you called your wav in the first bracket of this

CODE
LoadSound("(mysound1)", "(name of sound copied).wav")


do the same for this

CODE
elseif (contAy<-0.5 or contApushdown>0) and TargetItem


but you can use a different sound if you want ;).

now you have a menu (or menus) with sound when moving up and down.

-----------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------

Skin thingy No 3:

Shutdown/Restart Menu:

I decided to make a shutdown/restart menu. It's basic since there are currently no calls for shutdown/restart so you will have to get the shutdown/reboot xbe's. The legal ones are available at http://dillx.net/nexgen/vp_legal_sh_rs.rar (thanks to VulgusProfanum for making them originally for use with tHc M$ Dash), and "the usual places" will provide for the xdk compiled xbe's. Copy them (making sure they are called shutdown.xbe and reboot.xbe and copy them to the root of C! Download this file http://dillx.net/nexgen/toxbox.lua and place it in your Skins/xdash folder. This file will be updated again soon with pictures and text repositioning.

Now open mainmenu.lua in Skins/Xdash

Find:

CODE
if contApushw>0.5 then


then look for the first instance of
CODE
end
after that.

after that paste this:

                             
CODE
 if contApushb>0.5 then
     newscene("SKINS:\\xdash\\toxbox.lua")
     framecnt=10
  end


the letter at the end of contApush? shows which button is pressed to activate the function. In this case b. You can change it to a button that isn't used for another function already (do not use black - broken screenshot feature). Once finished you press B (in my example) and it will show you a menu which you can Shutdown, Restart or start Xenium OS.

-----------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------

Skin thingy No 4:

That black line around the orb is really ugly. The black line is a combination of the black colored mesh that was textured with a too small orb. Here's how you remove it.

First thing is to get rid of the extra black on the orb image (you can do this yourself), or you can use this image (not very good needs to be recolored again, still an outline (supposed to be) but i'm sure it's blue). The orb that is used is in Skins/xdash/mainmenu/ and it's called 0001.bmp

http://dillx.net/nexgen/0001.bmp (save target as)

Open Skins/xdash/mainmenu.lua with a text editor

Find:

CODE
setrenderstateargb(75, alpha, 0, 0, 0)


and replace with:

CODE
setrenderstateargb(75, 0, 0, 0, 0)


-----------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------

Skin thingy No 5:

Extremely basic skin color changing and some look changing. Since there is only one color skin and look at the moment here is how you change the color of your skin and change the look.

First are the textures, they are just bitmap (bmp) files and are easy to change.

Here is a list of the textures and what they are used for

/skins/xdash/outersphere.bmp             >>  the cellwall's texture (the rotating background)
/skins/xdash/xray.bmp                         >>  some use (can't figure out yet, don't change)
/skins/xdash/dialog/SMITEM-2.BMP        >>  texture for buttons
/skins/xdash/mainmenu/0001.bmp        >>  the orb texture for the main menu
/skins/xdash/mainmenu/0002.bmp        >>  some use (can't figure out yet, don't change)
/skins/xdash/mainmenu/SMITEM-2.BMP >> the background of the mainmenu items
/skins/xdash/mainmenu/MITEM-2.BMP   >> some use (can't figure out yet)
/skins/xdash/mainmenu/SMITEM-1.BMP >> selected mini orb (placed next to menu items)
/skins/xdash/mainmenu/MITEM-1.BMP  >> unselected mini orb (placed next to menu items)
/skins/xdash/settings/SMITEM-2.BMP >> button texture (used in clock menu)

in the lua files (most of them) are these:

CODE
setupxray(object number? (don't worry), Alpha Channel Value, Red Value, Green Value, Blue Value)


CODE
setrenderstateargb(object number? (don't worry), Alpha Channel Value, Red Value, Green Value, Blue Value)


these two change the color of 3d meshes used by neXgen.

CODE
settextargb(object number? (don't worry), Alpha Channel Value, Red Value, Green Value, Blue Value)


this one changes the color of rendered text

mess around with these values until you get something you will like

-----------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------

Skin thingy No 6:

Changing the scroll speed of the mainmenu. Some people don't like the ultra fast main menu.. Well here's how to change that..

Open up in a text editor Skins/xdash/mainmenu.lua

Find

CODE
if (contAy>0.5 or contApushup>0) and TargetItem>0 then


go down from there and at the first instance of
CODE
framecnt = 10


the value on the end is the one to change, a higher number will make the scroll speed slower and a lower number will make the scroll speed faster.

do the same for
CODE
elseif (contAy<-0.5 or contApushdown>0) and TargetItem


you can do this on any scrollable menu (i think) just look for something like the codesnippets in the other files.

me thinks wav playing needs work, the sounds sound sucky since they (mostly) play 1 for every two scrolls

-----------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------

Skin thingy No 7:

Launching XBE's from the main menu (and other places that only allow lua opening). In the main menu, the menu is set up to load lua files only when a button is pressed. This is annoying if you want to have a link to a xbe on the main menu (such as xbmp/c). This will show you how to launch xbe's from the main menu.

first make a new folder in your skins/xdash/ folder, call it launchxbe.

open up your text  editor and paste this into it.

CODE
launchxbe("(path to XBE and name)")


path should be written in our funky naming convention (see notes at top) and should use double backslashes instead of one.

eg

CODE
SYSTEM:\\shutdown.xbe >> C:\shutdown.xbe


then save it as a .lua file in your /skins/xdash/launchxbe folder

now open up /skins/xdash/mainmenu.lua in a text editor

(this bit you can slightly modify, i'll tell you how to add entries soon)

find

CODE
menuitem[6]="FTP"


replace "FTP" with whatever the name of the program.

on the next line
CODE
menuaction[6]="SKINS:\\xdash\\ftpdialog.lua"


replace what's in the quotes with the location of your lua file.

-----------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------

Skin Thingy No 8:  CellWall as Orb

If you dont like the orb image you can use your cell wall as a orb...

to do this open mainmenu.lua in your Skins/xdash folder

find

CODE
loadmesh("xsphere", "SKINS:\\xdash\\mainmenu\\xsphere.xbg")


and at the front of the line it is on add

CODE
--(space bar)


what this does is comment out the loadmesh (orb mesh) code

then find

renderobject("xsphere", 1, -15, 0.95, 3, 0, -PI/18, 0, 0.5, 0.5, 0.5)

and comment it out by putting this before it

CODE
--(space bar)


underneath that make a new line and paste this

CODE
renderobject("outersphere", 3, -25, 0, 31, PI/2, BackRotation*20, 0, 0.4, 0.4, 0.4)


the "BackRotation*20" is the way it rotates and currently i havent found other ways to rotate but to change speed change the "20" to another number

this will give you a cellwall orb mesh instead of the orb texture

------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------------------------

more soon!

neo-dilly
Member of Team Xboxopensource
http://www.xboxopensource.com

This post has been edited by neo-dilly on Mar 14 2004, 08:02 PM
Logged

unleashx

  • Archived User
  • Hero Member
  • *
  • Posts: 621
Things You Can Add To Nexgen's Skin
« Reply #1 on: February 23, 2004, 02:11:00 AM »

Can't you remove the extra MusicPlaying() line and use Playing = MusicPlaying() alone? Less call, less resource, faster framerate.

Logged

neo-dilly

  • Archived User
  • Jr. Member
  • *
  • Posts: 57
Things You Can Add To Nexgen's Skin
« Reply #2 on: February 23, 2004, 01:48:00 AM »

yup i just tried it and have updated the code in my first post  <
Logged

Dunny

  • Archived User
  • Full Member
  • *
  • Posts: 220
Things You Can Add To Nexgen's Skin
« Reply #3 on: February 23, 2004, 02:05:00 AM »

can you remove the text from the top of the screen, fps and version text?  I personally don't like any text on the main screen.  <
Logged

HoRnEyDvL

  • Administrator
  • Sr. Member
  • *****
  • Posts: 462
Things You Can Add To Nexgen's Skin
« Reply #4 on: February 23, 2004, 03:01:00 AM »

I will get into removing the text from the top for you guys & try 2 get a new build out.

This post has been edited by HoRnEyDvL on Feb 23 2004, 11:04 AM
Logged

neo-dilly

  • Archived User
  • Jr. Member
  • *
  • Posts: 57
Things You Can Add To Nexgen's Skin
« Reply #5 on: February 23, 2004, 03:04:00 AM »

*deleted*

This post has been edited by neo-dilly on Feb 23 2004, 11:04 AM
Logged

unleashx

  • Archived User
  • Hero Member
  • *
  • Posts: 621
Things You Can Add To Nexgen's Skin
« Reply #6 on: February 23, 2004, 03:25:00 AM »

Remove the
QUOTE
tags as they don't work within "Quote" or "Code" tags, might cause confusion later for someone who doesn't know this things.
Logged

neo-dilly

  • Archived User
  • Jr. Member
  • *
  • Posts: 57
Things You Can Add To Nexgen's Skin
« Reply #7 on: February 23, 2004, 06:07:00 AM »

oops my bad

This post has been edited by neo-dilly on Feb 23 2004, 06:38 PM
Logged

Dunny

  • Archived User
  • Full Member
  • *
  • Posts: 220
Things You Can Add To Nexgen's Skin
« Reply #8 on: February 23, 2004, 09:01:00 AM »

how do you go about editing the xbg images?  <
Logged

neo-dilly

  • Archived User
  • Jr. Member
  • *
  • Posts: 57
Things You Can Add To Nexgen's Skin
« Reply #9 on: February 23, 2004, 10:48:00 AM »

at the moment i don't know because one of the other devs (and original coder) did them...  <
Logged

T3chnomancer

  • Archived User
  • Newbie
  • *
  • Posts: 2
Things You Can Add To Nexgen's Skin
« Reply #10 on: February 23, 2004, 04:04:00 PM »

Not exactly an easy answer but.....

XBG Objects:- originally created in 3DSMax (typically inside out, so the faces point inwards giving a transparent look) Then converted from .3ds to .x and then to .xbg file using utilities found in either the XDK or in the usual places.
The .xbx image format for textures can also be converted into from normal file types, ie .jpg,.png etc.

Once XBG object is converted load into a .lua page and start the laborious process of tweaking size and 3d positioning of the object so that it fits into the 3d world used within NEXGEN.

Said it wasn't easy, especially since this is a very concise look at how it was done.

BTW you can use other 3d apps to create the original meshes ie Lightwave, Maya, Softimage. It is just that 3DSMax is the best supported for converting direct to the directx format of .x files.
Logged

XJelo

  • Archived User
  • Newbie
  • *
  • Posts: 4
Things You Can Add To Nexgen's Skin
« Reply #11 on: February 25, 2004, 07:18:00 AM »

First of all, thanks for these tweaks as they help address some of my immediate feelings about the dash and I'm gonna mess with it some more before I decide to get rid of it. So far it seems stable and does a decent enough job of detecting and launching games and apps.

Can we do anything about the 3D bracket that holds the "x sphere" in the main menu?
I'd like to use the mesh that the standard MS dash(or the tHc dash) uses but change the color to blue. The simulated blue woodgrain effect on there's just not doing it for me. I also intend to mess with the background sphere texture to smooth things back out. It's all just a bit more cartooney looking than I like.

Also, what about support for a music playback system of some sort(again, if it didn't crash after 15-20 minutes, the easy access player that tHc uses is ideal IMO)? At the moment, it just starts at the very top of my playlist every time I load the dash and I don't seem to have any control beyond that. Although I see music options listed in the cfg file, they don't appear to be on my menu system(maybe I should go back and look again).

Anyways, thanks again for the time you're putting in to help out and we all appreciate it. Just need alittle help with the nipping and tucking to make myself comfortable. smile.gif
Logged

neo-dilly

  • Archived User
  • Jr. Member
  • *
  • Posts: 57
Things You Can Add To Nexgen's Skin
« Reply #12 on: March 14, 2004, 12:03:00 PM »

added another thing

*bump*
Logged

SpOoK

  • Recovered User
  • Newbie
  • *
  • Posts: 46
Things You Can Add To Nexgen's Skin
« Reply #13 on: March 14, 2004, 01:32:00 PM »

Hi neo-dilly,

thanks for all your work on modifying the Default skin it's appreciated.

I finaly got around to adding some more lua bindings today.

So you will have built in:

xboxpower() --> Power off XBOX
xboxreboot() --> Reboot
xboxopentray() --> Eject Tray
xboxclosetray() --> Close Tray

+ more
Logged

Cuke

  • Archived User
  • Newbie
  • *
  • Posts: 1
Things You Can Add To Nexgen's Skin
« Reply #14 on: April 19, 2004, 10:47:00 PM »

Helpful, Thanx.

A few things I noticed while poking around.

/skins/xdash/mainmenu/MITEM-2.BMP >>unselected background of the mainmenu items (a one pixel high horizontal gradient fill that gets streched to fill the menu item).

/skins/xdash/mainmenu/0002.bmp >> don't know what its for, but renaming to 0001.bmp will give the orb a very nice texture with lighting and shadows, almost like it was designed for the orb.

also, changing image size had no ill effects on the few images I messed with, don't know if that's OK for all images.
Logged
Pages: [1] 2