Jump to content


Check out our Community Blogs

Register and join over 40,000 other developers!


Recent Status Updates

View All Updates

Photo
- - - - -

A Dice Roller Linked With An Image Generator

generator image images mac osx os x

This topic has been archived. This means that you cannot reply to this topic.
4 replies to this topic

#1 TylerLinden

TylerLinden

    CC Lurker

  • New Member
  • Pip
  • 3 posts

Posted 09 November 2013 - 11:25 PM

To start, I'd like to say that I have no programming experience or knowledge (except for an extremely small amount of Java). I'm posting because I really don't know how or where to start this. I'll try to explain everything in as much detail as I can. Another note, I'm wanting to make this an application for Mac OSX Mavericks. What language should I use? What Program should I use? Are there any visual editors (like Visual Basic) for Mac.

 

Here's the idea:

This program simulates a card game. There are 73 cards, each with a regular effect and a chaos effect. Each turn the player may roll a die. If they roll a blank side nothing changes. If they roll the chaos side the chaos affect is activated but the card doesn't change. If they player rolls the cycle side, the card is shuffled back with the 73 other cards and another one is chosen. Rinse and repeat.

 

 

Here's what the program does:

I'm wanting to make something that randomly displays 1 of 73 images (JPGs). There will be a button that says "roll." The roll will simulate a 6 sided die, randomly generating a number between 1 and 6, but instead of displaying the number it display some text that would disappear when clicking anywhere besides the "roll" button. Numbers 1-4 would display "Blank," 5 would display "Chaos," and 6 would randomly generate another 1 of the 73 images to replace the current one.

 

Any advice, code, or anything like that would be really helpful.

 

Thanks in advance,

Tyler


Edited by TylerLinden, 09 November 2013 - 11:42 PM.


#2 gregwarner

gregwarner

    Obi Wan of Programming

  • Expert Member
  • PipPipPipPipPipPipPip
  • 1586 posts

Posted 13 November 2013 - 08:59 AM

Java would be a nice choice in that it runs on all platforms, although it will rely on your users having the Java Virtual Machine installed. There are several IDE's (Integrated Development Environment) available for Java, and most have some form of visual editor built in. Netbeans and Eclipse are two that come to mind. For Mac, Apple's own XCode product is very good. I believe the choice of languages are C, C++, and Objective-C, although I don't do Mac development anymore so I couldn't tell you if anything's changed during the last 5 years. Of course there is a visual editor included in XCode as well.

 

Until a language and/or platform is selected, it would make little sense to talk about how to do the specifics of your program, as everything will be done a little differently in each language. Have a look at those choices listed above and decide what you're most comfortable with. I can say, however, as you mentioned you have very little programming experience, your project you mentioned above might be a big step. It would certainly be worth your time doing some incremental programming projects to learn the skills you'll need and build up to your goal.


ti-99-sig.png
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.
– Douglas Hofstadter, Gödel, Escher, Bach: An Eternal Golden Braid


#3 TylerLinden

TylerLinden

    CC Lurker

  • New Member
  • Pip
  • 3 posts

Posted 13 November 2013 - 11:16 AM

Java would be a nice choice in that it runs on all platforms, although it will rely on your users having the Java Virtual Machine installed. There are several IDE's (Integrated Development Environment) available for Java, and most have some form of visual editor built in. Netbeans and Eclipse are two that come to mind. For Mac, Apple's own XCode product is very good. I believe the choice of languages are C, C++, and Objective-C, although I don't do Mac development anymore so I couldn't tell you if anything's changed during the last 5 years. Of course there is a visual editor included in XCode as well.

 

Until a language and/or platform is selected, it would make little sense to talk about how to do the specifics of your program, as everything will be done a little differently in each language. Have a look at those choices listed above and decide what you're most comfortable with. I can say, however, as you mentioned you have very little programming experience, your project you mentioned above might be a big step. It would certainly be worth your time doing some incremental programming projects to learn the skills you'll need and build up to your goal.

Thanks, I did a little Googling, and I think I'm going to try and start learning Java.



#4 TylerLinden

TylerLinden

    CC Lurker

  • New Member
  • Pip
  • 3 posts

Posted 13 November 2013 - 02:38 PM

I've decided to go with coding this in Java. If anyone has any tips on where to learn java or some example code from programs that do similar things, please post them!



#5 BlackRabbit

BlackRabbit

    CodeCall Legend

  • Expert Member
  • PipPipPipPipPipPipPipPip
  • 3871 posts

Posted 13 November 2013 - 07:52 PM

About JAVA, this is our Beginning with java tutorial (you could find more browsing the java tutorials section)

 

Later you can check for this program example which is close to your needs.






Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download