Sytten / WheelsRedemption

The Wheels of Redemption
GNU General Public License v3.0
4 stars 0 forks source link

Feature #3 #15

Closed Corb3nik closed 8 years ago

Corb3nik commented 8 years ago

Hero can jump at different heights based on the amount of time the spacebar has been pressed.

Closes feature #3

Sytten commented 8 years ago

As a general comment, we need to figure out is we put the physics components with the sprite directly or with its parent. Same for the scripts. I don't like the fact that a parent script uses a child component.

Corb3nik commented 8 years ago

@Sytten I agree, it seems odd because we don't have any guidelines on where to put our script objects and where to put our physics components.

The parent components are there mostly for positioning and regrouping multiple child elements (when applicable).

I suggest that all scripts should go in the parent objects. As for the components, I suggest leaving them at the child level since a parent object can have multiple child objects, and that each child object can have different behaviors.

Sytten commented 8 years ago

Yes I agree the parent/child relation is important, In the case of the hero it makes more sense to move the parent than the sprite, so the physics components should be with the parent object...

Corb3nik commented 8 years ago

Conclusion for now :

Components that have dimensions (box colliders, mesh, etc) will be used per child. Components for more generic features like gravity (rigidbody) will be used in the parent.