Game
Rogue Cadet
9 years ago

Day 51


Day 51: Today, I had trouble to wake up. Maybe it’s related to fact that I spent the night before playing Skyrim… Other than that, it was a pretty standard day. I took taks to do. Did them, did some other tasks. Realized I could actually improve stuff. Did those improvements and poof end of the day. But you want details I suppose. Well okay, but it really because it’s you. Today I:

  • Implemented seven enemies. At first I aimed for four. Then I thought six. And then at the end I had time for one more. So seven new enemies:

    • “Turret like”: stays fixed shoots three bullet in cone toward the player. Then at a longer interval it shoots two fast bullets toward the player. I realized while doing this enemy, that I don’t have any dedicated script to make the enemy look at the player. It’s directly in the TargetMovement. So I added a target movement to this enemy. But then I thought that a lot of calculation was done for nothing. So I added a check at start that start the movement routine only if speed > 0.

    • “Popcorn”: really weak just goes left/right and shoots the player from time to time. Nothing particular happened during the creation of this enemy.

    • “Melee”: goes toward the player at medium/high speed. Doesn’t shoot. I had to tweak the TargetMovement variables to have a correct collision avoidance. I shouldn’t have to tweak it. It feels like stitching decomposing zombie limbs. It kinda works but it’s not really a permanent solution.

    • “Square”: has a “square” waypoint patrol. Shoots four bullet in cross (✚). Funny thing, the enemy is named “Square” but the sprite is a circle. (you dare to call that “funny”? Man you really have low joke standards).

    • “Base”: doesn’t move. Shoots a circle of bullets. Called “Base” as in rebel base. No llama were hurt during the creation of this enemy (at least not by me).

    • “Spiral base”: Like a base but shoots in spiral. This means there’s a delay between each bullet. Also it shoots continuously.

    • “Turret”: Just a turret in the wall. It shoots forward. I used the new distance switch to activate it before you enter a room. Right now it’s destructible. But I’m not sure I’ll keep this.

  • Did some cleanup. Stuff like deleting old enemies prefab or minor script fixes.

  • Separated the enemy weapons from the player weapons. Because I was alway putting the same thing in the enemy weapons. I just put an absurd amount of max fire time (over 9000). And it used the same code than the player who has stuff like cool downs. So I separated it into two distinct scripts.

  • Modified the way enemy behaviours are switched. Before I used the “enabled” variable that allowed me to disable the Update method. But that didn’t work well. There was too many side effects. Like when a script needed a player reference. It would then disable itself, wait for the event and enable itself. But with a switch active, it woud fucked up everything. I had little control and I didn’t like it. So instead I implemented a simple Interface that forces classes that want to be switched to have a SwitchState method. Within that method I can do whatever I want. In particular I can have an internal bool that says if the script can be activated at all. It works well but the Unity inspector can’t serialize my interface type. So I have to still use a Behaviour variable and cast it to my interface. I should do a custom inspector but laziness took over. Plus, nothing like a big red error to catch my attention right?



0 comments

Loading...

Next up

Short intro of us 💕✌️

We're an eletro duo based in Seoul 🇰🇷 Heavily influenced by the 90s.

Our new album #Xennials is all about the nostalgia of that era 💽 CD listenin 📟 beeper beepin 💾 floppy disks floppin days 😎

Stream now! 🎧

https://open.spotify.com/album/3YwWhnHWVy5cA8XOpbaGRA?si=8E9awqU…

Today I was setting up the location of the first boss. His name is "Father" and he is the first of the Patagonians. His task is to guard the road to the House.🛡🗡 Bookmark pre-launch page🔖🔖🔖

https://www.kickstarter.com/projects/rdvindiegame/the-patagonian…

Shadow The Hedgehog X pixel art

Protege el conocimiento, salva la historia. Guardian of Lore es un platformer 2D en el que debes luchar para mantener viva la memoria de la mitología latinoamericana. El juego llegará a Steam el 18 de mayo: https://steam.pm/app/1211740 #ScreenshotSaturday

Werehog transformation process. #sonicunleashed

Update 2.627

New challenges & new effects!

Shuiro Haname. #Commission

Commission for @ShuHaname

Spaaaace~

These are background sprites I've created for a game I'm working on at school ^w^ Click on the post to see how the sprites connect. You won't regret it! (personally, I think it's pretty heheh)

Drawn in Piskel using my mouse. Whaddya think?

I worked so hard to get all four of them to the end safely, but then...

My D&D art for my family so far (WIP if you couldn't tell)