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 - trevmeister66

Pages: 1 ... 15 16 [17] 18 19 ... 71
241
TI Z80 / Re: Side Project #2: DUNGEON
« on: May 09, 2009, 09:53:48 pm »
Original map engine:


New map engine:


(there's a syntax error because those rooms haven't been designed yet)

EDIT: WOOT 300th POST!!!

242
TI Z80 / Re: Side Project #2: DUNGEON
« on: May 09, 2009, 09:48:16 pm »
the flickers not that bad, but it is a little slow. hmm, I wonder how big it will be. maybe I'll make it so that you can choose which one you want to use, the big one or the slower one
Its actually not that big. It's only about 16 or so lines, and it is faster. I'll post a screenie soon comparing both methods


243
TI Z80 / Re: Side Project #2: DUNGEON
« on: May 09, 2009, 09:20:37 pm »
You might be able to get a pretty good speed boost if you hard-code in the Text( commands to draw the map instead of looping over and having to use StorePic/RecallPic so many times.  i.e.
Code: [Select]
:Text(-1,0,0,sub(Str1...
:Text(-1,8,0,sub(Str1...
...
:StorePic 2
:Text(-1,0,0,sub(Str2...
:Text(-1,8,0,sub(Str2...
...
:RecallPic 2
It would add to the program size, but you would be eliminating 16 calculations of 8A-16 and 15A-29; seven StorePics and RecallPics; and the overhead for running a For( loop.  Plus, StorePic and RecallPic are pretty darn slow and StorePic automatically displays the screen so you could be getting some flicker.
Hmm that's a good idea. I think I'm gonna go with that, or at least try it out

244
sucks that we have to go to such lengths, but you got to do what you got to do

245
TI Z80 / Re: Side Project #2: DUNGEON
« on: May 09, 2009, 05:44:13 pm »
Hmm that is pretty good. I would just make it so you don't fall down when you're on the monkey bars.

Also, it forces you to go to the next room when you get to the edge instead of when you go passed the edge.. that's the main difference between yours and mine

246
TI Z80 / Re: Side Project #2: DUNGEON
« on: May 09, 2009, 05:30:25 pm »
Hmm can I see all your code so I can run it with my ROM/mess with the code a little to see if I can optimize some things?

247
TI Z80 / Re: Side Project #2: DUNGEON
« on: May 09, 2009, 05:19:00 pm »
Here's how fast my game is now:


Here's how fast it would be if I didn't slow it down:


It's too fast to be playable if I go without making it slower

248
TI Z80 / Re: Side Project #2: DUNGEON
« on: May 09, 2009, 05:07:46 pm »
Hmm I would recommend not using list's for variables that are going to change a lot. Lists are pretty slow and can really slow down your game. Just use a variable for it.


249
TI Z80 / Re: Side Project #2: DUNGEON
« on: May 09, 2009, 03:28:27 pm »
Why not just keep C and D as your location, since you use A for displaying the map? Would save quite a few bytes.

250
TI Z80 / Re: Side Project #2: DUNGEON
« on: May 09, 2009, 02:35:06 pm »
yeah I saw a bunch of things you could make faster. I have one question about your code though, why are you using C and D as well as A and B for your characters location?

251
TI Z80 / Re: Side Project #2: DUNGEON
« on: May 09, 2009, 02:10:59 pm »
I figured it out, and I also figured out how to detect the way it is, I'll post my code in a bit.
Code: [Select]
:For(A,1,8)
:Text(‾1,8A-8,0,sub(Str1,15A-14,15
:StorePic 2
:Text(‾1,8A-8,0,sub(Str2,15A-14,15
:RecallPic 2
:End
:2→B:3→A
:DelVar J
:While 1
:A→C
:B→D
:Text(‾1,8A-8,6B-6,"Ω
:DelVar K
:getKey→K
:If K:Then
:B+(K=26)-(K=24→B
:If B≠D
:Then
:If ""=sub(Str1,15A-14+B-1,1
:D→B
:End
:End
:If ""≠sub(Str1,15(A+1)-14+B-1,1
:Then
:A+1→A
:If J:A-1→A
:Else
:J+L1(1)(K=21→J
:End
:If J:Then
:A-1→A
:J-1→J
:End
:If A≠C or B≠D
:Then
:Text(‾1,8A-8,6B-6,"Ω
:Text(‾1,8C-8,6D-6,"
:End:End
it runs pretty quickly on the 83+. this version also includes spikes and stuff.
whoa just saw this. I'll post my code for you in a sec.

Code: [Select]
While Q>0 // Q=Health

G-(G>0->G  // This is my 'if you jumped' variable
H+not(G->H  // This is my gravity variable.

If E=1 // If there's an enemy in the room
Then
prgmZ4
End

If not(G) and not(fPart(H/2)) and not(inString(Str0,sub(Str2,T+14,1  // more gravity stuff
Then
Text(-1,8D-16,6C-12,"
T+14->T // Location in string
D+1->D // Player (Y) variable
If D>9 // If you go below the map
Then
M+1->M
2->D
14+C->T
prgmZ1
End
Text(->1,8D-16,6C-12,"Ê
End

getKey->K

If K=25 // if you jump
Then
If (inString(Str0,sub(Str2,T+14,1 // makes sure you're on a tile and not in the air
Then
4+2(1=L(1->G // Sets your jump to '4' or '6'
End
End

If G>0 and not(fPart(G/2)) and not(inString(Str0,sub(Str2,T-14,1 // if your 'jump' is still activated and nothing is above you
Then
Text(-1,8D-16,6C-12,"
D-1->D
T-14->T
If D<2  // if you went above the map
Then
9->D
M-1->M
14D-14+C->T
prgmZ1
End
Text(-1,8D-16,6C-12,"Ê
End

If (D=I and C=J) or sub(Str2,T,1)!=" " // if you hit an enemy or walked onto something
Then
prgmZ3
End

If (K=24 or K=26) and not(inString(Str0,sub(Str2,T-(K=24)+(K=26),1 // if left or right was pressed AND nothing is in the way
Then
Text(-1,8D-16,6C-12,"
C-(K=24)+(K=26->C
T-(K=24)+(K=26->T
If C<2 or C>13 // If you went outside the map
Then
L+(C>13)-(C<2->L
13(C<2)+2(C>13->C
14D-14+CüT
prgmZ1
End
Text(-1,8D-16,6C-12,"Ê
If (D=I and C=J) or sub(Str2,T,1)!=" "
Then
prgmZ3
End
End

If max(K={24,25,26  // Just here to fix a bug that I had found, you don't need to worry about it
Then
If "x"=sub(Str2,T-(K=26)+(K=24)+14(K=25),1
Then
Text(ú1,8(D+(K=25))-16,6(C+(K=24)-(K=26))-12,"!
StorePic 1
Text(ú1,8(D+(K=25))-16,6(C+(K=24)-(K=26))-12,"x
RecallPic 1
End
End

End
The 'not(fPart(H/2' and 'not(fPart(G/2' are both put in to slow down the game.. essentially they're only run when those variables are even, which happens every OTHER time the loop is run.

252
TI Z80 / Re: Side Project #2: DUNGEON
« on: May 09, 2009, 02:08:50 pm »
yours is probably faster now because I have a bunch of other stuff going on at the same time (well not a 'bunch', but you know what I mean).

Heh seeing your ss makes me want to finish this...time to get back to map designing..bleh

253
Introduce Yourself! / Re: Hello
« on: May 09, 2009, 01:13:50 pm »
Here's some milk to go with those peanuts and cookie:


254
Miscellaneous / Re: Doritos Spicy Sweet Chili
« on: May 09, 2009, 01:10:20 pm »
Hmm tough choice, but Netham45 is a lobster.

255
Other / Re: "LEGAL" Hacking . . . really
« on: May 09, 2009, 01:09:07 pm »
"Hacking" and "Cracking" are similar but different. Hacking is breaking in somewhere for informational or testing purpose, like to test the security of a website or whatever. Cracking is breaking in somewhere with the intent to cause destruction. Hacking has gotten a bad rep because non-computer people call anything bad dealing with internet security break ins "hacking".

The government, and businesses in general, are already hiring Hackers, the people who know how to all that, in hopes to prevent a Cracker from breaking in...they just don't call it by it's real name. I think my college calls it "System Safety Management" or something. It's a couple of classes available in my degree that I can take.

Pages: 1 ... 15 16 [17] 18 19 ... 71