Day 58

Today I worked on a sprite for my attack animation. I finished it but I still don't think it looks that good.

This is my hard work XD

I can't do better than that for an attack animation. 
I actually spent almost the entire class trying to make it to the best of my ability.

At the beginning of the class I watched some tutorial videos on how to make a proper functioning attack with hitbox. 


Tomorrow I will try to implement attacking into the game.

Day 57

Today I fixed my problem.

I was right last class, the problem was because I didn't center my sprite in my game.

Now it looks good.

The rest of the class I was looking at some tutorials of how to fix some bugs such as: the enemy idle path being the same every time I play the game. So to fix this I had to put randomize(); at the beginning of the code. It's that easy to fix and make everything random :).


Tomorrow I will try to add an attack to the game.

Day 56

Today I found some sprites for my goblin.

I went on opengameart and found some good sprites for my goblin.

I started implementing them into my game. But there is a problem, whenever my sprite flips, it flips completely.

Looking at it now it's probably because I didn't center the goblin sprite.

Tomorrow I will work on more AI mechanics and try to fix the flip.

Day 55

Today I had a lot of fun.

I made a new enemy with no specific sprite yet but I want him to be a goblin. So I started working on the enemy AI. I made these things called "states" which tell at what state the enemy is currently in. I currently have 3 states: static, follow, and attack. Static state is the state where he just walks around randomly and doing nothing else. Follow state is the state where when the player get close enough and the enemy can see him, the enemy then starts to follow the player. If the enemy gets near enough to the player, he changes to his attack state where he starts attacking the player and doing damage.

Oh I forgot to mention i made a health-bar :) I made it by making the red part get shorter the lower my hp is. 

Tomorrow I will work on something else I haven't quite figured out yet.

Day 53

Today Mr. Bilesky suggested that I keep working on my old game to "polish" it up because there is not much time left to start a new game. So i started to work on polishing up my game by adding things like scores etc. I started by removing Resets from the game and adding 1 to deaths every time I reset the game. Then I replaced resets with score. I gave each piece of item in the game a certain score that it adds.

Jump = 100
Walljump = 250
Speed = 500
Jump = 500
Killing Enemy = 1000

Then I made it so that the higher combo I have the more score I get per action by multiplying the score by combo. ex. If I kill an enemy add (1000) * (global.combo) so if the combo is 5 it would add 5000 to my score.

Then I thought "would it broken if the player could just keep resetting the room and the score doesn't change" so I wanted to fix that. I made a controller object and gave it a variable called "previousscore" and made it so that when I go to the next level that previousscore = score so that it saves the score at the beginning of the level. Then I made it when room start that the score would go back to previousscore when the room started.

So when someone resets it goes back to the score it was when the room started.

Tomorrow I will work on "polishing" up more things.

Day 52

Today I worked on my new game. I added a few new things such as a smooth camera movement. I took this code from one of Shaun Spalding's game called "life is short". I didn't want to code it myself and he made the code free to use. I understand how his code works, the movement slows down the closer it gets to the cursor.
As you can see, I also added a mini sprite to the game the I found online. I haven't fully got him to work yet by changing his direction etc.

Tomorrow I will work on my sprite and movement to make sure it works properly.

Day 51

Today Mr. Bilesky showed me to Ty. I showed him my game and what it can do. He taught me some new things to do. He told me how to change my game to make it a bit easier by changing the amount of time it jumps off, so you have a faster reaction time at wall jumps. He then showed me around on his game and what he did with his game. His game looks cool, it has good graphics that he made himself. His game is a 2D platformer. He hadn't done much story wise, he just has a hub where he tests out everything.

Tomorrow I will work on my new game and get some things set up.

Day 50

Today I looked around to try and maybe start a new engine.
I looked at engines like unity and unreal.
Unity has a lot of cool games with it such as games like: Rust (a PvP survival game) Assassins creed Identity etc.

After that I said I wasn't gonna start a new engine because I still haven't done anything "amazing" with game maker and there is so much more i can do.

So i started planning for a new game. My classmates: Quinn and Zack helped me plan.

Here is what I have so far:

New Game Ideas

Top Down Medieval Game

Enemies:
Goblins
Orcs
Dragon

Wild Animals:
Sheep (Wool for crafting)
Cows (Food when killed)
Horse (ridable when tamed)
Wolf (tamable) (hostile when not tamed)
Dire Wolves (only appear during winter, hostile)
Chickens (eggs)
Bears (hostile, untamable)

Seasons:
Spring
Summer
Fall
Winter

I think once this game is done it will look good. This game will take a long time to make but it will be worth the time to make.

I will do more planning tomorrow and maybe start a bit if I finished all ideas.

Day 49

Today I finally finished my game.

I checked to see on Reddit but no one responded so I had an idea to just make the font lower and the space between the levels smaller so i could fit all the levels in, and this is what i got.

Then I just worked on some minor changes like sound combo bugs etc.

Then i added a new piece of text to the final level.
:)

Tomorrow I might start a new engine to work on.

Day 48

Today I pretty much finished my game.

At the beginning of class i did something i probably should've done a while ago. I made the obj_player draw all of the combos, resets, and deaths, instead of the certain objects to draw it. That way the texts only appear when my obj_player is in the room and never anywhere else (for example main menu which was there for a while but i was just too lazy to get rid of). Then I worked a bit on the last level of the game. I added a text saying "The End" and a text underneath saying "Press 'R' to restart" and I made that true.
I still couldn't figure out how to make scrolling text for the level select menu so I asked around on reddit.

 https://www.reddit.com/r/gamemaker/comments/4jmfa1/how_do_i_make_scrolling_text_in_a_menu/
I still haven't got an answer and its the end of class.

Tomorrow if I get an answer I will try to put that in my game.

Day 47

Today I finished my last level. I finished the last part of my level today. I added a high jump after the last part from yesterday and the enemy.
After that i started looking online for how to make scrolling text and i found this.

I wanted to implement it into my level select screen and I couldn't figure out how.

Tomorrow I will implement scrolling into my level select menu so I can fit more levels.

Day 46

Today I worked on a new powerup and a new level.

I started off on the level by working on a new jump power. It works the same as the speed powerup but instead it inscreases the jump speed from 7 to 10. I made the sprite for the powerup to mario jumping.
Then i tried many things to test the level but its very hard because of the new jump powerup. So i only got halfway done today.
This is the new level

Tomorrow I will work on finishing the level and continuing the next part that leads to the end.

Day 45

Today I worked on the mute button.
I finally got a response on Reddit and someone told me to check out all the audio commands in Game Maker so I did. And apparently there is a command called audio_master_gain(); which you can set the gain for ALL the sounds (master). So i put that into my game code to set the master gain to 0 when i press the mute button, and it worked! Then I wanted to put the code inside the step event so I could have it so that when you press "M"  OR you press the left mouse button it would mute/unmute. So I made a variable called mouse_left and set its value to mouse_check_button_released(mb_left); and then I made a variable called key_m and set its value to keyboard_check_pressed(ord("M")); Then I added an "if" statement and said that if key_m or mouse_left return true then execute audio_master_gain(); and change the sprite to the muted sprite.

Tomorrow I might start finishing up my game by adding a new last level, working on sprites, and an end screen.

Day 44

Today I worked on a new pause menu. I made the pause menu interactive so that you can exit to main menu and restart and continue the level.

The code was almost the exact same as the main menu and level select menus I only had to add a new variable called "pause" where the code would only activate if i press pause. And then I made a new script called scr_pause where I added the cases for the arrays that will activate. 

In the last bit of class I tried to find out how to add arrays but I still couldn't figure out how. So i asked around on reddit to see if anyone had the answer for my question, but i haven't gotten a response yet.

Tomorrow I will see if anyone responds on reddit.

Day 43

Today was a shortened block and I couldn't do as much work today. Today I wanted to add multiple values to one variable but I couldn't figure out how to. So i googled it and I found something called an array. An array is a way that you can add multiple values to one variable. The syntax kinda looks like this

array[2] = 0;
array[1] = 0;
array[0] = 0;


This is defining the array variable with a certain number or value. You can then pull out that certain value of that number like this.

Switch(array){

case 1
 {
//code here
 }
}

case 1 pull out the value from array[1] case 2 pulls out array[2] etc. if you know what i mean.
I used this for the tutorial:
http://docs.yoyogames.com/source/dadiospice/002_reference/001_gml%20language%20overview/401_06_arrays.html

I wanted to add all my sounds into one variable called audio. So that when I press the mute button i can use audio_sound_gain(audio,0,0) so that the volume goes to 0.

Tomorrow I will find a way to work with arrays in my game and mute the sound.

Day 42

Today I worked on a lot of stuff. I started off the day by working on a new level.


I didn't have time to add it to the level select menu but it's fun :). It took a lot of time to test the level closely to make it work. I got my friends to test it out for me too. After that i tried to work on a new thing that mutes the game like a little speaker at the bottom of the game.

I tried doing many things but the game would just keep crashing every time i tried it. I think I know whats wrong and I will try to fix it next day.

I also worked on new slopes that i added to my level.


This week I learned a lot of things. I learned how to make the sound play only once when the variable equals that ammount I also learned how to add new slope sizes into the game, i learned how to add a new speed powerup. This week was fun.

Next day I will work on fixing the audio mute and some other problems.

Day 41

Today I worked on a new power up that adds speed whenever i pick it up. My movement speed goes from 0.3 to 0.5. I made the sprite of the powerup Sonic because, you know, Sonic is fast....
I did a lot of coding to make this work. I added a new variable called speed_powerup and made it so that when i pick it up my movement speed increases to 0.5 and plays a distorted version of the sonic theme until I die, reset or go to the next level.

I tried to change the player sprite too to sonic once i pick it up but I couldn't figure it out.

Tomorrow I will work on a new level.

Day 40

Today I did some cool things. I changed the sprite for the current red block enemy and set image_speed to 0.3

I think it looks very cool imo compared to the normal red block because they share the same things (only way to kill is to jump on them). After this I added more sound effects to the game. I counted a total of 6 possible combos on the last level so I had to make sound effects for combos:4, 5, and 6. 

This game become an MLG parody of my original game. Quinn suggested I should make the game "MLG" and add all these "weed" sound effects for the laughs lol. (The humor of this generation is very weird and strange so don't be confused)

Then Zack suggested I should add another goomba to that part of Level seven so I could have a total of 7 combos. And then I added another sound effect for the 7th combo. 

Tomorrow I will add a new powerup to the game.

Day 39

I got a reply on my Reddit post about on how to do the code that I've been trying to fix for the past 2 days. And the code that he sent me worked. I just need to edit it so that it works for all my powerups.

OK so I made some changes to the code and added it to the rest of my objects (powerups, and enemies) and it works. 

I made a controller object to which i assigned all the code to try to make it consistent throughout all levels but it still wouldn't work.

Then I made a draw event in the controller object and made it so that it writes Combo: (combo amount) so it is easier to tell how much you have.
Class is coming to an end, and today I learned how to make a sound play only once when you have that amount in a variable thanks to the person who helped me out on Reddit.

Tomorrow I will be working on something new. I might change the sprite for the enemy and maybe make it a goomba (lol).