• Announcements

    • khawk

      Download the Game Design and Indie Game Marketing Freebook   07/19/17

      GameDev.net and CRC Press have teamed up to bring a free ebook of content curated from top titles published by CRC Press. The freebook, Practices of Game Design & Indie Game Marketing, includes chapters from The Art of Game Design: A Book of Lenses, A Practical Guide to Indie Game Marketing, and An Architectural Approach to Level Design. The GameDev.net FreeBook is relevant to game designers, developers, and those interested in learning more about the challenges in game development. We know game development can be a tough discipline and business, so we picked several chapters from CRC Press titles that we thought would be of interest to you, the GameDev.net audience, in your journey to design, develop, and market your next game. The free ebook is available through CRC Press by clicking here. The Curated Books The Art of Game Design: A Book of Lenses, Second Edition, by Jesse Schell Presents 100+ sets of questions, or different lenses, for viewing a game’s design, encompassing diverse fields such as psychology, architecture, music, film, software engineering, theme park design, mathematics, anthropology, and more. Written by one of the world's top game designers, this book describes the deepest and most fundamental principles of game design, demonstrating how tactics used in board, card, and athletic games also work in video games. It provides practical instruction on creating world-class games that will be played again and again. View it here. A Practical Guide to Indie Game Marketing, by Joel Dreskin Marketing is an essential but too frequently overlooked or minimized component of the release plan for indie games. A Practical Guide to Indie Game Marketing provides you with the tools needed to build visibility and sell your indie games. With special focus on those developers with small budgets and limited staff and resources, this book is packed with tangible recommendations and techniques that you can put to use immediately. As a seasoned professional of the indie game arena, author Joel Dreskin gives you insight into practical, real-world experiences of marketing numerous successful games and also provides stories of the failures. View it here. An Architectural Approach to Level Design This is one of the first books to integrate architectural and spatial design theory with the field of level design. The book presents architectural techniques and theories for level designers to use in their own work. It connects architecture and level design in different ways that address the practical elements of how designers construct space and the experiential elements of how and why humans interact with this space. Throughout the text, readers learn skills for spatial layout, evoking emotion through gamespaces, and creating better levels through architectural theory. View it here. Learn more and download the ebook by clicking here. Did you know? GameDev.net and CRC Press also recently teamed up to bring GDNet+ Members up to a 20% discount on all CRC Press books. Learn more about this and other benefits here.


  • Content count

  • Joined

  • Last visited

  • Days Won


jpetrie last won the day on July 18

jpetrie had the most liked content!

Community Reputation

13063 Excellent

About jpetrie

  • Rank
    Moderator - For Beginners

Personal Information

  1. What exactly is it you're trying to accomplish (if you say you're not rebasing anything yet, why are you running the command)? The "proper" content of that text file depends on your goal, and putting the wrong thing in there (or deleting the wrong stuff) can have unpleasant consequences.
  2. Handle errors how? D3D reports almost all failures using HRESULTs, you don't need dxerr.h's functions to interpret and handle those failures. For the most part the SUCCEEDED() and FAILED() macros will let you make the appropriate determination, and they will be pulled in by simply including Windows.h. The dxerr library is basically dead. All it was useful for, really, was getting formatted error strings from some HRESULTs, and some utility macros. If you really need that functionality you can find various reimplementations (for example, header and source). In practice I've found it more useful to simply write code that interprets the actual HRESULT in the context of the actual failure and propagate a custom error message to users that way, rather than the generic context-free messages produced by the old dxerr functions. You can also use FormatMessage directly.
  3. What's the error you get when you try? Adding a "reference" to a native project like that isn't necessarily going to set up the include paths correctly; probably the only thing it's doing for you is ensuring the referenced project builds before the referring project. Depending on how you set it up, it may also be automatically linking in the static library output of the referenced project. Chances are, you need to go into the project settings for your main project and find the include search paths option, and modify it to include a relative path from your project to the directory containing the D3DApp.h source code. Or, frankly, not bother with a separate project for this and just lump it all into your main project.
  4. Git just invokes your text editor. It's your text editor. I can't tell you how to use it. If you don't know how to use the text editor you have installed, consider getting a different one. Git will use whatever the appropriate OS-level mechanism is to try to find your default text editor, if applicable, or use the one you tell it to via your .gitconfig or similar. Then it will invoke it and wait for you to close it and read the (usually temporary) text file you generated with the editor session to continue its work.
  5. Yes, this part is true. No, this part is not. The parent (base) class cannot see into the derived class. It doesn't know anything about it, and cannot act on any member variables of the derived class directly. The Base::Method() syntax you're seeing here is nothing magical, it's just a way of disambiguating, for the compiler, which function you want to call in a case where there are two versions (the base virtual method and the derived overridden method, for example). It is otherwise akin to any regular old member function call. Your terminology is a little off again, here. In your example, "value" is a member of A. Not B; B doesn't have a member named value of its own, it just has A's value because B inherits from A, and thus every instance of B is also an A. When you say things like that something "will act on the derived class variables," what you are saying is that if (continuing your example) B had a member variable called "name," that calling A::FancyFunction from B::FancyFunction could let A set name = "Frank." But that is not possible.
  6. It's hard to say without the code. But probably what you are seeing here is that D3DApp::Init() is being used to call the base class version of Init(). I'd venture to guess that the author is suggesting you use this pattern to allow you to insert any of your application-specific code before or after the base application initialization runs. There are alternative, better (in my experience) ways of implementing this pattern. But in this case the author is probably opting for simplicity and straightforwardness at the cost of robustness and expecting you to just "remember" to call the base class Init function at the right time. The Foo::Bar() syntax means different things in different contexts. In this context, it means "explicitly call Foo's version of Bar on the object pointed to by the this pointer."
  7. As for your actual plan: What do you mean by "build," here? You keep using that word, but it doesn't make sense in context. Do you mean a build is like a shipping version of the game, so you'll ship the initial game (one build) and then 14 more content updates afterwards? Everyone is actually working for you. And the people you want working for you will know that, they aren't going to be suckered in by hype like "everybody is working for themselves." They're smarter than that, so I'd recommend you don't try to pitch that angle. How are you expecting to hold everybody to this "two hours a day" schedule? Two hours is too small a time window to produce a usable, measurable artifact on a daily basis. What does getting paid "twice as much for what they did" mean? Twice as much as what? What is the "small percentage," and what is it a percentage of? What accounting method do you use to arrive at that value. Your business plan here needs a lot of work and a lot more detail if you expect worthwhile developers to be interested. I think you are being extremely idealistic and, consequently, unrealistic in your expectations of why anybody would want to work for you, a self-proclaimed neophyte when it comes to game development. Unfortunately making the game itself usually bears little to no resemblance to what playing it will be like. It's not "scary" to make zombie games. It's not going to be intrinsically funny or even fun to make a comedy game.
  8. If you mean "resubmit" here (as in re-post), please don't do that. You're welcome to engage in a discussion with the larger community about your plan, but there's no need to re-post it daily.
  9. "Pull requests" are a feature of GitHub, not Git itself. They're a project management mechanism, and as the name implies are simply a request by somebody for the owner of a GitHub project to pull some proposed changes from another branch (usually in another fork of the repository). GitHub provides some infrastructure around supporting comments and peer review of pull requests, should you want to use that. Ultimately when a request is accepted it is merged into the target branch (usually master) exactly as you'd merge any other branch by hand. GitHub just provides some helpful buttons to do that for you. You can use GitHub's Pull Request system however you like. Or not at all. It is purely a convenience mechanism.
  10. Looks good. Two notes: You explicitly call GetWindowLongPtrW(); you shouldn't need to do this, especially as you don't explicitly call the other wide-character overloads. Just call GetWindowLongPtr(). Needing to explicitly call the *W or *A variant of some Win32 function is usually a sign you're doing something tricky (this is not) or something wrong. Instead of passing 0 to GetWindowLongPtr (or SetWindowLongPtr), consider passing the constant GLWP_USERDATA. Passing a value >= 0 is asking to retrieve sizeof(LONG_PTR) worth of data from the "extra" memory you asked the API to allocate when you created the window style (via the cbWndExtra field)... which most people never do. If you've actually done that, great. But if you haven't done that, you're reading from and writing to garbage memory which is likely to crash you soon or later. Using GLWP_USERDATA is, in my experience, more common than manually bothering to allocate extra instance data.
  11. Ah, yes, what you are describing there is correct and supported. If your D3D11Engine inherits from D3DApp, and D3DApp's "WinProc" function is virtual, you may override that function in your D3D11Engine class. Your version of the WndProc function will be called when anybody calls WinProc on a D3DApp* (or D3DApp&) that actually refers to a D3D11Engine object. This is incorrect terminology on your part though, and probably what contributed to my misunderstanding your goal. That global pointer is a pointer to an object, not a function, so that global pointer can never point to a function, let alone your derived class function. However, it can point to a D3D11Engine object. Which is what you actually want to accomplish the behavior you're describing. You don't need to do this, actually (but that was commendable problem solving). Even though, during D3DApp's constructor, the dynamic type of the this pointer is a D3DApp, the actual object will eventually be a D3D11Engine and the dynamic dispatch of anything via that pointer will work as it should. However, as Oberon noted, the use of this global at all here is a bad idea. I'm really disappointed to find a book espousing this method. The correct way to handle the whole issue of the window procedure callback not being a member function is, as he noted, to stuff the actual pointer to the engine object into the window's user data storage.
  12. During execution of the constructor for type T, the dynamic type of "this" is T*. That is, "this" is always a pointer to a type of the currently-executing constructor within that constructor. Even if the object will ultimately be some more-derived type. So, in the D3DApp constructor, "this" will be a D3DApp*. In YourApp's constructor, "this" will be YourApp*. As above, no. And even if it were true that wouldn't allow "re-defining" virtual member functions in that constructor. Functions are not fields of any given class instance, so you couldn't do something like "this->myFunction = newVersionOfThatFunction," which is what it sounds like you were hoping to do. This is known as an unnamed (or anonymous) namespace. The purpose, here, is to prevent the global variable declared in that namespace from being accessible outside the translation unit it's defined in. So yes, basically to keep that global confined to that file. In general, nothing bad. In this particular scenario, the gd3dApp pointer is assigned to in the constructor of D3DApp, so that's a problem. It's not really a problem if you derived two types from D3DApp, though. It's a problem if you create two instances of types derived from D3DApp (or of D3DApp itself). In that case, the gd3dApp pointer will refer to the instance that was constructed last, whichever one that happens to be. That may cause the earlier-constructed instances to misbehave if they rely on the assumption that "this == gd3dApp" anywhere. gd3dApp is a singular global variable. There's only one, not one per D3DApp subclass.
  13. This is a visualization that is specific to your tool, so only somebody who uses that tool can give you a definitive answer. That said, these kinds of graphs are common for visualization of Git repositories and if you posted a screenshot somebody might be able to make a reasonable educated guess. If you want. You can also just avoid pushing the feature branch anywhere, which is usually what I do.
  14. Right in one of the project settings panes.
  15. The "local master" and the "remote master" are the same branch, conceptually. The "local" and "remote" just refers to where the physical storage for that branch is. You merge your feature branch into the master branch. You do this locally. Then, you push the master branch somewhere. This causes the copy of the master branch at that "somewhere" location (the "remote" location) to be updated to reflect your local copy. You don't, and for the most part cannot, directly affect a remote clone of a repository other than with the push. Git stores the entire repository with each clone (barring exception circumstances that are irrelevant here). So there's a copy of the master branch here (the local) and a copy of the master branch there (the remote). There will be as many copies of that branch as there are clones of the repository. Just like there as many copies of this post as there are people who read it: the copy stored on the forum's database, and the copy your machine downloads to display in your browser.