Jump to content
  • Advertisement


  • Content Count

  • Joined

  • Last visited

Everything posted by Sachs

  1.   I got it! This method is easy and effective. Thanks a lot.
  2. Hello, everyone. How can I get the following effect ?   http://www.148apps.com/wp-content/uploads/2011/06/hardlines3.jpg (Screenshot from game "Hard Lines", and the lighting lines are beautiful)   Thanks!
  3.   This is the screenshot: http://flic.kr/p/eDFLwx   I do this in GIMP:     1. I begin with a black background(layer 1).     2. Then draw the red(255, 0, 0) line (4 pixels) in the layer 2.     3. Copy layer 2 to layer 3     4. Use gaussian fliter(kernel size is 10x10) to blur the layer 2.      5. layer 3's mode is addition.   The problem is:     1. The middle red line isn't as bright as I expected. I guess it didn't blend correctly.     2. The "glowing" is also too dark.   Thank you for the advice.
  4. When I use the Gaussian filter to blur a line(1-2 pixels)  in the whole black background, the blurred line is dark and it's "glowing" range is small. Then I compose the tow lines, the final effect is not as clear as the game's. May be I missed something?   I haven't read the book, but I will check it later.   Anyway, thanks for your reply.     I have no idea with "a texture with the glow", could you give me some examples? Or you can tell me where I can find the texture? (I have already "googled" it, but can't find something useful.)   Thanks a lot.
  5. Sachs

    Game Programming: Snake

    Thank you!
  6. Thank you! It confused me for a long time.
  7.   Right, as different Component has different "value", e.g. Component "position" has two float value "x" and "y", we may be dynamic generate those values. Because there is no class in C, we couldn't extend from a base class like IComponet. So I store these dynamic generated values into a string hashtable, which key is "variable name",  to describe a Component, just like we "describe" a class is in OOP language.   When we create Entity, we can pass the Component name we "described" before, the engine may allocated memory to store the Component's value which just like we create an object in OOP language.      I agree with you. May be Systems have some function pointer like void (*on_update)(float dt), and we can assign different function for different System, right? But I'm not sure is it a good implemention, I'm still exploring.   Anyway, thanks for your replay and  any suggestion is aprreciated!
  8. Hi.   Recently, I read some articles about "Entity-Component-System", one of these is  "What is an entity system framework for game development?" written by Richard Lord.   In his article, he mentions that component only contains data which is like C's struct. Entity is a set of components which also don't have any method. All operation are moved to system.   This is data-oriented programming rather OOP, so why we still use OOP language rather than the C language? I'm interested  in what it will be when implemented in C.   One of the implementation may be like this: ecs_component_create("position"); ecs_component_add_value_int("position", "x"); ecs_component_add_value_float("position", "y"); ... int id = ecs_entity_create("spaceship"); ecs_entity_add_component(id, "position"); ecs_entity_set_value_int(id, "position", "x", 0); ecs_entity_set_value_int(id, "position", "y", 0); ecs_engine_add_entity(id); ... ecs_engine_add_system(engine, "RenderSystem", priority);     I'm not sure whether it is right, can someone give me advises?   My English is poor, and thanks for your patient!
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!