Jump to content
  • Advertisement

YengaMatiC

Member
  • Content Count

    70
  • Joined

  • Last visited

Community Reputation

172 Neutral

About YengaMatiC

  • Rank
    Member
  1. YengaMatiC

    lightmapping + normal mapping.

    Speaking of HL2 shading, do you know how ambient cube works/is computed? I know it's some sort of computing light intensity in each of 6 basis directions (+/- X/Y/Z), but i still don't get the point. Filami, HL2 NM-radiosity works blending 3 lightmaps computed from 3 different directions (forming a known basis) using the normal on the fragment (look at the paper).
  2. YengaMatiC

    What is the better way to do to this.

    I think scissor test would be the easy option, while changing camera to a panoramic view and resizing the viewport would look better. There's a good tutorial on glScissor on NeHe. What problems are you experiencing?
  3. YengaMatiC

    Lispsm

    Light can be modelled as a camera (ortho for directional and perspective(s) for spot/omni). So you can transform points into camera's space using it's mvp matrix.
  4. YengaMatiC

    C++, references

    You can think of references as an alias for another variable. When you do this: SomeClass kInstance; SomeClass &rkReference = kInstance; You have only one instance to SomeClass, but two symbols that referentiate it. Internally, references work like pointers. They have stored the address of the actual object, but they have the property of auto dereferencing when you use them, so in practice you feel like using kInstance. class SomeClass { int m_iMember; public: int &Member () { return m_iMember; } int *MemberPtr () { return &m_iMember; } }; SomeClass kInstance; int iMember = kInstance.Member(); iMember = 4; // this doesn't change SomeClass::m_iMember int &riMember = kInstance.Member(); riMember = 4; // this DOES change SomeClass::m_iMember int *piMember = kInstance.Member(); *piMember = 4; // this DOES change SomeClass::m_iMember Do you see the difference? Pointers and references can change the actual value that they point to, but with references you can use the same syntax as normal variables. See that SomeClass::Member() returns a reference, but I can use this function in two ways: 1) Assigning the return value to a normal variable, so it cannot change the value of SomeClass::m_iMember 2) Assigning the return value to a reference variable, so it CAN change value. Why don't we use references instead of pointers? Because you have to tell references what variable they are referencing when you declare them. Also, you cannot call new or delete on references because they're not pointers in a strict sense. Basically that's it, hope this helps :)
  5. There are tons of tutorials on STL map, also here's the SGI page of STL. You can google for tuts and source with a simple 'stl map' search. BTW, you can also try the boost or stlport library. I haven't used them, but they're good libraries too. OGRE engine and many open-source engines have implementations of hash strings and hash maps. You may want to take a look at their docs/source.
  6. YengaMatiC

    Keyboard/mouse input

    I like event dispatchers. You simply provide the interface for event handlers and each subsystem that wants to get input registers its callback function to input system's listener chain. Each frame, the input system generates events and sends to the first listener in the chain. You can implement your dispatcher in whatever way you want, various chains (one for each event type), a priority based chain, a ring-chain or hibrid approaches. I like this way of doing things because input processing is isolated from other tasks.
  7. I'd use STL map, or any other premade one. I've used a handle-based system, indexing an array with the handle and mapping resource names to handles with a STL map. If you have an inheritance tree and want your cache work for all kinds of objects, then use pointers to base resource class. I have a cache for every type of resource, and then a manager that holds that cache (TextureMgr, MeshMgr, WhateverMgr). If you go for the home-made hash table, you could store the hashes in some variable (using hash strings?) so you don't have to run the hash function everytime.
  8. YengaMatiC

    Complete Gameengine design?

    I like looking at open source engine's documentation (OGRE, NeoEngine, WildMagic, ...) to see how they organize their subsystems/packages/modules/whatever. Also, you can take a look at Enginuity or Code On The Cob series, it's a pity they're unfinished but you can get good insights.
  9. I think you are lacking of objectivity (or don't want to). Some of you compare DirectX (multimedia library) with OpenGL (graphics library). That's not a good comparison, and even thread's title says so. Then you think D3D and OGL are like 5 years ago or so. Things have evolved pretty much, as hardware did. Now there are only two brands: nVidia and ATi. OpenGL extensions are not a problem because there are libs that load all extensions with a single line of code (maybe two) with no performance hit when you use them. So this argument is no more valid. Performance is not a problem, as we all know that both APIs work well in overall. Then, what's the problem? None. Almost all people choose D3D or OpenGL because misinformation (MS, friends, forums, ...) or because a few years ago they preferred one of them (for some arcane capabilities that weren't in the other API) and stuck with it till the end of days. Why did I choose OpenGL? Because I found it easier and I was going to use it in university. I'm an OOP man, but I don't mind using a procedural syntax. In the end, both D3D and OGL get encapsulated into the graphics system of the engine. So, who cares? Just choose whatever you are more comfortable with, and don't believe who tells you "DX is better than OpenGL" or viceversa, they're liars.
  10. YengaMatiC

    Prehistory game: instincts vs intelligence

    Yes, I know. But it's intended to be a playable game and not a movie. I want the game to be somewhat humorous in that situations, so you have to correct what your instincts do bad. How do you think it will affect gameplay? See that you would be somewhat forced to suffer the situation, even if later you'll continue without solving it. EDIT: A friend just told me that in Vampire: The Masquerade, you enter in a frenzy and attack your mates or other people without control (it seems that controlling your character in this situation is somewhat hard). This may be an example of what I intend to make. PD: I think I'm explaining the concept good, let me know if it's not. I feel like it isn't being understood or well exposed.
  11. YengaMatiC

    Prehistory game: instincts vs intelligence

    Yes, there will be like cut-scenes where do you see how your character makes actions that put him in trouble, then you get the controls and try to solve the situation. I'll try to illustrate with an example situation: You see a honeycomb hung from a tree and think, 'Hmmm I like honey'. Suddently, your character starts to run towards the tree (and bees) to get the honey. When the angry bees sting you, you regain control of your character. Now is when you have to solve the situation. You can jump to the river, use a branch to make the honeycomb fall from the tree, use smoke from a fire to drive bees away or simply run and continue with the story. Those situations may be triggered when you are near the situation scenario (at 20 meters from the tree i.e.) or you could be forced to play it (you should be able to leave out the situation like escaping from bee stings). If you solve it, you will be more proficient throwing stones, making fire, using a club or even running :D but you'll also see less of this situations.
  12. YengaMatiC

    Prehistory game: instincts vs intelligence

    Hmmm, sorry about that, I forgot to specify the type of game. It's intended to be an action/adventure game, with a few chapters representing each big step of human evolution (australopithecus, homo erectus, homo habilis, homo sapiens).
  13. YengaMatiC

    Use Cases for game design

    Ok, now I get the point on Use Cases, I really needed some guidance :) I also thought that my use case was trying to explain many actions, but i didn't notice that there are all that fields to describe the use case. As for the 'writing use cases for each subsystem', I see now that it's innecesary because it would describe what the system has to do and not what the user can do with the system.
  14. I find it funny there's always a fight between our animal instincts and our appreciated intelligence in everyday's life. You can feel it when you see a beautiful woman, a delicious cake or when you see a spider (whatever you fear of). Instincts take control of our minds everywhere. I've been thinking of a game in which you can show the progress of this fight along human evolution. Here's the story in brief: At the end of the day, you fall asleep, but when you wake up, nothing is the same. You are in a prehistoric environment, with rare animals walking and flying everywhere, and you've turned into an ancestral hominid. Your instincs have taken control of your mind, but with a feeling inside that pushes you to manage your supervivence: your primitive intelligency. As you progress in the story, you make great discoveries that make you [re]evolve through hominid species until homo sapiens. You learn how to make and use tools, weapons, fire and finally language. The main objective are play through scenarios to finally discover what makes you evolve in a situation that needs an intelligent use of your abilities at the moment. For example: in the phase where you are an Australopithecus, you r abilities are throwing stones, hit and bite others and grumbling, so don't expect to kill a mammoth it that state. How to show the fun of the instinct vs. intelligency fight? I can think of situations that make it visible, so you are the intelligent part of the fight and the computer plays the instincts for you. What do you think about the instinct vs. intelligency part? It would be like a bonus, if you resolve a situation where your instincts get you in, you gain more control over your character and abilities, being less prone to your instinct's dirty tricks. Thanks for your feedback. PS: English is not my first language, there will be lots of faults, don't be bad at it ;)
  • Advertisement
×

Important Information

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

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!