• Advertisement


  • Content count

  • Joined

  • Last visited

Community Reputation

100 Neutral

About Michel_Carroll

  • Rank
  1. User Interface for level editor

    It would be very difficult to create an intuitive way to display irregular room relationships on your map editor. If you're only going to have a few such rooms, I wouldn't spend that much time on the problem. What I think is a good way is this: Make a separate mini-window containing the irregular room. When you click on one of those rooms, the entrance room is highlighted in a color, and the exit room is highlighted in another color. To change the room relationships, create an option its contextual menu that lets you select the entrance/exit room. This design would be pretty intuitive to me.
  2. C++ Destructor Called Prematurely

    Quote:Original post by cache_hit the array assignment isn't an initialization. The 2 entries already got initialized (i.e. had their constructors called) in the new CPolygon[2] statement. When you *reassign* it it creates a temporary instance, on which it has to invoke a constructor. It assigns using the compiler generated functions since you haven't supplied one yourself, and then it destructs the temporary object. I think I understand now. I didn't stay faithful to the "Rule of three". I should code my own assignement function, and copy constructor. Thank you
  3. It would be very appreciated if somebody could help me with a programming issue. I've been trying to nail a bug for the past while, and managed narrowed it down to this. int main(int argc, char *argv[]) { #ifdef _DEBUG int result = UnitTest::RunAllTests(); #else int result = 0; #endif CPolygon *anArray = new CPolygon[2]; anArray[0] = CPolygon(6); anArray[1] = CPolygon(7); system("PAUSE"); return result; } When I assign the CPolygon(int) constructor to "anArray[0]", it constructs the object correctly. However, RIGHT after constructing it, C++ calls its destructor. It's as if the object's scope has already expired. Here's CPolygon's definition and implementation: // CPolygon.h class CVertex; class CPolygon { public: // Constructors & Destructors for This Class. CPolygon( int ); CPolygon(); ~CPolygon(); std::string ToString(); // Public member variables int vertSize; CVertex *arrVertex; // Simple vertex array }; // CPolygon.cpp CPolygon::CPolygon( int VertexCount ) { vertSize = VertexCount; arrVertex = new CVertex[VertexCount]; cout << "Size: " << VertexCount << endl; cout << "Constructed: " << arrVertex << endl; } CPolygon::CPolygon() { vertSize = 0; arrVertex = 0; } CPolygon::~CPolygon() { cout << "DEST called: " << vertSize << endl; cout << "DEST called: " << arrVertex << endl; if(vertSize > 0) delete [] arrVertex; }; string CPolygon::ToString() { string output = ""; std::ostringstream ss; ss << vertSize; output = "Polygon Vertex Size: " + ss.str(); for(int i = 0; i < vertSize; i++) { std::ostringstream ss2; ss2 << arrVertex[i].x; output += "\n{ " + ss2.str(); std::ostringstream ss3; ss3 << arrVertex[i].y; output += ", " + ss3.str(); std::ostringstream ss4; ss4 << arrVertex[i].z; output += ", " + ss4.str() + "}"; } return output; } I later tried recreating the same problem using a simple local variable, but it got constructed correctly (without calling the destructor right after). Example: CPolygon cp = CPolygon(5); Could somebody please enlighten me as to why it does that? Thank you!
  4. Portfolio Feedback

    I made major improvements to my resume. I realize now that my generic resume has alot of irrelevant information. @SpreeTree I cut out alot of the resume content that gave me "character" (community service, hobby) as you pointed out, but I intend to show that through my cover letter, portfolio, and interview. Plus, I have a friend in the company that I want to work for that can vouch for my personality. First and formost, I want my resume to eliminate any doubt that I can do the job right. Next, I'm going to polish off my Sheep Defender game.
  5. Portfolio Feedback

    Forgive me for the not-so-prompt reply. I'll definitely look at everything in my resume/website more closely, and rewrite stuff to make it more relevant to the industry. Thank you for the taking the time to point everything out. I'm aiming for a generalist game programmer position to start off with. The company I want to apply for is a game developer for IFE (In-Flight Entertainement), which are games played by airplane passengers. They develop their games in C++, using in-house libraries, as well as Allegro, DirectX and OpenGL. They currently have open positions for 2D and 3D programmers. Because I don't currently have sufficient knoweledge of 3D programming, I want to try to get in as a 2D programmer right away. However, I'm currently learning DirectX, which I'll point out to them. The company mentions how the position will involve participating in brainstorming sessions, and writing design specifications. There will be alot of associating with other team members (artists, designers, quality assurance). I'm in the process of learning 3D graphics programming and linear algebra. Should I take the time to polish my game? Or should I move on to another project (I'm thinking a 3D game in DirectX)? Thank you again everybody. This is very appreciated.
  6. Portfolio Feedback

    Hi guys, I'm soon applying for a game developer position. It's a job in C++ 2D programming, because I'm still in the process of learning about 3D programming. Here's my portfolio: www.michelcarroll.com Could people please comment on my portfolio's content, resume, qualifications, presentation, etc.. Be honest! Thank you
  7. Hey guys, I'm exploring ideas for my next portfolio game. It'll be 3D. I'm no artist, or modeller; I'm a game programmer. Therefore, I don't mind having very simple models, as my employer probably won't be looking for very elegant graphics. I've been looking around the internet for good free 3D models, but havn't been able to find ones that I want. How complex would it be to have a these models made? Do you think a novice 3D artist could make these for me for free? -Simple rocks, trees, shrubs -Simple animals such as rabbits, deer, wolves (nothing fancy) -Simple textures to go with these I'm NOT recruiting anybody at the moment. I just want to know how much time/skill this project entitles.
  8. Entity Collection Modifications

    Are you multi-threading? If not, you shouldn't have anything to worry about.
  9. Zombie Portfolio Game

    Quote:Original post by drakostar From the title I was hoping for a game based on zombies in business suits carrying briefcases. To be blunt, zombies as a game theme is getting very overdone, and very few people are doing anything interesting with it. It's the new Tolkien-esque fantasy setting or WWII shooter, or teenage vampire show. It evokes feelings of dread, and not in a good way. So unless zombies somehow play a critical role, as they hypothetically would in a survival game (NOT "survival horror") based on Max Brooks' books, replace them with something else. Evil killer robots, for example, would offer more variety and might be easier to animate, and are somewhat less likely to invoke an eye-rolling assumption of unoriginality. I don't intend on becoming either a game designer or a game producer (anytime soon anyways). Therefore, I'm not really interested in the marketablity of the game. Thanks for pointing it out; I agree with you about zombie games becoming old, although I'd still enjoy playing a Good 3D zombie survival game if ever one comes out. I don't think my employers are going to be against my portfolio game theme. If you dissagree with this, feel free to argue. On a different point, thank you all for your ideas. I like the idea of implementing night-time, although I want to keep the game as intense as possible by keeping the zombies coming during both day and night (more/faster zombies during night).
  10. [C# XNA] Stroy Lines and Programming

    This is what I THINK you mean, and what my solution is to that: If you're referring to interactive conversations with enemies... I think it's better to have a spirit of soft-coding every aspect of the conversation, and designing everything using text files, or a tool of some sort. I tend to hard-code when I don't have a lot of content to include in game. But when the content represents an possibly large dataset, I think it's good idea to think about implementing a lighter way to add content to the game.
  11. Zombie Portfolio Game

    I would like some of your opinions in regards to my latest 2D portfolio game in development. I'm at a point where all that's left to develop is the game specific logic. In other words, the game's display, resource management, input, character movement/collision/animation, pathfinding, and all that good stuff is done. Therefore, if I implement a functional game, and in a week I decide that I don't like it, I've coded a bunch of functions for nothing. This is why I want to make sure I love my game idea (and know exactly where I'm going) before continuing. I know it's a bad development process, so criticize it all you want; this is my career's second game project. Here's a brief of my game idea at the moment: -It's a 2D top-down action game using "cartooney" sprites -The primary goal is for the player character to successfully eliminating a group of enemy zombies -Secondary goals include blocking the zombie's path by using objects, and eliminating them by herding them into traps -Game play consists of picking up game objects, putting objects down in the path of the zombies, and setting up traps for the zombies The enemy's pathfinding/artificial intelligence have to play a critical part in my game, as it's a good demonstration of my programming abilities. Could somebody please criticize my idea, or brainstorm me some more game play elements? I don't want anything that will take too long to implement (such as a weapon purchase system). I want simple/elegant game play elements.
  12. [C++] Memory could not be Written

    FOUND IT!! I deleted the pointer twice. Thank you all for your inputs. I think this all taught me a valuable lesson about defensive programming. I'm going to rework my game's architecture, and be more strict about my programming methods from now on.
  13. [C++] Memory could not be Written

    Quote:Original post by Gage64 I don't know if this is related, but your loops are incorrect. erase() moves all elements after the one being erased, so the element at index i is now at index i - 1. This means you miss certain elements, and may index into invalid memory. You're right, thank you. It could cause problems, so I fixed it. However, it's still crashing the same way.
  14. [C++] Memory could not be Written

    Quote:Original post by Gage64 What kinds of objects are stored in _behaviours? What does the destructor for those objects looks like? What does the destructor for Character looks like? A destructor is not required for Character, since it dosn't contain any dynamically allocated content (new). The pointer to the CharModel is only a reference to another class containing a bitmap. Likewise with Behaviour. No "news". Character.h class Character : public Displayable { public: int x; int y; CharModel* charModel; CharDirection charDirection; CharStep charStep; bool(*collFunction)(Character*); Character(int, int, CharModel*, bool (*)(Character*)); void MoveCharacter(int, CharDirection); //DISPLAYABLE MEMBERS int GetX(); int GetY(); BITMAP* GetBitmap(); int GetXSize(); int GetYSize(); }; Character.cpp Character::Character(int _x, int _y, CharModel *_cm, bool(*fColl)(Character*)) { x = _x; y = _y; charModel = _cm; charDirection = UP; charStep = ONE; collFunction = fColl; } Behaviour.h class Behaviour { private: Behaviours currBehaviour; Actions currActions; public: Character* _character; Behaviour(Character*, Behaviours); void ProcessBehaviour(); void ProcessAction(); }; Behaviour.cpp Behaviour::Behaviour(Character* theChar, Behaviours initial) { _character = theChar; currBehaviour = initial; ProcessBehaviour(); }
  15. [C++] Memory could not be Written

    Here's an error: instruction at 0x7c910717 referenced memory at 0x003cb7ed cannot be read EDIT: And another one: instruction at 0x7c9101b3 referenced memory at 0x0049251a cannot be WRITTEN
  • Advertisement