Scroll Code Compiler v1.03 by Davius Rex/Anarchic Designs ________________________________________________________________________________ What it be: ~~~~~~~~~~~ It be a utility that will generate ASM code to scroll the SHR screen. The code is formatted for ORCA/C's asm{} command, but you could easily change that (just replace the 0x's with $'s). New with version 1.03: - file appending is supported (as opposed to overwriting) New with version 1.02: - vertical scrolling is supported New with version 1.01: - you can specify the number of bytes to scroll - rightward scrolling is supported To use: ~~~~~~~ sc Where: is the name of the output file. is the name of the ORCA/C function to create (you can just paste the code inline for greater speed) is the y coordinate to begin at. is the last line to scroll. is the number of BYTES not pixels to scroll is the direction; l for left, r for right, u for up, d for down. is the option(s); +a for appending. Examples: ~~~~~~~~~ Good: sc scroll.cc Compiled_Scroll 0 40 1 r Scrolls the top 40 lines right. sc scroll.cc Compiled_Scroll 10 60 2 l Scrolls lines 10 thru 60 left. sc scroll.cc Compiled_Scroll 40 0 1 u +a Scrolls up; appends to the file Bad: sc My Code.c Compiled_Scroll 0 40 1 r ^^^^^^^^^ sc doesn't like spaces. You shouldn't program in HFS anyway. sc scroll.cc Compiled_Scroll 40 0 1 l ^^^^ startline must be less than endline. Suggestions: ~~~~~~~~~~~~ Keep sc generated code in a separate file from the rest of your code. Scroll code doesn't change much, but takes a long time to compile, so it's better to have a multi file compile and use a build script. (Hey, I do...) Junk: ~~~~~ Sadly, sc uses MVN/MVP, so it's pretty damn choppy. (I know asm the way Bill Clinton knows how to keep promises ). If someone cares to teach me stack scrolling, dp or whatever I'll write a new version that'll let you select which kinda to use, and whether to use 0x or $ as the hex character, etc. For now this MVN/MVP is pretty much OK if you just wanna do like 10 scanlines or so. The J-Bob demo did _not_ use code made with SC, FYI, it used the memory manager's BlockMove, which is far too slow. I have a new version that uses SC code and it looks OK, but not great. The JimBob demo was just something I threw together, so don't judge me by that -please-. It's really unoptimized and I gave out all the source code to the demos that were finished (sorry, I forgot that #3 didn't work - to work it import the Data:IPG.Data:Fonts.DAT to a resource in Hello type $B0B1 id 4), and left out the cool but crashy ones. Beware! The C source to SC is really really disgustingly coded. Why sc? ~~~~~~~ sc is just a tool to help me prove that cool graphics can be done in part using C. Bleh. About me: ~~~~~~~~~ I am Davius Rex, member of Anarchic Designs, a group consisting of myself and JimBob (huhuh I said "member" huhuhuh), and since we're the same person, it gets kinda lonely. Fortunately I have a girlfriend (finally!) who I'd like to thank for mental health support. This utility was produced with the help of Nirvana, Vito's "Real Italian" Pizza, and Pepsi (tm). How to reach me: (like you'd really want to do this...) ~~~~~~~~~~~~~~~~ Internet: Davius_Rex@bastards.colum.fnet.org (i've never tried this) IRCNick: JimBob, j-bob, DaviusRex FVNet: Davius Rex@Byte Bastards Watch for more cool utils like: ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ LZSS packer/unpacker with full source code [it's fast when depacking..] ver - easily put rVersion resources in from the command line And another demo! ("ick", you say.. well this new one's much better already! :) ~~~~~~~~~~~~~~~~~