xboxscene.org forums

Pages: [1] 2

Author Topic: Search For Xbeid  (Read 144 times)

Kthulu

  • Archived User
  • Hero Member
  • *
  • Posts: 787
Search For Xbeid
« on: January 08, 2004, 10:06:00 PM »

@ttt
on the searching for xbeid thing and deleting the xbmp save and then launching...
you could use a context script, then the path would already be available to you as %_GameDir%.  to use the SETFUNC ... XBEID function and compare with game save dir, you could use the getHeXbeID.xas script i just posted.

@kf
i've had an idea for awhile on solving the cach-editor search problem, but was trying to wait till i got something else working that would provide an example (may be awhile though) so... how bout mimicking the menu structure in actionscript.  only search one level at a time and present the search results as a menu with selectable menu items (kinda like VKB) once an item is selected, it searches down one more level and presents a menu with choices resulting from that search.  am i making sense?
Logged

Kthulu

  • Archived User
  • Hero Member
  • *
  • Posts: 787
Search For Xbeid
« Reply #1 on: January 08, 2004, 10:10:00 PM »

or you could put the script in like this...
QUOTE

<item>
<dir>F:HDDLOADERProject Gotham Racing 2</dir>
<action>
SETFANSPEED whatever (10-50, i think)
EXEC "F:\HDDLOADER\Project Gotham Racing 2\default.xbe" (Might wanna check on the use of backslashes inside qoutes, i think u have to double them up)
</action>
<title>Project Gotham Racing 2 (PAL)</title>
<media>F:MXM Video Previewst_projectgothamracing2.wmv</media>
</item>

i bet the %_GameDir% is useable in there, but maybe not...
Logged

geniusalz

  • Archived User
  • Hero Member
  • *
  • Posts: 1635
Search For Xbeid
« Reply #2 on: January 08, 2004, 10:18:00 PM »

I was working on a very similar system, but abandoned it coz it was taking too long to fix.

And if you want a menu script that works fine, You can customize one I posted one a little while ago.
GOSUB won't work, so you'll have to move the code inside the main loop.  And FOR loops don't work, but that can easily be done with GOTO's

good luck
Logged

Kthulu

  • Archived User
  • Hero Member
  • *
  • Posts: 787
Search For Xbeid
« Reply #3 on: January 08, 2004, 10:41:00 PM »

smile.gif  just to see if i could smile.gif

i have a working display that can be switched from source display, destination display, queue display.  it doesn't use any external files for record keeping.  it uses that old "06C:MXM07C:EVOX" string-array trick i talked about a long time ago.  it has flicker problems tho when scrolling thru the files cause the processing in the recursive calls are so heavy.  i got frustrated with my queue string array tho cause i was having problems taking strings out of it...so haven't touched it in a few weeks.

maybe this weekend, if you would be willing, i can clean my code up to something more readable and you could look at it?
i know the coming built-in filemanager will be FAR superior, but i just wanted to see if i could do it.  plus, even after the filemanager is built-in, something similar to this script may still be needed for other scripts to get filepaths from users without relying on their 'typing skills'  wink.gif
Logged

geniusalz

  • Archived User
  • Hero Member
  • *
  • Posts: 1635
Search For Xbeid
« Reply #4 on: January 09, 2004, 05:21:00 AM »

Sure, I'll have a look at it.  In my experience XML arrays are far easier to use than string arrays.

And cool idea about using it as an 'open file' or 'open location' dialog box.
Logged

Kthulu

  • Archived User
  • Hero Member
  • *
  • Posts: 787
Search For Xbeid
« Reply #5 on: January 09, 2004, 05:30:00 AM »

when you say using XML arrays, are you talking about using a temp xml file...
OR
is it possible to use the built-in XML operations on an XML structure loaded into a string?

that would be cool...
Logged

geniusalz

  • Archived User
  • Hero Member
  • *
  • Posts: 1635
Search For Xbeid
« Reply #6 on: January 09, 2004, 12:52:00 PM »

You don't have to make an xml file, just a temporary one in memory.

You can use !.%index% with XMLGetValue and XMLSetValue to use arrays

If you have a string, you can just write it to a file, and use the XMLOpen for that
Logged

thetruethugg

  • Archived User
  • Sr. Member
  • *
  • Posts: 432
Search For Xbeid
« Reply #7 on: November 13, 2003, 08:29:00 PM »

How would I do a wildcard search for a specific XBEID and return the path to the xbe?  I want this for my "Delete XBMP/C save and launch" script.  I feel it would be done the easiest by searching for the specific XBEID (for the user at least), and returning the path, so it knows where the file is, to launch it.

I'm having quite a hard time trying to figure out a way to do this.  It's confusing the fuck out of me sad.gif
Logged

geniusalz

  • Archived User
  • Hero Member
  • *
  • Posts: 1635
Search For Xbeid
« Reply #8 on: November 13, 2003, 09:00:00 PM »

I guess you'll have to search all directories/subdirectories.  Check all files' XBEIDs.  And launch the one whose XBEID matches.

I'm afraid there's no easy way to do this.
Logged

thetruethugg

  • Archived User
  • Sr. Member
  • *
  • Posts: 432
Search For Xbeid
« Reply #9 on: November 13, 2003, 09:04:00 PM »

Yea, I know there's no easy way.  I'm just having a hard time figuring out the code to make this work.  I guess I should have said that.

EDIT:  Nevermind (for now), I think I'm starting to get it to work, I haven't tested it yet though, it just looks like it *may* work.

EDIT2:  Ok, here's the code I've come up with so far, I don't know if it works, I don't know that I'll get to test it out till tomarrow or so:

CODE
:XBMC
BEGINSEARCH *
:TOP
SEARCHITEM XBE
SETFUNC XBMCID XBEID %XBE%
IF %XBMCID% == "0face008" GOTO GETPATH
IF %XBMCID% != "0face008" GOTO DOAGAIN
GOTO DONESEARCH

:DOAGAIN
SEARCHNEXT
GOTO TOP

:GETPATH
BeginDraw UseCurrent
MessageBox "TEST:  %XBE% and %XBMCID%$eol$$eol$BLACK to exit"
INPUT
IF %_GP_BLACK% == "1" GOTO DONESEARCH
EndDraw

:DONESEARCH
ENDSEARCH
Logged

koldfuzion

  • Archived User
  • Hero Member
  • *
  • Posts: 1226
Search For Xbeid
« Reply #10 on: November 14, 2003, 04:34:00 AM »

you might be able to use the cache_menu.xml to do this.

The nodes arent indexed so it might not be easy... ill try out some code this weekend and let you know if i come up with anything workable.
Logged

thetruethugg

  • Archived User
  • Sr. Member
  • *
  • Posts: 432
Search For Xbeid
« Reply #11 on: November 14, 2003, 04:47:00 AM »

Thanks man.  I was originally thinking about that.  But, I don't know how to make it work for people like me that don't use auto-menu, well, and I suck at this action scripting, so I really just kinda started throwing shit together, and this is what I've come up with.
Logged

thetruethugg

  • Archived User
  • Sr. Member
  • *
  • Posts: 432
Search For Xbeid
« Reply #12 on: November 14, 2003, 10:47:00 PM »

Eh, nevermind the XBEID for XBMC being '0face008' that's just the folder the saves are in (which, I thought that was done by XBEID, guess not though).  Luckily, I checked the cache menu, and found out it's actually '262987784', that should make things go a little bit smoother.
Logged

koldfuzion

  • Archived User
  • Hero Member
  • *
  • Posts: 1226
Search For Xbeid
« Reply #13 on: November 14, 2003, 10:54:00 PM »

CODE
But, I don't know how to make it work for people like me that don't use auto-menu


It shouldnt really be an issue since you still must have the basics in your custom menu for it to work too.

Im making a script that will let you browse your cache file and change game/app titles now that kthulu has his keyboard script finished.

Since I was working with it and had to get the search pattern down right (thanks for the bugfix geniusalz:)) I figured I would go ahead and write this up.

You will need to edit the first line in the script to point to your cache_menu.xml file unless yours is on C:\ by default.

The only problem that this script will have is if you go through two submenus to get to your players.  (ie:  main menu->apps->media players->xbmp)

Thats the next fix I will be working on before i go ahead with the editing of game titles.

Anyway,  the script searches your menu.. and checks the xbeid from the xbe file location itself and not the cache_menu entry for it.  If found, it offers to delete the saves adn launch the app, skip or quit.   So custom menus shouldnt be a problem unless its the problem i previously mentioned.

Its set up for XBMC and XBMP and tested fine on my box.

You can get it HERE... let me know if it works out fine for you.
Logged

thetruethugg

  • Archived User
  • Sr. Member
  • *
  • Posts: 432
Search For Xbeid
« Reply #14 on: November 14, 2003, 10:59:00 PM »

Yea, after I posted the "But, I don't know....." crap, it occured to me you could also search for XBEID still, too lazy to edit. wink.gif  As for your script, I'll test it when I can, sounds nice though, with this I may just switch to auto-menu, because I'll be able to edit name from MXM and such.  I still think I'll finish mine, though your's will be far more superior, just to get some experience and a sense of completion (something I rarely do).
Logged
Pages: [1] 2