Jump to content

  • Log In with Google      Sign In   
  • Create Account


Nickie

Member Since 10 Jul 2012
Offline Last Active Sep 07 2014 12:39 PM

Topics I've Started

Custom Physics: Preventing objects from losing velocity in certain situation

12 April 2014 - 05:12 AM

Illustration: http://s22.postimg.org/7agd30vap/Untitled.png

So the little box is my character. The red arrow shows the current velocity(Some force to right + gravity). Below it are 2 blocks which has the same height. The problem is that my algorithm would solve the collision normals with error.(You can see them in green). These would mean that my character would not slide, but will stop in one place.  In this place both collision normals should have been UP(0,1).

 

Implementation details:

I'm following this tutorial: http://gamedevelopment.tutsplus.com/tutorials/how-to-create-a-custom-2d-physics-engine-the-basics-and-impulse-resolution--gamedev-6331

 

 

Is there something I miss and how can I fix this problem?

 


Defining some terms

15 May 2013 - 06:47 AM

Hello everyone,

I would like you to define some words.

Model - does it consist of just one mesh? Or multiple meshes?

Mesh - does it contain multiple objects. I mean should the mesh contain more than one pair of index/vertex buffers for example.

Node - It may be scene node, and it contain pointer to the mesh/model?, the texture, shader, etc.(to allow using the same mesh with different textures). It contain also parent(if the scene is tree oriented), relative position, etc..

 

Where does the animation goes to? There are thousands of ways that come to my mind to handle animation. Is the character represented from long list of verticles(just one buffer)? If so, I guess animation would go into the mesh object.

 

These questions may seem easy to answer by some people but I would like to make the things clear for myself.

There may be different interpretations of the words I mentions, but what do you understand/imagine when you see these words.


Writing good code based on good architecture

28 April 2013 - 03:44 AM

Hello everyone.

I'm catching a bad tendency about my code. Short after the piece of software grow at 20-25+ files the code seems to be hard to follow and understand. But with proper comments I can remove the last statement "understand".

I'm trying to use some kind of patterns to achive better code however everything end up a big mess at the end.

So... I fail to hide the complexity in my code. However I don't know how to google about books on the subject. I'm not native english speaker and I canno find good keywords.

 

My question is: Can you recommend me a good book that can help me write good code?


Character Animation.

23 March 2013 - 10:33 AM

Hello!

Which is the right way of implementing skeletal animation? Does it worth?

Hardware vs software?

The first thing that pop into my mind is getting all data in memory and one dynamic vertex buffer.

Each frame calculate new vertex position in software and update the buffer? Is this the right way of doing this?

Yes or no? If no,can u give me a hint if 1-2 sentences. I don't deserve more.. after all I ask before I have tried anything ;/


Multithreaded engine queues.

12 March 2013 - 11:54 AM

Hello,

I'm following the intel's multithreaded engine design document.

http://software.intel.com/sites/default/files/m/d/4/1/d/8/Designing_a_Parallel_Game_Engine.pdf

I've already implemented the thread pool, service manager, task manager, state manager(state synchronization, obj has moved, created, etc).

The problem is that I currently have too many queues. I've got global task manager queue(under global I mean shared for all threads which make sense), service queues and state queues. All systems are hidden behind ISystem interface.

So I don't feel confortable with the current way my systems interact. I've got the feeling there is a better way(maybe merging all queues in one?).

 

For example:

I need to tell the graphics module that I want a full screen window with resolution 1024x768. What i do from logics module is:

1. Create object WindowProperties which is derived from ServiceRequestParams class.

2. Call function MakeServRequest(SRVC_SETRENDERWND(which service), this(where should the result be returned, ohh yeah I forgot, I've got another queue for service request results...), ServiceRequestParamsPtr);

3. Handling the request: If-else construct(I really couldn't think of way to "hide" this by polymorphism, altough it is the only if-else construct in my engine), doing the job, packing it in another structure derived from class ServiceRequestParams(yeah the same)

and calling function ReturnRequestResult(Id (ServManager has included it in the data bundle pushed in the queue), class_to_return)

4. Waiting on the callers queue for an answer. Another ugly note: I need a way to track where is the data needed(I gave example with window creation, however this may be physics ray cast). I'm using request ids to identify different requests...

 

Ohhh ugly story. So is there a better way of doing this, can I merge some queues(I need queues for sure for synchronization, I'm on free-step mode), or I should just go back, clear the code as I can and live with it?


PARTNERS