Space shooter

  • I have completed the galaxy shooter game in the course and was wondering if moving the game to android would be the same way as you would to other devices. And if so would the code work as it is or would changes need to be made to it? As i am new to programming i am not sure how this would work?

  • There is several ways to it. Either learn how the movetowards works with mousepointer, or implement input overlays (where you see a 'knob' control on one side and a firebutton on the other for instance. It isn't easy, but doable, but I suggest you finish the whole course first. (Ryan, I still hear you say that to me some months ago :D)

    Everyday a little more a little better. Always adapting, always improving.

  • Hi guys, Could anybody can help, understand what is the difference between a gameobject and a transform component. What is the difference in their variables. Why there is a gameobject starting with small case letter and a Capital letter Gameobject like this one???????

  • Hi guys, Could anybody can help, understand what is the difference between a gameobject and a transform component. What is the difference in their variables. Why there is a gameobject starting with small case letter and a Capital letter Gameobject like this one???????

    None. A game object is the parent class of the transform class. THe transform determines the position, and further relation to the world the gameobject lives in. The gameobject can have several adjecendant classes, like audiosource (which is a component, but inside it is just another class), spriterenderer, shader, etc.


    The 'gameobject' refers to the object that is represented in the game. The transform is the object that is representing a part of the gameobject related to only a part of its behavior. That is why a default GameObject is derived from MonoBehavior (or NetworkBehavior), which gives it all the default functionality (like the Transform part).

    Everyday a little more a little better. Always adapting, always improving.

  • okay but still I have confusion between gameobjects and transform, specially on those camel casing and the variables between these two.

    Camel casing?


    A transform is a part of an object (a component). The game object is the base class of an object you identify in your game.


    I am guessing translation is causing problems here, but that is simply it.


    A cube in your Unity game, is a gameobject. The transform is the 'positioning' component: Where is it on the X/Y/Z axis (in world or in local space). How big is it? On which axis is it rotated?


    If this isn't clear to you yet, please just follow the course. Redo the course when you are done and you will see that things are clear.

    Everyday a little more a little better. Always adapting, always improving.

  • Just I'm still not clear not world space and local space?

    That will become more clear in 3D projects. Basically, world space is all you can see in the Unity editor and if you have an object positioned there, you talk about 'worldspace'. But when you have a 'collection of objects' Like an Empty GameObject that has an object under it in the hierarchy, the underlying object is positioned according to local space (within the group that is the Empty GameObject).


    So:

    Game-Scene (worldspace)

    - Empty GameObject -\

    \- Cube1 | Localspace
    |- Light1 -/


    This is where transform is important. The Transform of Empty GameObject is positioning the group according to the worldspace. The transform of Cube1 and Light1 are positioning according to their space within Empty GameObject.


    So, though Empty GameObject can be in X:1400 Y:54 Z:-245, within the Empty GameObject the Cube1 is perhaps on X:0 Y:0 Z:-10 RELATIVE to its parent (the Empty GameObject. So in Worldspace it is at X:1400 Y:54 Z: -255 (-245+-10).


    Again, I urge you to finish Jonathan's courses and take your time to let it sink in. If these concepts don't ring home yet, I think you are not on level to continue beyond the courses yet.

    Everyday a little more a little better. Always adapting, always improving.

  • I suggest making two steps default in your actions when trying to understand things:


    1. Type in Google.com (or Bing, but that will give way less info) the search criteria: I want to know about time.time in unity

    (You will see that it will give you exactly what you want to know. Best is to first take the links that are of Unity3d.com itself of course).

    2. Go to Youtube and do the same: Time.time in unity3d and you will get all the info you need.


    Btw, as of now, I have a video on the World Space vs. Local Space in respect to transform on Youtube (thanks for putting me onto this task ;) )



    Let me know if I can put anything else up (and if you think the video is helpful of course :D )

    Everyday a little more a little better. Always adapting, always improving.

    Edited 2 times, last by MAD4Games ().

  • I do following the scripting reference but it is complicated, it is hard to understand

    If it is hard to understand, I think you are still missing the more basic understanding. That is why I meant that you should run the parts of Jonathan's course again, so you can see which parts you wer eable to grasp and which you will have to repeat until you understand it.


    It is often that age, language and experience in the field of programming is holding people back at first.

    Everyday a little more a little better. Always adapting, always improving.