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

Pages: 1 2 [3] 4
31
Axe / Negative/Opposite Numbers (SOLVED)
« on: November 20, 2012, 03:17:31 pm »
Is there a way I can make it so "If EXP1 = true, 1→Z, else, -1→Z"? Or some variation of this? I need a negative number to use in a formula (as in the output eventually will not be negative)

32
Axe / Re: Full Speed Command?
« on: November 14, 2012, 11:29:44 am »
Thank you all for the replies! Thought I already responded...  Thumbs-ups are on me ;)

33
Axe / Full Speed Command? (SOLVED)
« on: November 02, 2012, 12:13:00 pm »
I heard there was a "Fast" or "Full Speed" command in Axe, I don't see it in the documentation though. How do you use it?

34
Axe / Enemy Routing Tips?
« on: October 11, 2012, 12:27:12 pm »
I'm having a dilemma trying to decide how to route the enemies in my game the best way. Right now they go straight toward the player, and will slide along walls if the player is diagonal from them (they will not go through walls). The problem is that if a player is directly on the other side of the wall (walls are red in the picture), the enemies will just stay against the wall, so I need to re-route them to go through the nearest doorway. What do you guys think the easiest way to do this would be?

(the player is the dot inside the walls, the enemies spawn outside)

35
Axe / Re: Enemies Freezing after another enemy is shot? (UPDATED)
« on: September 04, 2012, 04:15:54 pm »
Thank you all! I finally figured out the issue with my program, its that I didn't take into account that I needed to make two separate variables, one for the number of total zombies, and one for the CURRENT number of zombies. It was basically trying to read X/Y/health variables for "dead" zombies, rather than skipping over them, due to the way I set up the memory.

Bottom line, its all solved, thanks to inspiration from you guys! Thanks for the optimization suggestions, i'll definitely use them! Thumbs ups are on me guys ;)

36
Axe / Re: Enemies Freezing after another enemy is shot? (UPDATED)
« on: September 04, 2012, 12:19:04 pm »
Wow thanks for all the input guys! And yeah, you're right, I meant to do 18 not 16 for the "3" key =P
Also would the arithmetic logic be a good optimization for speed on a ti84+SE?

37
Axe / Re: Enemies Freezing after another enemy is shot? (UPDATED)
« on: September 03, 2012, 10:12:47 pm »
.
Code: [Select]
Lbl DIFF1
0→A→B→C→S→T→R→U→D→I→θ→G→{L1}→{L2}

Oh I see, should I use the Fill( command to zero out the ram? I converted this program from BASIC because I realized it was getting to slow, hence some errors =/

The following code probably doesn't make much sense because I havent implemented other guns yet =P  The L variable stands for "which gun is selected" and, pressing key 15 (CLEAR) ends the game quickly for a quick exit to the game.
Code: [Select]
:If K=15
:Goto DIE:End     
:If K=33
:0→L:Else:End
:If K=34
:1→L:Else:End
:If K=26
:2→L:Else:End
:If K=16
:3→L:Else:End

What is a LUT and what does inData do? I looked it up, but the definition doesnt make much sense to me.

The Z variable was actually left-over from when I changed around variables. Its supposed to check if theres no zombies before you can start another round, but I left it so you can restart a round while theres zombies out for testing purposes. (The real variable is now U for zombie count).
Code: [Select]
If K=47 and (Z=0):1→R:End
I never knew about the "+" and "*" operations, I'll look into it!
Your optimizations also are very, very useful. I'll optimize the whole program after I figure out this error.

I'll make a version of the program that is easier for you guys to read now, commenting on it and all.

38
Axe / Re: Enemies Freezing after another enemy is shot? (UPDATED)
« on: September 01, 2012, 02:00:25 pm »
Narrow down the randomness of a "sometimes-occuring" bug to specific criteria that must be met to reproduce the problem.

Now that I'm back to school, I've continued working on the problem. I figured out that the bug occurs if I shoot the enemies out of order. Like if theres enemy 1, 2 and 3, if I kill them out of order like 1 then 3, #3 will be frozen in place, and it respawns at a different place (figured out it was spawning 65k spaces away out of map). I think somethings happening and its running code for the wrong zombie. Like if a piece of code for turning off pixels and moving the zombies x/y variables to another place is supposed to run for zombie #3, it instead turns off the pixels and assigns the variables to zombie #2. It may be more clear if you run it yourself, heres the newest version of the game, with diagnostic variables on screen for each zombies health (starts at 100, for now when it gets hit by a bullet it changes to 0, then after the score is processed it changes to 101)

39
Axe / Re: Enemies Freezing after another enemy is shot? (UPDATED)
« on: May 21, 2012, 04:30:51 pm »
I have had a similar problem with a project of my own previously, and assuming the enemies freeze the moment another one gets killed, you might be doing something wrong in the code that removes enemies from the buffer when they get killed. An enemy "freezing" could have several causes: forgetting to erase an enemy from the screen buffer, or incorrectly/not moving backwards the remaining enemy entries in the buffer when one is removed (in my case it was the latter, causing enemies to turn invisible and randomly freeze and warp around when one was killed).
It's 2nd to shoot (also included the more necessary info in first post)
And yes, the enemy freezes as soon as another gets killed. I don't think its a problem with erasing from the buffer, as it works for other zombies, and I move backwards the remaining enemies after the loops, so it shouldnt interfere.
Also, I appreciate the reply!

40
Axe / Re: Enemies Freezing after another enemy is shot?
« on: May 20, 2012, 03:10:47 am »
Days later and I'm still confused by it. I've tried so many things, to no avail :c

41
Axe / Re: Correction Code
« on: May 11, 2012, 05:02:20 pm »
You need:

GetKey → K   //Should have this at start of program loop
If K=1          //If key pressed is down
1 → {L1+(G*4)+2}  //Store 1 to that bullets direction variable
End
If K=2.... etc.

42
Axe / Re: Enemies Freezing after another enemy is shot?
« on: May 11, 2012, 04:55:21 pm »
Halp please :c

43
Axe / Enemies Freezing after another enemy is shot? (SOLVED)
« on: May 08, 2012, 10:55:35 pm »
PROBLEM SOLVED, THANK YOU ALL FOR INPUT!

So I'm working on my game, and I've run into a problem I can't seem to figure out. When there are multiple enemies, sometimes when I kill one, the others freeze in place, and will not disappear if I shoot it, and it's driving me crazy as to why! If you run the program attached, you can see the problem in the 2nd or 3rd round. I'm pretty sure it has to do with this segment of code:
Spoiler For Spoiler:
:For(G,1,I)
:If pxl-Test({L2+(G*4)},{L2+(G*4)+1})
:For(θ,1,U)
:If {L2+(G*4)}=({L1+(θ*4)}) or ({L2+(G*4)}=({L1+(θ*4)}-1))
:If {L2+(G*4)+1}=({L1+(θ*4)+1}) or ({L2+(G*4)+1}=({L1+(θ*4)+1}-1))
:{L1+(θ*4)+2}-100→{L1+(θ*4)+2}
:0→r1
:If {L1+(θ*4)+2}=0 and (U≠0)
:S+10→S
:100→{L1+(θ*4)+2}
:Pxl-Off({L1+(θ*4)},{L1+(θ*4)+1})
:Pxl-Off({L1+(θ*4)},{L1+(θ*4)+1}-1)
:Pxl-Off({L1+(θ*4)}-1,{L1+(θ*4)+1})
:Pxl-Off({L1+(θ*4)}-1,{L1+(θ*4)+1}-1)
:5→{L1+(θ*4}→{L1+(θ*4)+1}
:r1+1→r1
:End:End
:End:End
:U-r1→U
:
:{L2+(I*4)}→{L2+(G*4)}
:{L2+(I*4)+1}→{L2+(G*4)+1}
:{L2+(I*4)+2)→{L2+(G*4)+2}
:0→{L2+(I*4)}→{L2+(I*4)+1}→{L2+(I*4)+2}
:I-1→I
:Else
:Pxl-On({L2+(G*4)},{L2+(G*4)+1})
:End:End

I appreciate any help! I doubt anyone will take the time to look through the code, but if you could run it and maybe make a suggestion as to what it is, It'd help me a lot!

EXTRA INFO:
Arrow keys to move, 2nd to shoot, clear to end game
I = Bullet count
G = Which bullet
U = Zombie count
θ = Which zombie
r1 = Just a temporary variable so the code runs through for each zombie/bullet and THEN the zombie count is decreased
L1 = zombie array
L2 = bullet array

44
Axe / Re: Line( not working for me?
« on: April 19, 2012, 11:58:51 pm »
I'm not 100% sure but I think you have to put Dispgraph somewhere in your program too.

Yup, thanks haha.

45
Axe / Line( not working for me? (SOLVED)
« on: April 19, 2012, 11:53:05 pm »
I have a program I made in Basic (birds eye nazi zombies), and I converted it over to Axe. I've gotten pretty much everything to work except Line('s and Pxl-On('s aren't displaying anything. I use this style:
Line(1,2,1,5)
Pxl-On(5,10)

Thats the same for Axe, right?

EDIT: In this post - http://ourl.ca/8409
I see "r" after line, like: Line(w,x,y,z)r
What does r stand for?


I feel dumb now, gonna go sulk in the corner and program  :P

Pages: 1 2 [3] 4