Jump to content


Photo

How Do You Execute .xas Files


  • Please log in to reply
1 reply to this topic

#1 jinx_removing

jinx_removing

    X-S Member

  • Members
  • Pip
  • 66 posts

Posted 24 November 2003 - 02:31 AM

Hey everyone.

Apologies for the question -- I'm having trouble figuring out how to execute .XAS files. I wanted to poke around ActionScripting, but can't even get moving... At all. tongue.gif How does one run the testscript.xas

Again, apologies.

Peace.

-Jinx

#2 koldfuzion

koldfuzion

    X-S Freak

  • Members
  • PipPipPipPipPip
  • 1,480 posts

Posted 24 November 2003 - 04:03 AM

you can add a new submenu to your menu.xml and add a menu item to that.

As you can see.. you set everything up just like you would a menu menu entry, except you need to change the <exe> tag to an <Action> tag.

of course, you dont have to use a "callfile" function to get a script running, you could put actionscript code between the <actions> tags and run it straight from the menu.xml itself.

I prefer the way listed below, it allows me to update the script without having to reboot.

(you will need to edit the paths to the files on your xbox and you can remove the media and thumbnail tags if you want)

<Submenu>
<Title>Scripts</Title>
<SortField>Title</SortField>
<Media>C:\mxmvideos\scripts.wmv</Media>
<Thumbnail>C:\mxmvideos\folderstuff.png</Thumbnail>
<item>
<title>Test Script</title>
<descr>Use test.xas for testing</descr>
<Action>Callfile c:\mxmscripts\test.xas</Action>
<media>C:\mxmvideos\test.wmv</media>
<thumbnail>C:\mxmvideos\hammertime.png</thumbnail>
</item>
</Submenu>


the test.xas file is a simple text document. You can start by creating a new one in notepad and pasting the following code and saving as test.xas then upload to the xbox in the place you reference in the menu item above.

CODE

BeginDraw UseCurrent
MessageBox "Hello  $Name$"
EndDraw
INPUT
QUIT


You can use system vars, internal scripts, environment vars etc... just browse the scripting forum and mxm docs when you are ready to jump in head first.

hope this helped.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users