Progress Report X-8D Re: Programming Project 1

Edit: Due to the last programming section mistakenly being empty, some minor changes are made and some programming aspects will be re-explained again.

The programming section of the first project, Bellowing Protector is geared towards making simple changes to the script based on the tutorials given and adapt it based on the code design. The reasons why I chose to program it the way it is and how I come to the conclusion of that design.

The basic movement is used by using OnMouseDown. This allows me to click on the object and allow me to move them. And then, use screenpoint on a cameraworld base, I created a limiter which allows the movement to be restricted by only the camera’s position.


The OnMouseDrag is a basic drag movement which allows me to move the object as intended to. The reasons why I decided is more on the technical side, rather that it is a simple script which doesn’t require extensive scriptiing knowledge. With the limitations that I have, I used a simple drag function so that I would be able to move the character with limitations and make the movement restricted to the cameras, for simple design purposes.

This takes several attempts because I tested it an amount of times and found an error regarding the Vector3 position, which is eventually fixed by changing the basic offset values.


The Shooting Script is simple as well. A basic generated prefab which shows up when object is clicked. A simple OnMouseDown and Destroy function. The reason being is to make an object which allows it to collide with the enemy and destroy it. The method for doing it is a simple base as follows:

Check if the enemy hits, if the enemy is hit by the prefab that was generated by the object the object will be destroyed. This script does not work because of a prefab that I had was missing and I did not attach it properly to the layers I need.


I fixed this problem by testing, reiterating and making changes to the variables of the script for the enemy and the object, so that it would match the variable damage and conditions that would allow the object to be destroyed. The destroy 10 second on the image above gives the object a time limit which restricts infinite gameobject to be generated and prevent the game to be slowed down. The same goes when the object is being destroyed, colliding with the enemy.

This is the basic justification and make iteration testing and code quality for project 1. I will describe a more detailed version of code quality and testing for project 3 on a more detailed progress report down the line.



Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s