Jump to content
IGNORED

"ANUBIS" ... a new side-scrolling shooter


Retrospect

Recommended Posts

39 minutes ago, senior_falcon said:

I haven't made a lot of progress on this. I see the symptom in the compiled code. Testing this in XB is very difficult. It takes a lot of time to register a "hit."

After hitting a death ship, I got BAD VALUE IN 25411

25411 AF=1 :: CALL SPRITE(#3,108,6,P5,P6,0,-40)

AF=1   P5=0   P6=0    So P5 and P6 are the bad value. I don't think that is the problem because I think the compiler would be OK with this. But I think there is probably something along these lines that is causing the problem.

This problem seems to happen after the last death ship has been killed. See if you can get XB to get this far to see what happens. I suspect the last DELSPRITE is not happening.

Thanks Harry.   The culprit in this case is line 25402, which is telling the '99 to jump to line 25411 if "AF" does not equal 1.  AF is for the death ship's firing activation.  I've been careless here.  So it's basically skipped over the bit that would have fed the '99 with the information it needed to form a missile position.    If AF did equal 1, then the death ship has already attempted to fire and these lines would not have been encountered.  The compiler would throw a wobbler if A5 and A6 had never been declared (even as null) in the program at any point before that.  

There's the matter of other ships "haunting" the program by turning into ghosts as well.  So I'm wondering if by the example of what I did in line 25402, I've been doing this all over the place and causing it myself?  I'll have a good look at this in a little while, just need to sleep in a moment.  Thankyou for having a look at it, I'll let you know what I've discovered ASAP.

Link to comment
Share on other sites

@senior_falcon I've altered the line 25402 to read;
25402 if af=1 then 25403 else 25411
25403 CALL POSITION(#1,P1,P2,#16,P5,P6)

So it wouldn't get the bad value anymore 

And then this happened .....  (This is tested in XB not compiled)


Line 25511 is for the activation of the walking robot missile!  I've missed it's X and Y coords out.

Link to comment
Share on other sites

@senior_falconalso there's this .... now i've corrected the robot walker's missile, thats working .. however there are still "ghosts" hanging around on the screen , these should have been "Delsprited" as they obviously don't function, they just glide aimlessly .... this is in XB uncompiled
 

 


 

  • Like 1
Link to comment
Share on other sites

I think a careful re-write of the code might be in order ... That I shall do in a few hours time , should I get a time slot.  Should only take a few hours to get up and running and I'll see what the sprites are up to.  Basically though they should only be there if they're called in a routine and if their "alive" array is set to 1.  When they've been shot they should all be dead and gone.  

Link to comment
Share on other sites

7 minutes ago, Retrospect said:

Steve.  I get it , your TI-CODED doesn't need them .   
We won't have this discussion on this thread but at some point I will talk with you regarding TI CODED.

I would be happy to talk about TiCodEd with you someday, but this was really not my point here, I talk about plain XB.

 

You use IF-THEN in XB very much like in TI BASIC, only with line-numbers, where you might enter the full statement as in my example, when it is just one or two statements. It might be a matter of personal taste, but IF <cond> THEN <next-line> else <line-after-next> looks more complicated to me, compared to IF <cond> THEN <code-from-next-line>.

 

So I left the line-number 25402 on the left and just pulled the CALL POSITION up from the line after, reducing the code a little.  

 

 

 

 

 

  • Thanks 1
Link to comment
Share on other sites

11 hours ago, senior_falcon said:

Hi Fabrice: Can you post an example that shows this behavior? I would like to figure out what is happening.

Not easy to make a video of this behavior due to the totally random of its appearing. To make a video, I would have to modify my program to pass anew several values in a same CALL LINK("VWRITE") then patiently waiting the problem occurs. But, I will do.

All I can say this time is that I could use/test my game during very long minutes, even many hours without having any problem, then suddenly the problem appeared . Note that, in my game, I don't use the Sprite motion feature to move them,  I just use CALL LOCATE. But when the problem occurred, some Sprites suddenly got diagonal motion movements and some characters pattern were destroyed (not the Sprite ones but some others and not all but always the same). A problem seen when the game was compiled or not, using Classic99 or ti994w emulators.

Link to comment
Share on other sites

11 hours ago, Retrospect said:

@senior_falconalso there's this .... now i've corrected the robot walker's missile, thats working .. however there are still "ghosts" hanging around on the screen , these should have been "Delsprited" as they obviously don't function, they just glide aimlessly .... this is in XB uncompiled
 

 

 


 

The first thing I thought about when the video started is that it reminded me of R-Type. You know where you get that power-up addition in front of your spaceship 

image.jpeg.7537800f8c744db767448d215013d4ee.jpeg

  • Like 1
Link to comment
Share on other sites

3 hours ago, SteveB said:

but IF <cond> THEN <next-line> else <line-after-next> looks more complicated to me, compared to IF <cond> THEN <code-from-next-line>

This is true.  A few years ago, the compiler wouldn't let you use any logic after a THEN statement and so I used to simply branch off to another line to do the logic there, and it did seem tidier.

Link to comment
Share on other sites

38 minutes ago, RXB said:

I would replace this line:

25402 IF AF=1 THEN 25403 ELSE 25411

with

25402 ON AF+1 GOTO 25411,25403 ! if AF=0 does then same thing as ELSE above, if AF=1 then AF+1=2 so like the THEN

 

I like these kinds of constructs when dealing with a constrained variable and use it (and ON...GOSUB) a LOT, but bear in mind this is not a nail.  This assumes the only values for AF are 0 and 1.  If AF is 2 or more, or -1 or less (i.e. not in {0,1},) this statement will error (which you can catch with ON ERROR.)

  • Like 1
Link to comment
Share on other sites

3 hours ago, OLD CS1 said:

 

I like these kinds of constructs when dealing with a constrained variable and use it (and ON...GOSUB) a LOT, but bear in mind this is not a nail.  This assumes the only values for AF are 0 and 1.  If AF is 2 or more, or -1 or less (i.e. not in {0,1},) this statement will error (which you can catch with ON ERROR.)

Well best case is AF=1 or AF=2 would be perfect fit. i.e. ON AF GOTO 25403,25411

Link to comment
Share on other sites

2 hours ago, RXB said:

Well best case is AF=1 or AF=2 would be perfect fit. i.e. ON AF GOTO 25403,25411

Yup.  That said, I am not certain that ON...GOTO <next line>,<another line> is faster than an IF...THEN <another line> which then falls through to the next line.  Definitely good for multiple values and targets like ON...GOTO <next line>,<another line>,<yet another>,<look another> &c.

 

A lot of different ways to wax that car.

  • Like 2
Link to comment
Share on other sites

TMOP identified a compiler bug involving comments at the end of a line. It turns out that lines with IF/THEN/ELSE that have trailing comments will not compile correctly. It turns out that ANUBIS has one such line:

1075 IF AF=1 THEN GOSUB 25435 ! death ship missile check

I removed the comment and recompiled with high hopes. But sadly, the phantom sprites are still there.

 

 

  • Like 2
  • Thanks 2
Link to comment
Share on other sites

Thanks for your time on this one @senior_falcon ... I've had a spare couple of hours today so I've done a couple of test with different games, and so far none of them have produced ghost sprites - only Anubis did .... which is making me think, it's me, not the compiler.  In fact one out of the two "tests" is now a full releasable game called Morg Blaster.  

The only other thing I can think, (if this IS a compiler bug) .... is it happening when we try to control sprites automotion values, using conditions? Anubis does this for all of it's enemies apart from the robots - the robots are the ONLY enemies that don't produce a "ghost". (i think!)

EDIT: Actually we do control automotion of the robots, scratch that.... I'm stuck then.  I'll do a careful re-write starting tomorrow at some point 

  • Like 4
Link to comment
Share on other sites

Psyching myself back into it with Anubis .... testing my sprite collision detection routine ... it ain't great ... then again I think it just needs more subs to the routine and it'll be golden.

There's quite a lot in the sub-list, even a routine that recoils the player ship when it fires.  Might keep it in, might take it out ... it's not THAT good .... 

 

Saucers are in anyhow, spinning away like they should .... player ships movement is spot-on ... just got missile-wrap issues.  (Auto motion value 60 won't help that!)

 

 

 

  • Like 2
Link to comment
Share on other sites

Here we have more progress and the sprite collision is 100 percent.  For now the game just loops between two different enemy types, and the "cruisers" that come on spinning and tracking the player don't fire yet but they WILL and boy will they be deadly when they do.  The saucers aren't too intelligent yet but don't they look good spinning like that?  I got the idea from a 50's flying saucer movie which Senior Falcon correctly identified as "Earth Vs The Flying Saucers" and it was Ray Harryhausen that did the fantastic job of the animation for those saucers.  

 

When you've blasted so many saucers, the rest that are alive speed away , at an impossible speed, out of sight - just like flying saucers would do .... and then come the cruisers ..... :)

We're getting there!  At some point this year there WILL be a new side scrolling shooter and it's going to do the TI99 and the Compiler justice.  

 

Edit:  At some point you'll see a slight pause - the TI did a garbage collection!  I guess the garbage always goes out on this day???

 

 

 

 

 

  • Like 3
Link to comment
Share on other sites

23 minutes ago, Retrospect said:

Edit:  At some point you'll see a slight pause - the TI did a garbage collection!  I guess the garbage always goes out on this day???

That is kinda funny.  I saw the pause but thought it was the video (audio muted.)

  • Like 1
  • Haha 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...