Page 1 of 1

Scripts

Posted: Sat Nov 19, 2005 12:00 am
by Frieloc
Hi, I've been having some script making issues. Amazing as it may sound, but after about 3 years of playing I have never created or used a created script. Ever. I have realized this has probably made things just slightly more complicated doing certain tasks but I never really cared too much. My question is just:

How do you make scripts? I tried using This tool and it said that it should put saved scripts in the AO/scripts folder, but it did not. So I was just wondering if I could possibly be doing something wrong or what. Any input would be great, thanks.

Posted: Sat Nov 19, 2005 12:06 am
by Snakebite
I've not used that one, I have the UnityoftheRose script generator...

But to be honest, I prefere to write my own from scratch, I think the're easier to edit that way.

& I found one problem with the scripter that I use, when I try to change the text colour selectively, when I save it, half of it just drops to the normal colour!!! :evil:

Posted: Sat Nov 19, 2005 12:09 am
by Frieloc
I just noticed that my scripts actually were saved and in-game but they have .txt extension on them... even though I swore I saved them without any extension. Hm... I'm not a computer techie, whats an easy way to make them not have an extension?

Posted: Sat Nov 19, 2005 12:20 am
by Snakebite
That's normal I believe...

Posted: Sat Nov 19, 2005 2:19 pm
by Khuri
Well, my tool works i'd say :roll:

Normally, Windows saves the files with .txt extension. As long as you do not have the "hide known extensions" options disabled in your Explorers Options, you'll not see the .txt extension behind the filename.
To change this (not sure about the correct English-Spelling of the names), open your explorer, on menu select:
Extra -> Folder Options
View-Tab -> Disable the option "Hide known file extensions"

You should then see the extension .txt behind all files (as well as all other extension on other files) and then you simply need to rename the file from eg. myscript.txt to myscript to remove the .txt extension (you'll get a notice saying if you're sure to change the file extension, click yes)

Anyway though, you should be able to execute the script ingame netherless with extension or not.
Once you saved them in your /Anarchy Online/scripts folder, you need to execute them ingame with the extension then (eg. type ingame /myscript.txt or however your script may be called)

With the exentsion is a problem of Windows though, as i haven't found a way yet to make it save a file without any extension when saved from the onlineserver.


@Snakebite: Are you sure you're using colors that are possible ingame? You can either define the color by using the HEX-Code of the color (eg. #FF00FF - it's RGB) or you use the color-names that are defined in your /Anarchy Online/cd_image/gui/[GUI_NAME]/TextColors.xml file - note though, that those names defined there do not have to exist for other users though, so if you might write down your own defination there, the names you use to define a color might not exist for other people and therefor show black for them then.
I'd prefer you use HEX-Code for defining colors, as those are working for everyone.

On the ScriptEditor on my site, i've pre-configured the 16 main Webcolors.
Please note, you can stack the font-tag, unlike on a forum like this for example, where you need to close a color-tag before you can open a new one, in HTML you can stack font-tags, like this:

Code: Select all

<font color='#FFFFFF'>This is a Test with a <font color='#00FFFF'>blue text</font> within the white</font>

If you might still have problems after this, feel free to contact me, and i'll likely try to explain more detailled for you and help you get your scripts working :)

Posted: Sat Nov 19, 2005 3:46 pm
by Snakebite
Yeah, I use hex colour codes when I write my own scripts, but it's when I use the unityoftherose scripter that it tends to wipe out the colour choices...

Posted: Sat Nov 19, 2005 7:36 pm
by Frieloc
Thanks a lot Khuri, figured it out from what you said and it works now :) great tool by the way, very easy to make scripts

Posted: Sat Nov 19, 2005 9:15 pm
by Khuri
You're welcome.
Glad you like the tool :)