Login [Register]
Don't have an account? Register now to chat, post, use our tools, and much more.

Would you like Magic the Gathering card game on your calculator?
Yes
 72%  [ 8 ]
No
 27%  [ 3 ]
Total Votes : 11

I was thinking that I could create a website that the server could link to. This website would have all the cards and their abilities, mana costs, and so on. But even that would take a while... As for triggers, I could write the equivalent of a If-Then loop. If the card has a trigger, then its waits until a specific set of events occur. If it doesn't have a trigger, then the system doesn't have to worry about it.
If you are willing to give Axe a try or learn assembly, you can have bit flags for whether a specific effect exists. But it will be very hard to code for the exact triggers on cards. You may want to check out the Yugioh Game Boy games, since they are the closest to the effect you seem to want.
I am willing to try Axe. How do I get started?
NanoWar wrote:
I don't think MTG is a game that can be easiliy coded at all. This sounds rediculous to implement. Where should I start. How do you do triggers?
http://www.e-reading.link/chapter.php/72410/54/Gottlieb_-_Magic__The_Gathering_Comprehensive_Rules.html

I mean you can make a similar game but implement the entire MTG rule set? I say: no way.

BTW: this is a mockup of a potential magic-like card game (I was just playing around with mana symbols, elements, etc.):



Mockup looks sick, but I'd agree with you that making a MTG clone would be much too hard, especially on a TI calculator. This is not to discourage the OP of the thread, but maybe try something less grand or big. You can always base your game off of MTG with some of the same mechanics, or gameplay style.

Other difficulties might include screen space, size of the program, you might actually run into some runtime errors with regards to the RAM the TI calculators are limited to (especially since you're doing this in Basic?).
I think that it is possible to write a program that difficult in Basic and connect it to a server. After all, it's like the moon shot in 1969- no one thought it was possible, but it was done. And this is just like that- it may be impossible to create a clone of the MTG game on a calculator, but I will surely try. And I play MTG, so I know all the rules, thank you very much. After all, someone has to try. But does anyone know anything about Axe coding? Because I don't.
Although I really don't know much about MTG (or anything at all) I know many people at my school who would love to play this game. I hope you keep going at this so maybe I can learn the game to Smile Also, sorry I don't know anything about AXE.
Do you know anyone that knows Axe?
I'm sorry, no I don't, but I'm 99.99% sure that more than a few people on this site do know Axe. Just ask around, someone can help.
Axe is for monochrome calculators only. You can't make an Axe program on a TI-84+CSE (or CE). You'd have to learn assembly. I'd be willing to teach what I know (which is very little), but there are a lot more CSE Asm programmers that are way better than I am. I'd suggest using 83+ Assembly in 28 Days (https://bitbucket.org/tari/83pa28d/src/) and combine that with the Doors CSE SDK (http://www.ticalc.org/archives/files/fileinfo/456/45654.html) and the Doors CSE ASM header (http://dcs.cemetech.net/index.php/ASM_Header_%28Color%29).
Thanks for the advice, but I have just one question.... Why is Axe only compatible with monochrome Graphing Calculator ?
and as for Asm, I do know a few words of it, but not enough to do any serious coding.
caleb1997 wrote:
Thanks for the advice, but I have just one question.... Why is Axe only compatible with monochrome Graphing Calculator ?
and as for Asm, I do know a few words of it, but not enough to do any serious coding.


Axe was built to basically be an alternate syntax to assembly. Assembly changed from monochrome to color, as new color commands were added in both TI-Basic and in Assembly, the screen is different (both in dimensions and in colors), and some addresses changed. That means that whatever magic Axe does, even when assembled into pure ASM, will crash your calc. There's also the fact that nothing on the CSE can run Axe without crashes or errors.
Oh. Ok! Time to start learning Asm then.
caleb1997 wrote:
I think that it is possible to write a program that difficult in Basic and connect it to a server. After all, it's like the moon shot in 1969- no one thought it was possible, but it was done. And this is just like that- it may be impossible to create a clone of the MTG game on a calculator, but I will surely try. And I play MTG, so I know all the rules, thank you very much. After all, someone has to try. But does anyone know anything about Axe coding? Because I don't.


Again I said "not to discourage you" but I'm just trying to help you realize some of the difficulties you will most definitely hit on the way. Having a structured plan on implementation and features not only allows you to see a clear roadmap of where you want to go and how to get there, you will also be able to feel like you're making progress. I've managed a few projects when I was still a CS major. And with a large project, something of that scale it's easy to feel like you're not making enough progress, or lose sight of what your project intended to be.

Secondly, I never meant to imply you didn't know how to play MTG, I just meant to suggest an alternative ruleset when implementing current MTG rules/mechanics. I apologize, I may have mis-communicated my intended meaning.

And last, I said it would be much too hard to make an MTG clone since your original post expressed interests in making it in BASIC. I wanted you to make the leap from instead of using BASIC to try something like ASM or even compiled C. Which it seems like you already have done so now.

TEE EL DEE ARR;
Making a roadmap can help you and us see where you're heading, so if you need our assistance it'll be easier to see your vision. I didn't mean to offend you or discourage you. I just wanted to make sure you could see for yourself how large scale this project will be.
caleb1997 wrote:
Oh. Ok! Time to start learning Asm then.

This is one thing that I have seen many say, and it is good to hear, but learning ASM is not for the faint of heart. Razz Be prepared to spend at least a couple months actually learning the language, full of compile errors and head-banging moments. To some with background in higher level languages such as C/C++, it isn't too bad, but it isn't a walk in the park. If you do decide to go the ASM route, you must be willing to commit yourself, a little bit at a time; not all at once, to try and learn its intricacies and style.

Best of luck if you think you can do it, but it won't be easy. Smile We're here to help, but the first thing you are going to want to read is this:
ASM in 28 Days
DWMelon wrote:
Although I really don't know much about MTG (or anything at all) I know many people at my school who would love to play this game.
If you have to connect to a server to play it, apart from being super slow none of your friends will be able to play it anyway. At least not at school.

As for learning Axe, download it and read the manual and commands list. I assume that's how all Axe programmers learned, along with asking questions and reading others' source code. The reason Axe doesn't work for the CSE, though, is because Axe is an assembly program (well, app) written for the 83+ series. The CSE didn't add new assembly instructions, it's still a z80 processor. However, the ports are different, the LCD is different, the OS is different (meaning bcall locations may have changed), saferam locations are different, etc. This means that assembly programs and apps written for the 84+CSE will not run without first converting them over.

If you decide to learn assembly i (and others here) will gladly help you out.
On it. Start to learn Asm right...... now!
caleb1997 wrote:
On it. Start to learn Asm right...... now!


see you... in the next 6 months? maybe? Razz
Actually, you will see me a lot, since I will be asking lots of questions. Or maybe not. Only time will tel....
I have an idea. When I place down a 4x4 pixel block, which represents a creature, is it possible to write an algorithm that can pxl-Test( each individual pixel in the 4x4 pixel block? This way, I can store card abilities on the 4x4 pixel block. For example: If the 1st pixel in the 4x4 block is off, that is interpreted as the creature as having haste. If the 2nd is off, it means it has deathtouch. 5 pixels are set aside for if the card has protection from colors. But for this to work, I will need to have a algorithm that can tell me whether a pixel is on/off. Can anyone help?
FYI: I am still writing this in BASIC until I learn Asm.
Of course it can be done. Are you asking about BASIC? Isn't there a pxlTest command? Also, writing to the LCD is pretty slow, if you are just doing that to store your data there's surely a faster way. There's a TI-BASIC forum if you have questions about TI-BASIC. There's also a "Your Projects" forum if you just want to talk about your project. If you want to know how to test a pixel in assembly, you'll probably want to use what's called the graph buffer. It's much quicker than reading from the LCD.

To find the pixel you want, you need to calculate the offset in the graph buffer. Pixels are stored 8 to a byte, and the graph buffer is 12 bytes wide (12*8=96 pixels). So assuming the top left is 0,0, for X = 20, Y = 30, you can first calculate the Y offset. To move down one row you simply add 12 bytes. So for Y = 30, you need to move down 30*12 = 360 bytes.

Next, you need to add the X. But since it's stored 8 pixels to a byte, we need to store the first three bits ("and %111" aka "and 7"will get these for you if the X value is stored in A), this is our offset within the byte. 20 AND 7 = 4. This means it is 4 pixels to the right within the byte (assuming the 1st pixel is 0 pixels to the right), that is, in this X position: %0000X000. This is essentially the same as doing % 8 (modulo 8, the remainder in the operation X/8). Next we need to divide X by 8 and throw away the remainder. Shifting 3 times to the right will take care of this for us (though depending on which shift instruction you use, you may need to clear some bits afterwards). Here, X = 20. So 20/8 = 2.blahblahblah. The blahblahblah isn't important. Now we can add 2 to the gbuf+y*12 value we obtained earlier. The 4th bit to the right (%0000X000) is the bit you want to check. If it is 1, it's on. If it is 0, it's off. Repeat that for the other pixels in the 4x4 square and you've got everything you need.

EDIT: disabled smilies
  
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 2 of 3
» 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