Jump to content

  • Log In with Google      Sign In   
  • Create Account


Member Since 23 Jan 2009
Offline Last Active Private

#5230671 Easy source control for educational uses?

Posted by on 24 May 2015 - 07:13 AM

Thanks for the ideas everyone. I'm going to start evaluating all of them. I'm actually leaning towards switching over to SVN clients, since GitHub apparently has SVN access. Thanks again, improving our source control workflow's gonna give us a way better shot at making it to the championship.

#5230430 Client side hit detection vs server side with prediction

Posted by on 22 May 2015 - 09:46 AM

So I'm working on a multiplayer game, and I've been reading that a lot of games lately have been switching to client side hit detection. I thought that the best way was supposed to be server side hit detection with hitbox rewinding, not client side hit detection. I know client side gives a better feel to the guns, but it's supposed to be much easier to cheat too and as far as I understand, rewinding hitboxes and predicting the effects on the client should be able to produce the same feeling of responsiveness. What are the benefits to doing it client side that are causing more games to use it lately? Is it just that it's easier to write? Or are there some other advantages to doing it client side that I'm not aware of?

#5198937 Serializing individual entities

Posted by on 18 December 2014 - 08:13 AM

Okay. So basically just creating component templates using structures and allocating them individually. For the amount of things I'll actually be spawning that way that actually sounds pretty good. I think the only real big loading costs are going to be the things that are placed on levels at the start anyways. I'll be having probably 9v9 player counts at most, so spawning 18 prefabs like that, plus whenever I have to spawn some sort of rocket or other slow moving projectile wouldn't be too bad.

#5195353 Improving component system

Posted by on 29 November 2014 - 10:54 AM

I'm working on upgrading my component based entity system. Right now I have a hierarchy of Entity objects within a Scene (which is itself just a special Entity). Each Entity has components that implement a Component interface that are basically a collection of callbacks. Components have onAttach, onUpdate, onDetach, etc. callback functions that are called when these events happen. The problem here though, is that I've got a really random memory access pattern by traversing through the hierarchy every frame and calling into each component. What I would like is to have a more linear memory access pattern where all components of the same type are updated together all at once.


I tried making it so my Component classes were just structures of data, and have a System that actually implemented the functionality. The problem with that though is actually tracking components. Should I require that when an Entity is created it will have a pointer to some sort of "SystemManager" that it can notify when Components are attached or detached? And if I do that, then how would I be able to retain support for my features like disabling entities and all their children? I can't just check the owner Entity of the Component to see if it's disabled, because that would throw another random memory access back in, and it would create more work when I have to traverse the hierarchy upward until the root to see if any parents are disabled.


Basically, all I want to do is be able to make my memory accesses more linear to improve cache performance while retaining my features (mainly creating a Scene in memory without setting it as active; and being able to disable an object and all its children). I don't care if I have to separate functionality from components, in fact I'd prefer to do so because of the extra opportunities for parallelism it presents in the future.

#5174587 Additive blending artifacts

Posted by on 18 August 2014 - 06:36 PM

Wow... Alright, for other people's future reference, that pattern is what it looks like when you output the wrong type to SV_TARGET. It doesn't give you a warning or anything, it'll compile just fine. It turns out there was a bug in my shader generator that left the 4 off of the return type. Hopefully no one else will spend 5 hours debugging depth buffers now only to find it was a simple return value issue.

#5159329 How is the elongated light beam/tentacle effect achieved?

Posted by on 09 June 2014 - 01:59 PM

I would assume they're just a tesselated textured strip of triangles animated with some sort of sin() or cos() function in the vertex shader.

#5158770 Run DirectX 11 stream output without drawing

Posted by on 06 June 2014 - 01:51 PM

I've also been considering using a compute shader to do skinning, but for now I'm just going to do stream out because I haven't written a compute framework in my engine yet.

#5155909 Skeleton representation

Posted by on 25 May 2014 - 12:07 PM

Okay, so it's basically the same thing as a normal system performance wise then. I don't think the attachments would need to cause an update at runtime if they didn't affect the transform for current frame would they? Or are you talking about how the bone indices are assigned to the matrix array?

#5147649 Fast GUID generator

Posted by on 17 April 2014 - 08:47 AM

Thanks for the advice. I'm thinking so far that I'll probably avoid GUIDs. I thought that was how most engines did things, but if it's overkill for realtime I'm not gonna bother. What the IDs will be used most for is querying game objects by their ID. If an prefab file is loaded with internal ID links then I want to retain those links while also being able to reference objects globally. I also want to have the ability to use the IDs to refer to objects across the network. Would it be a good idea to just have the ID generator reserve IDs in blocks and then "patch" local hierarchies of object IDs at load time? So lets say I load a prefab with local IDs starting from one that are only unique local to the prefab. Then I take the root object of that prefab and generate the next global ID for it, and then just increment the local IDs further down the prefab's hierarchy so that they retain their offset from the prefab root. Are there any inherent problems with a method like that?

#5086616 AngelScript 2.27.1 is here (so soon? yes)

Posted by on 16 August 2013 - 05:16 PM

I'm actually really excited to hear anything about a reduced memory footprint. AngelScript is already so small and optimized that it's amazing you can squeeze any more performance out for the features we get.

#5015556 How many levels is enough?

Posted by on 29 December 2012 - 04:45 PM

I'm working on a 2D platformer and I'm trying to decide how many levels to have. It's an Android/iOS app. Each level is a little bit less than a minute long but you have to play through them at least three times to find all the unlockables. How many levels make it worth the $0.99 to the players? I want to have lots of levels, but I don't want to have any "filler" content.

#5001829 Impotant! Books to start learning video game programming ! I need it...

Posted by on 17 November 2012 - 02:12 PM

I started learning when I was about 12. And the most important thing to remember is that you are NOT going to make a Halo or a Call of Duty or a World of Warcraft for your first game. Too many people (myself included at that time) bite off way more than they can chew and end up giving up on their project. My favorite book for C++ as a beginner was Beginning C++ Through Game Programming by Michael Dawson (that's for the latest edition anyway). I also think that if you aren't ready to learn C++ you might want to try Unity 3D for a little bit to get used to scripting before going for full on programming. If you want to see a Unity project I've finished a game using it and could show you how everything works. PM me if you're interested.

#4993791 How much CPU usage should just an empty game loop have

Posted by on 25 October 2012 - 07:48 AM

Thanks everyone. I've got it using up between 3-4% CPU and running locked at 60 FPS now. @freeworld This engine is going to run on Android also, so battery life is VERY important.

#4993138 Favorite little known or underused C++ features

Posted by on 23 October 2012 - 10:45 AM

Personally I like dropping the comma operator into functions just to upset people who have to read my code.

You are Evil Steve Posted Image

#4980684 Making smart-seeming NPCs

Posted by on 16 September 2012 - 12:33 PM

This article had really good information. It's applied to open world NPCs but I don't see why you couldn't learn from it for other genres.