Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - TrailMyx

Pages: 1 ... 619 620 [621]
9301
Script development tools / TrailMyx's Master Rail Engine/Developer
« on: June 09, 2008, 12:09:26 PM »
Code: [Select]
;-----------------------------------------------------------
; Script Name: TrailMyx's Master Rail Developer
; Authors: TrailMyx
; Version: 0.55a
; Client Tested with: 6.0.3.1
; EUO version tested with: 1.5 127
; Shard: OSI, FS
; Revision Date:  10/1/2007
; Public Release: ...
; Global Variables Used: None
; Purpose: Records and plays back rails.  Saves them to files.
;-----------------------------------------------------------

Code: [Select]
;-----------------------------------------------------------
; Script Name: TrailMyx's Master Rail Engine Subs
; Authors: TrailMyx
; Version: 0.30k
; Client Tested with: 6.0.3.1
; EUO version tested with: 1.5 127
; Shard: OSI, FS(Alexandria[RunUO])
; Revision Date:  9/28/2007
; Public Release: ...
; Global Variables Used: None
; Purpose: Plays rails recorded by TrailMyx's Master Rail Generator.
;   Allows user to have multiple rails loaded into memory and includes many
;  support functions to help automate rail-enabled script development.
;-----------------------------------------------------------
;  Functions:
;  call %railsubs TM_Initialize ; Initializes rail engine namespace to SUBROUTINE mode
;  call %railsubs TM_Close ; clears namespaces use for rail engine.
;  call %railsubs TM_LoadRail c:\rail1.txt
;  call %railsubs TM_RunRail RAIL1 PRESENT END FW
;                            RAIL1 0 5 BW
;  call %railsubs TM_SelectRail RAIL1  ; can select by either rail NAME or rail INDEX
;  call %railsubs TM_RailsLoaded  ; returns number of rails presently in memory
;  call %railsubs TM_DetermineCurrentRail ; returns index of rail presently selected
;  call %railsubs TM_DetermineCurrentRailName  ; return rail NAME of presently selected rail
;  call %railsubs TM_DetermineCurrentWaypointIndex ; returns current waypoint index for present rail
;  call %railsubs TM_GetRailNameForIndex 0  ; return rail NAME of index 0.
;  call %railsubs TM_DetermineCurrentRailWaypoints ; returns number of waypoints for presently selected rail
;  call %railsubs TM_DetermineRailWaypoints 3 ; determines number of waypoints for rail index/name 3
;  call %railsubs TM_GotoClosestRailIndexedWaypoint ; proceeds to the closest waypoint of selectable rail
;  call %railsubs TM_GotoClosestWaypoint ; proceeds to the closest waypoint of present rail
;  call %railsubs TM_GotoClosestGlobalWaypoint ; searches all rails in memory to find the closest waypoint.
;  call %railsubs TM_Push  ; pushes present waypoint and rail onto stack
;  call %railsubs TM_Pop   ; recalls last pushed waypoint and rail, sets rail and present_index of waypoint
;  call %railsubs TM_ServerInitialize ; initializes global namespace and puts rail engine into SERVER mode.
;  call %railsubs TM_GetStatus ; returns rail engine server status --> IDLE, RUNNING, ERROR
;  call %railsubs TM_GetServerMode ; returns configured server mode --> SERVER, SUBROUTINE
;  call %railsubs TM_PingServer ; returns PING if server doesn't respond, PONG if server is available.
;  call %railsubs TM_GetPresentServerCommand ; this is the present command the server is processing
;  call %railsubs TM_SetPresentServerCommand ; Used to issue STOP command, halting rail
;  call %railsubs TM_PercentWaypointRun ; -1, defined by rail, 0- walk all the time, 100 - run all the time.
;  call %railsubs TM_ShowDebug
;  call %railsubs TM_HideDebug
;
; Do not re-produce these subroutines without the express permission from the author, TrailMyx.   email: trailmyx@yahoo.com
;




Finally, I'm getting around to releasing this to you.  I've been busy using this system in a couple projects, so I've had some time to do some deep testing with it.  

This release comes in 4 parts:
1) Rail Developer/Creator
2) Rail Engine
3) Rail Converter (converts CEO and Roadkill formats to TM_RE)
4) PDF document  (very rough first-pass, will be amended as more time presents itself)

I may attach some more sample code as time goes on, or post more examples.

Here's a quick summary of the capabilities of this rail system:
  • Rail engine can manage any number of rails simultaneously only limited to memory.
  • Rail files are saved in 2K chunks, so even large rails can be saved and loaded very quickly.
  • 2 modes of operation, SUBROUTINE and SERVER.

           a)SERVER mode allows scripts to run in NON-BLOCKING mode so they don't have to wait while the engine completes a rail command.
           b)SUBROUTINE mode runs each of the rail subroutines directly, but script execution is blocked until the rail finishs/fails.
  • Lots of support functions including: Please check out the PDF file for more information (attached)
    - TM_GotoClosestWaypoint - find the closest waypoint within walking range of the current rail
    - TM_GotoClosestGlobalWaypoint - searchs all rails loaded into memory to find the closest waypoint; it's smart enough to know to choose the right waypoint just in case another one is close, but the z-axis may put that waypoint on another level.  i.e. Wandering in a house with multiple levels.
    - TM_Push, TM_Pop - save and restore waypoint/rail information if you need to make a detour
    ...more functions are added all the time.  Part of why I haven't released this yet.
  • Interactive rail developer; graphically allows you to record your waypoints while you walk, edit by adding, deleting, changing each waypoint.
  • Each waypoint may have an associated "callback" function that will be called by the engine.  So you can add special code for waypoints that require special attention.
  • Each rail file may have a separate callback script, so the rails can be completely independent of one another
  • Ability to move toward and named type of item such as a specific NPC, moongate, teleporter, etc
Getting started:

This couldn't be easier.  Start the rail developer, stand where you want to start end press "Start Record" button.  Then just walk.  When you want to end recording, press the "Stop Record".  Enter the filename you'd like to save to and a unique label; the engine uses this label to reference your rail in memory.  Then press "Save"  You're done!  Of course you can step through your rail or run it from the developer, it's your choice.

Now, if you'd like to have the rail engine test your script, enter your rail filename and label into the following simple code and run it.  Yes, it's that easy.

Code: [Select]
set %railsubs tool_railengine30f.txt
set %rail_filename railfile.txt
set %rail_label  RAIL_LABEL1

call %railsubs TM_Initialize  

call %railsubs TM_LoadRail %rail_filename

if #RESULT = #TRUE
{
  display ok Rail file not found
  stop
}
set #LPC 1000

call %railsubs TM_RunRail %rail_label 0 END FW  
if #RESULT = #TRUE
{
  display ok Rail error occurred.
}

call %railsubs TM_Close
stop



Notes:
  • I will keep the revisions under 1.0 until I get enough feedback to let me know the stability is good enough to validate full release.  So consider this a BETA release.
Release History
Engine:
Version 0.30k - 4/14/2007 Current release

Developer/Creator:
Version 0.55a - 4/14/2007 Current release

Converter:
Un-versioned release - will begin version number with next release.  Will also include a header. 4/14/2007

PDF document
Revision 2 4/14/2007

Scripts using this Engine
PM me if you use this and would like me to add your script to this list!

  • ScriptUO Heartwood Quester v1.x
  • ScriptUO Heartwood Quester v2.x
  • TrailMyx's Zoo Collector
  • TrailMyx's Quest List Builder
  • SuperSlayer's World Idoc Traveler Version




9302
Item Evaluation / TrailMyx's Paperdoll Totalizer
« on: June 09, 2008, 12:04:50 PM »
Code: [Select]
;=================================================================
; Script Name: TrailMyx's Paperdoll Totalizer
; Author: TrailMyx
; Version: 2.2
; Shard OSI / FS: OSI / FS OK
; Revision Date: 9/29/2007
; Purpose: Summarize all stats contained in your paperdoll.
; Globals:
;=================================================================



This is a very simple script that will allow you to summarize what you have in your paperdoll.  This summary includes summing all the modifiers and item properties.  It's not perfect, but it does show when you have things requiring insurance.

Special requirements:
You must not be running another script when you run this one.  Multiple finditems/event property calls will mess with this script.

Warning about Set Pieces:

If you are trying to evaluate "set pieces" this will probably not work correctly with this script.  In fact, the only thing that will get totaled is probably the set bonus, and not the individual piece information.  FYI

Additional Features:
  • Repair Checker
  • Insurance check
  • Totalize paperdoll or container of items.  Container can also be another paperdoll targeted
  • HTML Generator to make a list of your suit or container contents
  • BBCode Generator to make a list of your suit or container contents

9303
Site News / Welcome!
« on: June 09, 2008, 11:01:57 AM »
Welcome to ScriptUO!

So I'm tired of having all the sites that host my scripts go belly-up. I will be moving my script collection here to ScriptUO.com. I didn't really want to host a site like this, but I think it's better in the long run.

I don't want to really run a full-blown scripting site like we did for winuo.org or uocoders.com.  I would like this to become a more advanced scripting site, but for now I'm willing to host my scripts here for everyone to download.  I'll give access to my more deadly scripts to those few that I know and trust.  

Edit:  Nevermind, looks like we run a full-blown scripting site.  ;)

9304
Screen images / Integrated HELP!
« on: June 03, 2008, 01:29:51 AM »
Right context clicking a highlighted command will bring up the Wiki information from the EasyUO website.  (Thank you EUO).


9305
I have the looping construct engine working well.  First implemented is FOR, but with the engine I came up with, it'll handle everything that has to do with blocks braced, or single lines.  So it handles things like this now:

Code: [Select]
set %test 0
for %i 1 6
{
  for %j 20 10
  set %test %test + %i + %j
}
display ok %test
stop

Of course EasyUO can't handle this:

Code: [Select]
set %test 0
set !four 4
set !five 5
for %i 1 6
{
  for % . j !four * !five 6 + 4
  set %test %test + %i + %j
}
display ok %test
stop

9306
Screen images / Subroutine demonstration
« on: June 01, 2008, 02:27:09 AM »

9307
Clicking the lines found with the search/replace window will zoom your code to the corresponding line.


9308
Screen images / Debugger breakpoints and context menu + colored UI
« on: May 31, 2008, 01:16:41 PM »

9309
Screen images / Zoom feature demonstration of "Subs" tab
« on: May 31, 2008, 01:15:16 PM »
Just click a name in the "Subs" tab, and you will zoom the cursor to that location.


9311

9312
General Discussion / What to do about the lame EasyUO parser?
« on: May 31, 2008, 01:05:58 PM »
It's a darn shame I need to keep compatibility with the old EasyUO code.  I've always wanted to be able to parse things like this:

Code: [Select]
set %i 0
set %test0t monkey
set %cagedmonkey banana
set %test %caged . ( %test . ( %i , t ) )
display ok %test
stop

Mine parses this just fine; hand that monkey a "banana"; he doesn't want a "%caged("

At the moment, I believe EasyUO uses 3 or more separate syntax parsers based upon what commands are being executed and the data contained within a command.

Arguments for "display" and "menu" seem to use a simple no math parser.  The rest use a math parser unless certain rules are broken.  I'm figuring those rules out by trial and error and I've written quite a bit of test code that I use to compare what my parser does vs. EUO.

or this one:

Code: [Select]
set %i 0
set %test0100 monkey
set %cagedmonkey banana
set %test %caged . ( %test . ( %i , ( 25 * 4 ) ) )
display ok %test
stop

So going forward, I will be adding a "compatibility" mode for parsing through traditional EasyUO formatted code, but allow for a switch to implement the enhanced parsing features of ScriptUO.

9313
Features / Questions and Answers - General
« on: April 25, 2008, 03:28:06 PM »
Q: Is this part of the OpenEUO initiative?

A: No, we'd rather maintain our own code rather than be depend on another "closed" source.
------------------
Q: Will ScriptUO be open source?

A: No.
------------------
Q: What are your plans for client interaction?

A: At the present, there is limited client interface.  Partially due to my own time determining what the client hooks are.  For client version 6.0.5.0, I had a very large amount of client interface completed.  But going forward, I wanted to concentrate on what caused me to write ScriptUO to begin with.  So the user interface and tools get 1st priority.
------------------
Q: When will you be opening the site to registration?

A: Sometime after the alpha test phase at uocoders.com.  Moot, open.  ;)
------------------
Q: When are you going to finish this?

A: Well, since I work for a living and this is just a general pastime for me, I have to say that I'll finish it when I finish it.  I'm sorry but I just can't give a set time.  At least I'm actively adding new features all the time.  ;)
------------------
Q: How are you doing the ScriptUO development?

A: I'm using Visual C# and the .NET 2.0 platform.  I'm doing code development with SharpDevelop and version control with TortoiseSVN(Subversion).
------------------
Q: Why the heck are you using .NET?

A: Why not?  I like it.  Sure it's a Microsoft contraption, but I've been keeping a close eye on the development and at present I can still compile/execute with Mono. 
------------------
Q: Will you be transferring to the .NET 3.5 Framework?

A: Not unless forced by gunpoint or some other unforeseen occurrence.  2.0 Framework is widely used in the UOniverse with applications like RunUO and Razor already forcing many good people to install the framework.
------------------
Q: Are you utilizing anything else but C#?

A: Much of my client interface code is written, or is in the process of being re-written in C++.  Originally I had started this project using C++ since that's what I have known for many many years now.  But for the user interface, it made the most sense to implement it with C# and .NET Forms.

9314
Features / Features: Historical
« on: April 17, 2008, 11:37:23 AM »
Features of version 117

  • Context code highlighting
  • %vars, #VARs, and !vars have their own independent context color
  • Advanced search/replace
  • Integrated online help with help tabs integrated into ScriptUO linked directly to EasyUO Wiki
  • Zoomable lists for easily navigating subroutines, subroutine calls, and labels
  • User selectable font
  • User configurable theme coloring
  • Auto intention of script text
  • EasyUO/ScriptUO syntax checker
  • double click "sub" or "return" will highlight entire subroutine (disabled currently)
  • matching braces and parenthesis will be highlighted
  • "Tab" key when text is highlighted will advance entire block right
  • "Shift-Tab" key when text is highlighted will advance entire block left
  • "Ctrl-Mousewheel" when editing text will zoom the text font
  • double-clicking a keyword will select the entire word, including the variable operator

9315
General Announcements / Welcome to ScriptUO!
« on: April 17, 2008, 11:14:32 AM »
Hello everyone.  Thank you for stopping by.  I'm TrailMyx and I've been a behind-the-scenes turbo-scripter for over 7 years now.  During that time, I have gotten used to issues with EasyUO and always wondered what life would be like with a tool that has more useful features for the script developer.  That's where ScriptUO came from.  

I have to say now that I have enormous respect for Cheffe at EasyUO.  His work re-invigorated my love for UO and I found a whole new level of fun to be had with a tired old game.  So thank you Cheffe!

Eventually this program may turn into an EasyUO replacement.  For now, it's a great development tool that will aid your script development needs.  

So if you are script author, I'd love for you to try out ScriptUO.  This should make working on large scripts much more enjoyable.  Also if you are new to scripting, the embedded help features will help you get accustomed to the language syntax.

If you are a script user, you will find most of my scripts that were originally published on WinUO.org and UOCoders.com.

Hi and welcome,

TrailMyx

Pages: 1 ... 619 620 [621]