                   ___ _                    _____ ___ _    
                  / __| |__ _ _  _ ___ _ _ / / __| _ \ |   
                  \__ \ / _` | || / -_) '_/ / (_ |  _/ |__ 
                  |___/_\__,_|\_, \___|_|/_/ \___|_| |____|
                              |__/
_____________________________________________________________________________

Well then, here you go.  The source to Slayer.  It's a mess.  Have fun.
Please note that most of this (ie, the front end) is Luke's, not mine...
I did very little on the front end in the grand scale of things... infact,
come to think of it; there isn't all that much I /did/ do on this other than
lots of engine tweaks, templates, icons, optimisations, device menu, SScript,
etc...

Slayer is one of our proudest and most hated projects.  It makes us proud
because it is actually quiet good, and it's a big program, plus it was
very popular and got excellent reviews.

The reasons why we hate it, is that it is horrible, badly written, not
thought out and unmaintainable.  I find it deeply amusing that it competed
with Killer and VZap so well. ;-)

Slayer's source is seperated like this...


    *
    |
    +- !KiwiLib
    |  |
    |  * Menu
    |  | Menu creation stuff Luke liberated from somewhere, then extended.
    |  |
    |  * Message
    |  | Same as above, but for message files.
    |  |
    |  * Misc
    |  | Lots of Misc stuff.
    |  |
    |  * ResFS
    |  | Lets people who like crashing things do things they shouldn't with
    |  | ResourceFS.
    |  |
    |  * SqshLib
    |  | Something that was cobled together that doesn't work.
    |  |
    |  * Upgrade
    |  | Code for not doing internet upgrades.
    |  |
    |  * Wimp2
    |  | Some code for detecting if the current task is being pre-empted by
    |  | Wimp2, and complaining if it is.
    |  |
    |  * WimpLib
    |  | Lots of Wimp routines and toys.
    |  |
    |  *
    |
    +- !Slayer
    |  |
    |  * !RunImage
    |  | Most of the front end bits, WIMP init, closedown, polling, reason
    |  | code handling and some of the veeners to the module (ie, disc
    |  | clicks)
    |  *
    |
    +- Libraries
    |  |
    |  * !Networx!
    |  | Graham's unfinished (hardly started) networking code.
    |  | 
    |  * AsmFunc
    |  | Some frequently called string handling routines in assembler
    |  | rather than BASIC.
    |  |
    |  * BigError
    |  | This is used when Slayer panics :)  Displays a disassembly of the
    |  | code that crashed, and offers to write it to a file so you could
    |  | email it to us.
    |  |
    |  * ChipID
    |  | Code stolen from !ARMSI to do CPU detection.  You should note that
    |  | this code isn't under the GPL, it is under the original licence of
    |  | ARMSI, which is Public Domain, which means no copyright what-so-ever
    |  |
    |  * DeviceMenu
    |  | This is the code to build the devices menu.  It is basically lots
    |  | of menu warnings and specific code for non-FileCore stuff.
    |  |
    |  * DiscAuth
    |  | Luke's disc authorisation stuff.
    |  |
    |  * EasySTW
    |  | A veener onto gerph's DispLib to make it slightly simpler, and suit
    |  | our needs more.  Not that DispLib isn't included in this package.
    |  |
    |  * Expirer
    |  | Routines to expire archived log files based on the date in them, not
    |  | their datestamp.
    |  |
    |  * FastSave
    |  | Very unfinished code to do binary fastsaves of options.
    |  |
    |  * FileClose
    |  | Code to deal with the closing of files (and what should be done to
    |  | them, scan etc)
    |  |
    |  * Fingerer
    |  | Code to do with fingerprint collection.
    |  |
    |  * FTMenu
    |  | Quick and dirty non-sorted, memory-leaking filetype menu creation.
    |  |
    |  * Help
    |  | Stuff to do with interactive help
    |  |
    |  * HideTask
    |  | Code used to hide Slayer from the task display.
    |  |
    |  * HScan
    |  | Heuristic scanning of !Boot files
    |  |
    |  * Icons
    |  | You really don't want to know.
    |  |
    |  * ImageTypes
    |  | *REALLY* broken code to decide which files are images and should
    |  | be scanned.  There is a fixed version of this somewhere, but I've
    |  | lost it somewhere on my HDD.
    |  |
    |  * Logging
    |  | Code for doing buffered, formated, wrapped logs, both to file, and
    |  | screen.
    |  |
    |  * MemScan
    |  | This has obviously something to do with memory scanning of viruses,
    |  | but I'm not sure what.
    |  |
    |  * Misc
    |  | Some misc routines.
    |  |
    |  * ModKill
    |  | *VERY* dodgy code for killing a module, and restarting again.
    |  | Actually stolen from a virus :)
    |  |
    |  * Module
    |  | Slayer's module.  Lots of bad code in here, but it works. Ish.
    |  |
    |  * Options
    |  | Code for handling textual options files nicely, if slowly.  Also
    |  | handles all of the saving and loading of Slayer's options, and
    |  | updating the various windows.
    |  |
    |  * PluginCRC
    |  | Simple certification of plugins.
    |  |
    |  * Plugins
    |  | Code to load most of the plugins.
    |  |
    |  * raFS
    |  | An ickle bit of assembler to call 'SWIishes' in raFS.
    |  |
    |  * Scanning
    |  | The BASIC half of the scanning engine.  Don't expect to understand
    |  | what on earth this is doing.  I don't, and I'm ment to maintain it.
    |  | the most interesting bit is PROCgrab_dir, btw.
    |  |
    |  * SelfCheck
    |  | Code todo with checking Slayer hasn't changed, and fixing its self
    |  | on loading and when running.
    |  |
    |  * SScript
    |  | Slayer's scripting language... always a good comical read.
    |  |
    |  * Strings
    |  | General String handling stuff.
    |  |
    |  * Territory
    |  | Territory detection and selection stuff (that works under RO3.00! :)
    |  *
    *

The plugins should be fairly easy to understand their layout, more difficult
will be understanding the code.

If you are willing to be *EXACT* with a question concerning Slayer's source,
ie... What does this line in this file actually do, and why? then I'll see
what I can do (either answer it, or pass it on to somebody who can).

Have lots of fun,

Rob Kendrick (rob@kiwisoft.co.uk)
Wednesday 5th July 2000 @ 1436.