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

Pages: 1 ... 16 17 [18] 19 20 ... 62
256
TI Z80 / Re: Star Trek reloaded (bad pun on the 'ld' command)
« on: November 28, 2011, 07:28:15 pm »
well, since space is space, all u see are stars, so the only indicator of your direction are your controls. but, it would still be better to have actual space movement, rather than just 6 directions.

257
TI Z80 / Re: Star Trek reloaded (bad pun on the 'ld' command)
« on: November 28, 2011, 07:21:25 pm »
I'm glad this is progressing again. I unfortunately have no time to read your second post, though, since it's very long. However, I'Lll try when I have some time. Also by 3D do you mean wireframe and stuff like Star Fox 64 or something?

Not sure what those things entail. By 3D, I mean that you can say press the down arrow and, rather than move up by 90 degrees, you move up by...say...10 degrees. So, its like ur flying in space, rather than playing 3D pacman.

258
TI Z80 / Re: Star Trek reloaded (bad pun on the 'ld' command)
« on: November 28, 2011, 06:47:37 pm »
Progress update: Got an idea figured out to display a ship in the viewscreen if it is in front of you. Bear in mind that the data entry for each network member is:

5-byte member ID
8-byte username (padded if necessary)
6-byte position (xx,yy,zz)
3-byte sector (x,y,x)

So, first I check the sectors. If a ship is not in the same sector as you, I skip that entry. If it is, then I check the high byte of the axis you are moving on against that of the current entry. If it is not the same, I skip that entry. If it is, then I check the low byte. If the ship is in front of you, then I check the high bytes of the other two axises of the entry. If the high bytes of those two axis positions are the same as yours, then you see the ship on the view screen. The only downside I see to this is if you are, for instance, moving forward and the other ship is at $0012,$0000 and you are at $0011,$FFFF, you will not see the opponent on your screen, despite him being just one unit away (though you will be able to see him on your sensors). Comments? Suggestion?

The movement is only in 6 directions. Forward, Backward, Left, Right, Up, and Down. I kind of want to support full 3-d movement. Can anyone help?

As for weapons firing, you are most effective when you can lock onto your target. In order to do this, the sensors must be online. While locked, photons and phasers fly directly at the target. Without sensors locked, weapons will not function at all (except for the scrambler). As for weapons firing, I planned to make them instantaneous, but I've been thinking I should animate them flying through space in the view screen. Can someone help me with this?

As for locking, picking your target is very easy with gCn. Your calc will not spend time finding its target. "Locking-on" returns a pointer to the current target's data entry, making it trivial to return the ID for sending. ;) That's why I mandate locking for weapons firing.

The scrambler is an all-targetting weapon. It basically causes you to emit 0's for all your position data for some time, thus rendering you invisible. While you can be found at that corner of the map, you calculate the odds of being there. The scrambler is like the cloak in that it makes you invisible, but eventually, the jamming transmission wears off.

The cloaking device may be used to render you invisible until you choose to remove it. It emits 0's for your position data. Thus, you cannot be targetted. On level 0, you have no cloak (go figure). On level 1, you cannot transport or attack while using it. On level 2, you can transport, but not attack. On level 3, you can transport and attack.

Using the cloaking device consumes energy, as does firing weapons, using the shields, and mostly everything else. Every time you fire a phaser or photon, you use power. Having shields raised, being moving, and having the cloak raised also consume power at a steady rate. Your Power Level will drop if you begin using too much power at once, and if you run out, everything fails. Your Generator will be supplying power to all main drives by increasing your Power Level by a certain amount at a steady rate. This rate is in direct proportion to the current percent health of the generator multiplied by the level of the generator (you can equip upgrades). As your generator takes damage, the rate of power output decreases, thus your ship cannot produce power as fast. If your generator is knocked offline, once your Power Level drops to 0, shields drop, cloaks fail, and all other systems (except repair (which gets to work) and life support) go offline. Trust me, you don't want that to happen.

So, in summary:

1. Any comments?
2. How difficult will it be to support real 3-d movement, not just 6 directions?
3. I need help with firing animations.

259
ASM / Re: Please Help
« on: November 26, 2011, 12:42:27 pm »
well, i cap at 30 members to a server, so...30x21 is 630 bytes...fittable within saferam1. :)

260
ASM / Re: Please Help
« on: November 26, 2011, 12:24:26 pm »
Well, I'm not going to make the first routine, either you can do it or find someone else, but don't wait for me to post it ;)


As for relative positions, that's easy. There are two ways to go about it, and it depends on how you want your ship to move:

1. Ship is always dead center of screen:
    For this, we want to first see how the other ship compares relative to your ship. So (opponentX) - (yourX). That will tell you where they are relative to you. Then, just add the location of your ship on the screen. So lets say that your ship is on X=25 of the physical LCD, then you would add the little math problem from up above to 25 to get your location.

Example: (yourX) = 190, (opponentX) = 180, Your 50x50 screen is in the top left corner of the LCD. Your ship is displayed at (25,25)
     180 - 190 + 25 = 15. So you would display the enemy at X=15.

2. The ship can move freely and the screen scrolls when it gets close to the edge:
     I'll let you take care of the scrolling, we're only worried about displaying other ships. For this, the equation is just (opponentX) - (scrolledX) + offsetToScreen. It doesn't even matter where (yourX) is.

Example: (opponentX) = 180, (scrolledX) = 175, Your 50x50 screen is in the top left corner of the LCD.
     180 - 175 + 0 = 5. So you would display the enemy at X=5.

Ok, sorry. I hiatused this for a while and am back to it now. The original routines you gave me to search for stuff in the appvar, i will be using, however the format is now: 5-byte ID, 8-byte username, 6-byte coordinates (2 for x, 2 for y, 2 for z), and 3 byte sector (1 for x, 1 for y, 1 for z). Plus, I will be using saferam, rather than an appvar, so it should make this easier, right? Once we edit those original routines that search for username, ID, or coordinate, I should be able to handle the rest.

261
TI Z80 / Re: Chess
« on: November 25, 2011, 04:56:35 pm »
I meant like connecting two of the same calcs and playing each other :P

I've thought about that, the trouble is that linking is super hard. It's unreliable and a pain to test. So, you'll just have to give your calculator to your friend who is still probably sitting less than 1 foot from you.

thepenguin, why not provide support for 1v1 over gCn and Calcnet?

I don't want any dependencies. If I do something, I like to do it myself.

well, I can understand that...I'm that way too. But let me clarify...I meant the ability to go onto a virtual hub and find a player on the network, who may be in another country and play against him. Not to use gCn for 1v1 over link...

262
TI Z80 / Re: Chess
« on: November 25, 2011, 11:19:23 am »
I meant like connecting two of the same calcs and playing each other :P

I've thought about that, the trouble is that linking is super hard. It's unreliable and a pain to test. So, you'll just have to give your calculator to your friend who is still probably sitting less than 1 foot from you.

thepenguin, why not provide support for 1v1 over gCn and Calcnet?

263
TI Z80 / Re: Star Trek reloaded (bad pun on the 'ld' command)
« on: November 22, 2011, 10:26:20 am »
It's been a while, hasn't it?

I did almost a complete rewrite of this program, using a monochrome splash screen that is much simpler. The image is at http://clrhome.org/projects/startrek/images/splash.gif. What I would like from you guys is basically an example of an interface. Show me what you would like the "inside" of the ship, the view screen, to look like.

Also, a while back, someone gave me some code on how to find a certain calc ID, coordinates, or username, in an appvar. I forgot where it is. Can someone link me to it. Plus, I'm using saferam for this now, not an appvar. That shouldn't change much.

264
News / Re: Deep Thought becomes manager
« on: November 08, 2011, 09:02:41 pm »
Congrats.

265
ASM / Re: Chemical Formula Input Routine
« on: November 05, 2011, 03:33:25 pm »
If I ask for another text input routine, I give you guys permission to curse me out. :).

I'm trying to accept chemical formula input. In this routine, the first letter prompted for should be only uppercase. The second should be only lowercase (those are the only two allowed options). Pressing the down arrow key should allow you to type a subscript (there should be a designation in memory to indicate where the subscript starts and ends). Pressing the up arrow allows you to type superscript charges (2+, -1, ect.). Again, there should be a designation where the superscript starts and ends. You should be able to type parenthesis at any time. Can someone write such a routine for me? I'd even use the one out of the Balancer app, if I know who wrote it and have permission to use it.

Cancel. I have obtained permission from the author of BALANCE.8XK to use that routine.

266
ASM / Chemical Formula Input Routine
« on: November 04, 2011, 01:19:45 pm »
If I ask for another text input routine, I give you guys permission to curse me out. :).

I'm trying to accept chemical formula input. In this routine, the first letter prompted for should be only uppercase. The second should be only lowercase (those are the only two allowed options). Pressing the down arrow key should allow you to type a subscript (there should be a designation in memory to indicate where the subscript starts and ends). Pressing the up arrow allows you to type superscript charges (2+, -1, ect.). Again, there should be a designation where the superscript starts and ends. You should be able to type parenthesis at any time. Can someone write such a routine for me? I'd even use the one out of the Balancer app, if I know who wrote it and have permission to use it.

267
ASM / Re: Angle Calculation Help
« on: November 04, 2011, 01:00:26 pm »
Hmm, couldnt you use smiles for storing?
for example,
   |  |
  -c=c-  would be c=c
   |  |
I'm not trying to store. I'm trying to convert a molecular formula into a drawing. How you write the formula doesn't affect how it draws.

268
ASM / Re: Angle Calculation Help
« on: November 04, 2011, 09:11:50 am »
No, 6 is the max, as long as you don't go into crazy stuff which I'm not even sure is possible. (6 atoms involves hybridizing the s, p, and d orbitals, to do 8, you might have to start messing with the f orbital.) Also, you have to remember that atoms share electrons, so, for normal cases, you'll only have 4 atoms bonded.

You could do 2 bytes for flags, but to be honest, I don't think you'll ever run into a situation where you'll need 5 and 6 to have flags. Atoms can normally only have 4 bonds, so that is not a problem. The only time you start messing with the 5th and 6th atoms are when you go into expanded octets. The only possible way that your 5th atom could have a flag would be if it were double bonded, and I'm not sure this ever happens. You would have something along the lines of SF4O, which is not a real compound, and the O would be double bonded to the S. I don't think this is something you need to worry about though.

I don't think you understand what I meant by the ID. Lets say we're doing KNO3: Here's what your full data set would look like.

1. K [19][0][+1][11 00 00 00][2][0][0][0][0][0]
2. O [8][3][-1][11 00 00 00][1][3][0][0][0][0]
3. N [7][0][+1][01 00 00 00][4][2][5][0][0][0]
4. O [8][2][0][01 00 00 00][3][0][0][0][0][0]
5. O [8][3][-1][00 00 00 00][3][0][0][0][0][0]

The ID's are essentially pointers to the data. The only thing that makes it nicer is that it is 1 byte rather than two. Of course, you could do addresses if you really wanted, it would just take up more space.

Pointing to a polyatomic isn't a bad idea actually. Though, you'd save yourself a headache if you manage to parse the polyatomics on the fly. The only problem with pointing to polyatomics would be difficulties with drawing them. You'd have to special case them because you'd have a single polyatomic ion that might be bonded to multiple things. Cu(OH)2.

Well, you have more experience with this stuff, so I'll go with whatever you think is best.

269
ASM / Re: Angle Calculation Help
« on: November 03, 2011, 07:57:27 pm »
Hmmm. Why not just two bytes, and have four bits out the second allocated to 5 and 6, just for the sake of making it easier on me. And, can you not have 7 or 8 atoms bonded (like 8 H's). Now, as for bonded id, could I do, instead of the number of the array it is bonded to, a pointer to that atom's data? That way, I can point to another atom if needed, or if bonded to a polyatomic, point to that polyatomic's entry in the "polyatomics table"

270
ASM / Re: Angle Calculation Help
« on: November 03, 2011, 10:43:55 am »

[Atomic number][lone pairs][charge][flags xx112234][bonded id 1][bonded id 2][bonded id 3][bonded id 4][bonded id 5][bonded id 6][display x][display y]

Where:
 - atomic number = atomic number
 - lone pairs = number of lone pairs
 - charge = formal charge
 - flags = bond type 0 = single bond, 1 = double bond, 2 = triple bond, 3 = ionic
 - bonded id # = the array position of the other atom it is bonded to
 - display x/y = where it is displayed on the full buffer

So with this system, you have the 10 byte atom structures lined up in memory. Each one would have an ID based on where it is in memory as well as the atoms it is bonded to. The goal would then be to parse what the user typed and turn it into one of these structures. If you start to get triple bonds, you may have to switch some of the bond id's around as you add them, but that is fine.

Using this system, you should be able to represent any kind of atom I can think of, even complex organic molecules.

One problem...the flags.

A flag can only be 0 or 1, but i'd also need 2 or 3 as a value. How is that gonna happen?

Pages: 1 ... 16 17 [18] 19 20 ... 62