Tuesday, December 4, 2018

Feedback

Reflect on the evaluation that someone else did for your code. Briefly describe where you did well and where you could improve. Do you agree with their assessment? Why or why not?
One of the main things they mention I need work on is comments, which I agree with them. I agree because sometimes when I go back to back to old code I am confused on where things are and what certain code does. 

multiple variables

Have you made a mistake where you've declared too many or too few variables? What was the problem, and how did you fix it? When you begin writing a program, how do you know how many variables you'll need? 
I forgot which program it was but I had two same variables and one of the variables was writing over the second one. I fixed it by deleting the variable that was writing over the other. 

When you programmed the Princess Quiz, you needed several variables, one for each princess's score. For other programs, like the choose your own adventure program or the Marvel Universe Guesser, you only need one or two. What's the difference? What's a good rule of thumb for when you have to have a handful of variables versus when you only need one?
A good rule of thumb is named each variable with clear content. If one variable is the player then name the variable player.

Monday, December 3, 2018

flowcharts

1) What are flowcharts and how are they useful?
Flow charts are like an outline to a story or an event. It can help be useful by being more organized.
2) What coding tools/concepts will you need to complete this project?

I need to use the shapes key to correctly demonstrate an event or a story. 

Thursday, November 29, 2018

File Input and File Output

Compare and contrast File Input and File Output. How are they similar? How are they different. What does the code look like for both? What do they do that's different?

They are similar by they both are both files in the program file folder and they also have the same library. The difference between them is, they have different declarations variables. and the main difference is one is an input and the other is an output. So without the input, you can't get the output. One big difference in the code is they are spelled. The input variable is spelled Ifstream and the output variable is spelled ofstream. 

Famous artwork descirption

Start off with a 4 x 3 grid. in each grid, the background color is a different color. It's either red, blue, or yellow. In each square draw a circle with a smaller circle inside it. Every time you draw a circle us a different color. keep doing that until each square in the grid is filled with circles. 

Minimum wage work ethic

Take a look at the quote below. Do you agree or disagree with it? What level has your work ethic been at this semester? What are you strengths and where could you potentially improve when it comes to this area of your life?

Displaying ac04653ca046961d52f327ef64f6204c.jpg
I agree with it to a certain point because I know what they are trying to say and yea chase your dreams. The part where I disagree is I work in a minimum paying job because I am still in school. Even though I work at a minimum paying job I treat it very serious because it is still is a job and I am trying my best and working hard. Just because it is a minimum wage doesn't mean my work ethic has to be very poor as society has stereotyped it to be.

Monday, November 26, 2018

Card Game (Mathew. David. Isaiah)

Write a pitch for the game you and your team is developing. See slideshow linked below for example. 

Card Warriors is the hot new card game that everyone is playing! This game features new classes facing off in a head to head battle! Start with twenty cards and widdle down your opponents army.
There are five unique classes in our game, that can make your 1v1 intense. Starting off with Spy, this card allows you to see your opponents next cards. Then there is the tank, has high health and attacks every other turn. The Rogue deals high damage for that game changing play but has low health. The Medic heals other cards or can heal itself. Defense comes in and counters any attack. We know you will love this hit new card game, brought to you by the great minds at cec.

Saturday, November 3, 2018

different languages

Name 3 other programming languages besides C/C++. How are they different, and how are they similar? What are they primarily used for (learning? web design? if games, which ones?). Which would you be most interested in learning and why?
I know javascript, bash, and ruby. I don't know how they are similar, just knowing that they are used to programming programs for people to use. They are different because of how they are written. Javascript is used for editing a website's code and functions. Bash is used for the computers operating system. Ruby is used for developers frequently perform tasks like storing information in a database, and a Ruby framework called Rails speeds up development by including pre-built code, templates, and easy ways to perform these tasks.
I would like to learn more about bash because its primary purpose is the computer operating system and I would like to venture into that field. 

Bubble Sort

What is a bubble sort? In 3-5 sentences, write out its pseudocode. Bubble sort is generally seen as one of the slowest (and not very smart) ways to sort numbers. Why does it take so long? What does it have to do to sort all its numbers?
Bubble sort is an algorithm where it takes a set of numbers and puts them in order from smallest to largest.  Create a for loop that takes the users input of a random set of numbers. Create another for loop that goes through the numbers and puts them in order. Create some variables to help you put in the numbers in the variables and a variable that is a holder. Use these variables to put the numbers in order. It is very slow and not as effective as other programs because it has to run through the whole set of numbers over and over, beginning to end so it can sort it out. 

I/O files

Compare and contrast file I/O and console I/O. How are they similar? How are they different? What happens with file I/O? What steps do you follow to read and to write to a file?
From what I remember we used this to create save states for out games. So we would just type the code for the save states and once you run the code, it creates a text file for the save state. We also did loading in the save state so we would ask the user if they want to load in the save state and if they did say yes, we will load it in. kinda forgot about this moe sorry, this is the best I can give. plus it's 12 pm so I'm hella tired

problem solving


Today's problem was HARD. 
What emotions did you feel while struggling with this problem? How did you feel when you completed it? What problem solving techniques did you use? If you helped others, how did you guide them without giving them the answers? What other areas of your life (job, relationships, other classes, etc) give you tough problems, and how are they similar and different?
I just felt determined to figure out how to solve the problem and when I completed it I felt relieved. My technique was I asked other students to see if I can learn any new knowledge and solve the problem I had in the code. When I am having trouble in my college class it is usually behind on homework and instead of video games after school, I cram homework. 

computer programs in my daily life

Describe a few computer programs you and your family members run into a daily basis- anything from the gas pump or checkout counter at Safeway to specialized software your parents use at their jobs. Are there any that you're curious about? Which would you like to take apart and recreate?
I usually play video games every day and I want to see the code for most of the games I play and possibly recreate them with basic functions. The only software I can think my dad uses is his badge he uses to unlock doors. I would like to know how that software works and possibly try to work on it.

for loops and arrays

Explain why for loops and arrays work so well together. What tasks can for loops complete on arrays? Provide a code example of a for loop being used with an array and explain how it works.
For loops go well together because it can make putting inputs into the array easier. If you need to put multiple numbers in an array at once a for loop can be really useful. for example here is the code for that function. 
for(int i = 0; i<10; i++)
cin>>array[i];
This reads the users input and puts it in the array. 

Local and global variables

Compare and Contrast Local and Global variables. Where are they declared? Who can see and use them? Which ones are generally easier to use and why? Why wouldn't you want to make all your variables global?
Local and global variabal but are used for different things. The difference is where they are declared. Local variables go under main and only the code under main can use them. Global goes above main and all the variables can use it. I would say global variables are easier to use. 

Learning Reflection


Although we still have a few more concepts Dr. Mo would like to cover, at this point we've *officially* covered all the concepts on ACC's intro programming course syllabus. 

Using the wall standards as a reference, tell me which concepts you're the most confused about, and which you're feeling confident about. Be as descriptive as possible, naming specific examples if possible. Are there any concepts I should altogether reteach, or at least provide a second mini-lesson? Are there any you'd like to see me do a youtube video example of? What sort of daily codes would you like to see me assign to help reinforce these concepts? Any other teaching/learning suggestions?
I am comfortable with functions,  loops, basics of Allegro, math problems. I need to review parent classes more because I am still a bit lost about that. I want to learn in depth how the collision works, and lastly, I want to review classes in general.

Array


Describe what arrays are and what they can be used for. Explain why we would ever use arrays and not just make multiple variables. 

Show and explain how to declare an 8-slot char array filled with the letters of the word "Colorado".
The array is a variable that stores things depending on the return type. Using an array makes it easier than using multiple variables. 
char state [8] = {c,o,l,o,r,a,d,o};

Wednesday, October 31, 2018

feedback

What concepts are you most comfortable with, and what concepts need more review? Try to be really specific and include 3-4 concepts in each category.
I am comfortable with functions,  loops, basics of Allegro, math problems. I need to review parent classes more because I am still a bit lost about that. I want to learn in depth how the collision works, and lastly, I want to review classes in general.

Chaos Monkey

What is defensive programming? What are some steps you can take to make your program difficult to break? What are some steps you might try when testing other's code?


You have to be very clear in your coding and if the code is advanced code you will have to put understandable comments so whoever reads the code will not break the code and can go through the code with ease. I will add random numbers to see how it will effect the program. 

My Game

In a short paragraph, explain the mechanics of the game you're designing for your final project. What will be the winning and losing conditions? What are the goals of the game? How will it be challenging. Finally, and most importantly, explain how you will be using functions to implement these goals and challenges? 
The main mechanic would be the gravity function and the collision function.The player can make the square jump up and it will fall back down, the player will lose when the square hits any of the triangles.Hitting the triangles and starting over is the collision function. Once the player loses he will start at the beginning of the map and will have to start all over. The goal for my game will be see how long you will last. It will be challenging because of the short hop of the square and the reaction time of the player. I have 2 functions in my code, gravity and collision. You need gravity to get past the triangles or you will die and will have to start over.

Wednesday, October 17, 2018

Games and the world

Think about yesterday's article, "Defending nature: Real-life video game may help protect desert tortoises". What are other ideas you have for games that can have positive environmental or social impacts? What would they do, and how would they work? Do you think video games will become an important part of solving large problems for humanity in the future? Why or why not?
One idea that would be cool for a game where the player would clean up the ocean with a drone and can earn points on how much trash they collect. I think it would become important because it would be helpful to the earth but also it would add a fun factor to the objective. We only have one earth, there might be planets that are similar to earth but never the same. We need to take care of the planet so humanity can survive.

Random generator

Describe how random generation works in our games. What does the rand() function do, and how can you alter the range of the numbers it produces? Provide several examples explaining different ranges of numbers.
The rand is randomly generating numbers and you can add a restriction by adding the % and a number, that will set the range of the preferred numbers. For example rand()%100+1 is a random number between 0 and 100. 

Getting stuck on daily code

Explain where you got stuck and/or confused on today's code. If it was a bug, what was the problem, and what was the solution? If you got confused about a concept, what was it, and what was the clarification?
We got stuck on the how to actually have the for loop find out the biggest number in the sequence. Ferny helped us figure it out. He made an extra variable that exist as a holder for the numbers and if the number is bigger then the holder it will replace the holder. When it ends, the biggest number will print out to the screen.

Unix Commands

Spend 3-5 sentences describing the programs and commands you know how to use in your Unix shell (besides games). What is pico and what does it do? What is g++ and why do we need it? What about "./a.out"? Look up one other command or program and describe what it does.
pico opens a document to type your code. g++ to my understanding checks if you have any bugs in your code, and the ./a.out run the recent code. One extra command that is on unix is "pine" which is the email command where you can send emails and view them. 

UNIX VS. VISUAL STUDIOS

Compare and contrast coding in UNIX versus coding in Windows using Visual Studio. What steps do you take for each? How are they different? How are they the same?
Unix and Visual studios are used for coding but they are different in theirs own ways. Visual Studios is a more responsive compiler where you can see your errors in real time and UNIX you have to save the code then run it and then you see if you have any bugs. Another thing that makes them way different from each other is the helper libraries. Unix is limited on what libraries you can use and that means you might have to switch up your coding. With visual studios there is a more variety in the libraries you can use and is seen as an easier way to code because you can see the errors in real time.

Friday, October 12, 2018

compare and contrast return types and parameters

In 3-4 complete sentences, compare and contrast return types and parameters. What are each used for? How many can you have of each? Provide code examples to explain what each does.
 Return types depend on different types of code because you need some certain return types for some code to work. void returns nothing, bool is used for codes that require a yes or no answer, int is a number with no decimal, double is for numbers with a decimal, string is for for whole word answer and finally char is for one letter inputs. The parameter just like the return type depends on the type of code you are writing. It might contain on of those variable types and it could take multiple parameters.

Friday, October 5, 2018

Feedback

Tell me something that is going well in the class, something that I can improve on as a teacher, and then again something that is going well.
I am loving the warm ups and are good review topics. One thing that I wished you did is after the warm up you give us time for our projects we are working on. I want to work on our projects to get them done on time.

Thursday, October 4, 2018

Unix

Spend 3-5 sentences describing the programs and commands you know how to use in your Unix shell (besides games). What is pico and what does it do? What is g++ and why do we need it? What about "./a.out"? Look up one other command or program and describe what it does.

Unix shell is important because it is the industry standard and a lot of companies are using it. I know how write code, save it and then compile it. To write it you need to type pico into the console window then hit enter. You write all the code you need, then to save it you need hit ctrl+o, name it then hit enter. Then you exit it by hitting ctrl+x. That is how you write the code. to run and compile the code you need to press, g++ and the name of your code, then type ./a.out to run the last doc file. If you wrote your code with no bugs it will run successfully. 

function

 Tell me about writing functions. What are the three steps, and what do they mean? Where do they go? What do they look like? 

The 3 steps for a function is definition, call, and declaration. The declaration goes above main, the call goes inside main, and the definition goes after the end of main. The declaration would look like this: return type name(parameters); The definition is going to look similar, just instead of the semi colon it is going to have curly brackets. The call is going to have more things taken away, for example: name(parameters);. 

Monday, September 24, 2018

What are functions and why are they important in programming?
A function is group of code that has a certain task that performs a certain task. There are starting functions, return functions, and one that contains a lot statement that defines the function itself. It is important because functions are in most coding project it might be small but it is there.

Wednesday, September 5, 2018

Binary

 Explain what binary, octal, and hexadecimal numbers are, and why they're important to computer science.
Binary are number with just 1's and 0's, octal are numbers from 1-7, hexadecimals are numbers with numbers from 0-9 the a-f. All these binary are used to communicate from user to the computer, so its important so the computer can respond to the user efficiently. 

Thursday, August 30, 2018

Loops

 Compare and contrast the different loops (for, while, do-while) we use in class.
Loops are very good for making games and other programs you need to run more than once. Lets start off with a for loop, a for loop is a loop where you know how many times you know its going to run. If you need it to run 5 times then you can use a for loop. Now a while loop can run infinite. If you need something that needs to run for a long amount of time, for example a game like pacman. It checks at the top of the code/ loop then it loops. A do-while is the same as a while loop but instead of checking to loop at the top it will check at the bottom of your code.

Wednesday, August 29, 2018

Random function

 How do generate random numbers in C++? Provide 2-3 examples and explain what numbers they generate.
Generating random numbers can be used in multiple ways. You are going to have to type the random function in the perimeter you want, the code you have to type is, rand(). and you can restrict the randomness by adding a module and a number to go with the module, it will look like this rand() %700. One example is you can draw a rectangle and put the rand number function in the color parameters and get random colors for the shape each time you run the code or every time the code loops. Another example is putting the rand function in the shapes position and size parameter. Each time you run the code or the code loops, you'll have a random rectangle with a random size and position.

Tuesday, August 28, 2018

Functions-

In your own words, describe what the following functions do: al_flip_display(), al_init(), al_clear_to_color().
To start off, al_init() is important because it initializes the library so you can access all the code in it. The clear to color function is helpful when you are running a loop, where you are moving an drawing on the scree. It is used hear because the purpose of this function is to clear off the objects previous location on the screen, if you do not put this function on the screen it is going to look like its leaving a trail of that object and will cover the screen with clones of itself. Now the flip display function allows objects the computer to draw to the screen. Anything you draw will show up on the screen and if you do not not have this line of code your screen will be blank.

Monday, August 27, 2018

Game Projects

What individual game projects would you like to work on this semester?

I would like to work on Tetris with other 3 semesters and try to give each other ideas.

Monday, April 30, 2018

Adding modulo on the random function

in Rock, Paper, Scissors earlier this week, some students generated random numbers like this: rand()%3, and others did this: rand()%100+1

How are they different? Which way do you think is better and why?
Those percentages are called modulo and they set a limit on the random generator. For example the 100+1 is to find a random number from 1-100. There isn't a better or worse on because it all depends on the certain project.

Wednesday, April 11, 2018

Allegro Keyboard input

When I did my keyboard input I had to make one square move with the arrows and I had that working and when I chose the second players key binds. I chose the WASD keys. I made second player move the second bitmap with the WASD keys.

Allegro sounds

The sounds I have used with allegro  is my pong game is when my ball hits the paddle it makes
a roblox death sound and I also have back ground music when you play the game.

Friday, April 6, 2018

Allegro primitives

Create a blog post (3-5 complete sentences) where you describe what primitives are, and the steps you need to use them in your games.

Primitives are shapes you can draw in allegro. You need to add the primitives library and add on and of course the code to draw the shape. There are a lot of shapes you can draw with this library.

Allegro images

In your blog, use 3-5 sentences to describe the steps needed to show images in your game window.

First you need to download the images you want in your file, make sure you put it in the right folder. Then after that, add the image library, you need to turn on the image add on. Then type in the code code you have gotten from allegro tutorial.

Allegro Fonts

In your blog, describe the steps you used to write words of different font types in your game window.


  1. download your fonts
  2. put both fonts file in the program file 
  3. set up the font allegro code(create a game window, type in the add ons, al_load, render section, clear to color, al_draws, flip display, al_rest, and al_destroy_display.
  4. type ALLEGRO_FONT *font = al_load_ttf_font("font.ttf", 20, 0); two times.

Wednesday, April 4, 2018

allegro game window

In your blog, explain what Allegro is, and how you can use it to set up a game window.

Allegro is a library and you can use it with its unique language to great game windows for your own game. You use the game window for the games visuals.

Tuesday, February 13, 2018

How to create allegro game window

In your blog, describe the steps needed to create an Allegro game window in 3-5 COMPLETE sentences.

I first opened a file and set up the basic code, including setting up the allegro library and the al_init. Before I do all of this I have to download allegro, and to do that you right click on the project name and click on manage NuGet Packages, then download allegro. After it is finished downloading type ALLEGRO_DISPLAY *gameWindow = NULL;, that is the variable you need to set up for the window. Then you type ALLEGRO_DISPLAY *display = al_create_display(500, 500); to acutally create your game window and if you want to add al_set_window_position(gameWindow, 200, 200); to set the position og the game window on the screen. If you want to add  a title to the screen you just add this code al_set_window_title(gameWindow, ""); You also have to add these at the end
        al_flip_display();  :write whatever is in memory to the screen
al_rest(100.0);       :pauses game
al_destroy_display(gameWindow);     :clear memory