Login [Register]
Don't have an account? Register now to chat, post, use our tools, and much more.
Im currently working on a game series named Killer. There will be six parts to it. If you want to see parts of the first one made (Im currently working on the second one) watch these two videos.

http://www.youtube.com/watch?v=XHqH5Uqg9GM
http://www.youtube.com/watch?v=3iSKRSaeII0

Tell me what you think.
For those of us not able or not willing to click through to the videos, would you mind describing the basic premise, as well as the genre?
Well, I dont know the exact genre, but you go into a gypsy tent and pay 10 dollars for a wish card that says that you have one day to do whatever you want.

If you want to see my first part of this series...
http://sc.cemetech.net/?xpi=8b732edcd576a41fbcea5aa48b5347ca
adamac15 wrote:
Well, I dont know the exact genre, but you go into a gypsy tent and pay 10 dollars for a wish card that says that you have one day to do whatever you want.

If you want to see my first part of this series...
http://sc.cemetech.net/?xpi=8b732edcd576a41fbcea5aa48b5347ca
I noticed this:
Code:
Then   0
While    0
Repeat    0
For(   0
End   0
That means that it's entirely linear, plus Menus, Gotos and Lbls. Looking at the source, I feel like you need a subprogram that will take a string of text, ClrHome, display the string with word-wrapping, then Pause. I think that would save you significant space. Follow me?
um...not really
What parts don't you get? I/anyone would love to help you understand better. Do you understand any of the program flow things Kerm was talking about?
the thing i dont get is the subprogram thing he mentioned.
Ah, that's actually a pretty simple concept ^^ So, you have your main program that has all your conditionals, etc in it. But you use a routine multiple times (the same routine) one way to save space (and speed?) is to put that routine into a subprogram. In other words, make a new program with that routine in it, and in your main program call: prgmPRGMNAME to run your routine. Make sense?
oh i get ya

so like :prgmPACLR
:Pause
:ClrHome?
adamac15 wrote:
oh i get ya

so like :prgmPACLR
:Pause
:ClrHome?


Yeah, in that form.

Say I had to draw a border around the graphscreen every once and a while. That could take up a lot of space. So, I make a new program that has those commands in it. Back in the main program I want to draw borders, so I run the new program.


Code:

prgmMAIN
stuff here
:prgmBORD (this is where I would draw borders and stuff)
more stuff



Code:
prgmBORD
:clrDraw
:Horizontal 10
:Horizontal -10
: Vertical 10
: Vertical -10


The main program would run the smaller program saving soace since you don't have to type out the smaller program every time you wanted borders.

Does this make sense, or do you need more help?
yea it makes sense. but i need a calc before i can do that.
No, forget subroutines. You can't readily compress dialogue, and it takes four bytes to Pause:ClrHome each time calling a subroutine for this can save at most 1 byte per instance, and that is quickly negated by the space that the subroutine would occupy.

@adamac15: What I said regarding CHOICE5 applies here. Watch:


Code:
:Lbl H
:Pause
:ClrHome
:ClrDraw
:AxesOn:Goto A

:Lbl K
:Pause
:ClrHome
:ClrDraw
:AxesOn:Goto A

:Lbl N
:Pause
:ClrHome
:ClrDraw
:AxesOn:Goto A


Taken right out of your program, except with the story removed. You even have:


Code:
:Pause
:ClrHome
:ClrDraw
:AxesOff
:Lbl A
:Menu("KILLER PART 1","START",B,"INSTRUCTIONS",C,"QUIT",D)


First off, since you're not using the graph screen at all...


Code:
:Pause
:ClrHome
:Goto A

Code:
:Pause
:ClrHome
:Lbl A
:Menu("KILLER PART 1","START",B,"INSTRUCTIONS",C,"QUIT",D)


So, the premise is to have that set of instructions played out before the main menu starts. What would happen if you wrote it before the Menu(), but underneath Lbl A? What would this mean for the other instances of those instructions?

The transition from these insights to the next action that you should perform needs to be fully understood before your habits can be revised for future projects; I don't want to run the risk of you carrying something out just because someone else said it was a good idea.
Weregoose, I was thinking that if you were to dump in all the text for a single screen as the Ans input to the subroutine, the enter/Disp/" savings would be sufficient to more than cover both the cost of the call and the subprogram's size.
Word-wrapping routine?
Weregoose wrote:
Word-wrapping routine?
I'd even be happy enough with a letter-wrapping routine. Smile
KermMartian wrote:
I'd even be happy enough with a letter-wrapping routine. Smile

Too bad.


Code:
PROGRAM:A
:Ans+" →Str1
:DelVar A1→B
:ClrHome
:While Ans
:inString(Str1," ",A+1→C
:If 16<Ans-B or not(Ans
:Then
:Disp sub(Str1,B,A-B
:A+1→B
:End
:C→A
:End
:Pause
:ClrHome


As in:


Code:
:Lbl Q
:"YOU JUMP IT AND GO OVER THE WALL
:prgmA
:"YOU JUMP,LET GO OF THE MOPED, AND GO THROUGH THE WINDOW
:prgmA
:"AS SOON AS YOU DO,6 OR 7 GUYS COME NEAR YOU
:prgmA
:"YOU TAKE OUT YOUR SHOTGUN AND KILL ONE GUY
:prgmA
:"THE GUYS START SHOOTING AT YOU
:prgmA
:"YOU THROW YOUR SHOTGUN DOWN AND START DODGING BULLETS
:prgmA
:"WHEN YOU SEE A BREAK IN THE BULLETS,YOU RUN TOWARDS A GUY WITH A MACHINE GUN
:prgmA
:"THE GUY HOLDS UP THE GUN AND SAYS 'TAKE IT! TAKE IT! IM SORRY!'
:prgmA
:"YOU THROW THE GUY IN THE AIR, GRAB THE GUN AND KILL EVERYBODY ELSE
:prgmA
:"YOU THEN PROCEED TO GO DOWN A TUBE LEADING INTO THE NEXT ROOM
:prgmA
:"
:prgmA
:Disp "END OF KILLER","PART 1","
:"CHOOSE KILLER 2 TO CONTINUE
:prgmA
:Goto A

Programming is there to make your life easier. You can use it as a tool to erect a tool that lets you segue your thoughts into your creative writing more expeditiously and without the nuisance of self-administering line breaks! After all, interactive fiction is just barely within the scope of what TI-Basic is all about. Wink
Finished Killer 2.

http://sc.cemetech.net/?xpi=b0cf842070133a10c017b55f66bc8a9e

Give me feedback, advise, etc.
adamac15 wrote:
Finished Killer 2.

http://sc.cemetech.net/?xpi=b0cf842070133a10c017b55f66bc8a9e

Give me feedback, advise, etc.


Very nice Adamac15, I can't wait to see Killer 3, you really should implement Weregoose's word-wrapping technique (which I found to be great, Weregoose, nice job). It relieves you of counting spaces and lines on the screen so you can focus more on the text's content.
i put it in on the calculator, but it didnt work.
Weregoose, that's exactly what I had in mind; awesome! Adam: can you be a bit more specific about what "doesn't work" about the program and tell us some of the debugging steps that you've taken thus far?
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 4
» All times are GMT - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement