top of page

Enemies (mostly the computer key enemy)

Writer's picture: Dabrina♡Dabrina♡

Hi! This blog is about the enemies that can be seen throughout Reality Runner.

I have 5 worlds with 5 types of enemies described in one of my first-ever posts, but I'll give another brief outline of the enemies.


W1: Robot enemies, shoots laser

W2: Mushroom enemies, shoots mushroom that slows down the player

W3: Music note enemies that chase the player while playing music and if the player does not leave that range they die.

W4: Computer key enemies that shoot cursors at the player that freezes the player in place

W5: Blackhole enemies that draw in the player and slows their movement.


Currently 4/5 enemies have been coded and are ready for implementation into their levels.

Ok, technically all 5 have been coded, but the computer key enemy is giving some trouble.


Today, I was focusing on getting its functionality done, but for some reason the player movement is not resetting after the WaitForSeconds function has passed.


I have tried two approaches so far:


This approach accesses the PlayerController script and disables it completely, then should re-enable it after 10 seconds (set to 1 for debugging purposes). However, this code for some reason is not working. I realised that destroying the game object could cause some issues so I later made a resetplayer() function which handled everything after the coroutine has run and also added a boolean to check if there is a collision with the cursor or not, however the results remained the same.




This approach involves accessing the player's Rigidbody and its constraints. Before the WaitForSecond() function the all of the rigdbody's constraints were frozen, which basically freezes the player and of course after that the constraints were set to none, which should reset the player's movement. Again, there was no change.



At this point I have no idea what is going on so I'm going to try rewrite the scripts and see if I maybe left anything out.



That's all I've got for now. Thanks for reading,

Dabrina


1 view0 comments

Recent Posts

See All

留言


bottom of page