Arima's Recent Forum Activity

  • How dare you post about something which isn't entirely about C2 in open topic which is specifically a section for talking about whatever, including stuff that isn't about C2! Rage, anger, etc

    Kidding, kidding. In all seriousness, it is nice to know that their Facebook page is getting lots of complaints about it.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • I'm not sure the proper advice to give here. If you're not comfortable enough with construct yet, trying to make a level editor could prove frustrating. I'd recommend just learning how to get the components of the idea working first before making the editor itself. Some examples - here the basic game and editor code structure:

    If variable 'mode' = "game"

    • Game code as subevents

    If variable 'mode' = "edit"

    • editor code as subevents

    Structuring things this way isolates the editor from the game itself.

    You can store all instances in an array or dictionary named 'levelData'. Then store that array or dictionary as a json string inside a key such as "level 1" of another dictionary named 'allLevelData' and save that to disk via the node webkit plugin. Then basically do the reverse for loading, getting the type of object to create and where from the saved data.

    Again, learn, read the manual, and get a good understanding of how each piece works before trying to make the whole thing.

  • Yes, I made my own level editor. It's not something you need to learn JavaScript to do at all, my level editor is all in C2 via events. I can press a button while playing the game, edit the level, press the button again and I'm back to playing the edited level.

    I really don't recommend editing the tile map plugin for a couple reasons - first, it would be far more complex and Ashley has talked about why that's not a good idea because achitectural changes might be made to C2 which could invalidate the plugin you made.

    Second, while I'm almost entirely sure the tile map plugin is more efficient, that I'm also almost entirely sure that that efficiency depends on it being snapped to a grid. To get the effect you want would undo those optimizations.

    A level editor isn't the easiest thing in the world to make, but it's far fom the hardest. Basically you need to recreate the ui needed for placing, moving and deleting objects as well as selecting them and editing their parameters and variables that C2's editor gives you. You also need to come up with a system for saving and loading data when editing, and a way for your game to delete a level when you leave it, and to know what data to load and create at the start of a new area.

    I decided to have my editor in game, but you might consider making an external level editor, which might be easier to reuse and make work for multiple game types.

    It does take some work, but man is it smooth when you've got it working.

  • Ah, perhaps I wasn't clear enough. When I spoke about the high CPU use, I meant I'm still getting 55-60 fps, but just barely. I think I can keep it there with optimization.

    I also don't think I made it clear that I aside from this one problem, I'm pretty sure my computer is capable of running the game as I imagine it, so there's not much reason to target a higher spec anyway.

  • The gpu isn't relevant, as my computer has a 9800gt which is easily capable enough for this game and I wouldn't need anything above dx9 anyway. The drivers are also plenty stable enough even though nvidia has decided to stop updating them. My system was only blacklisted because it's vista, but I can get around that anyway by ignoring the blacklist.

    I'm a bit surprised you're arguing against it. You often mention in threads about what can be done on mobiles with optimization - why do you think my CPU shouldn't even be bothered with when it's still far more powerful than most mobile devices as well as having the benefit of JavaScript compilation via v8 which iOS doesn't have? Shouldn't the same philosophy be applied here, if the hardware is capable of it? Why shouldn't I target my CPU if I can? I'm pretty close to managing it, and really, even on an i3-i7 I would still probably need to implement the dynamic loading anyway.

    I know all games need a minimum spec. I decided my computer is that spec. I respect that you wouldn't want to target my computer for a PC game, but that's not what I want to do.

  • PC. From what my research found looking at performance tests, actually the top of the line CPUs like an i7 4770 3.2ghz (single thread rating is listed at 2254) are only about 3.3x faster on a single thread (my 4400+ has a 678 single thread rating). I'm not an expert on the matter, but as far as I know desktop CPUs have had only small single threaded performance improvements for a while, which is part of why they've gone multi core. I'd be happy if I was misunderstanding and they were actually faster, though.

    Regardless, this is the computer I have and I don't have the money for another, so I would prefer to have it working smoothly on my PC as well, not to mention that would make sure older computers can play it too.

  • - I gave it a try, but if I have any more than about 10 objects, it stops working properly because the objects push out, then end up overlapping another object, and get pushed out further, resulting in a weird vortex of teleporting objects. I was also getting teleporting while sliding along walls.

  • That's not really optimal for watching something though because I'd have to keep pressing pause every second and then scrolling to find the group each time to watch what it does. :/

  • It's possible (I've got it working for my game), but you'll have to make the level editor yourself.

  • Seems like as good a time as any for an update.

    The level editor is coming along great. Stuff made with it is looking super awesome.

    However, I've recently discovered that the game is kinda CPU intensive. This is a problem for my game in particular because of how I want the level itself to be able to be used as a weapon, and I want the players to be able to be clever and lure a difficult enemy into a trap that was a bit earlier in the level to defeat it instead of tackling it head on. This means as the players move from one room to another, the game has to keep processing what's going on in other rooms so enemies can follow.

    I've been optimizing and have managed to double the number of enemies in an area from 50 to 100, though that will probably be reduced some later when the rest of the code is in there. Some good news is that's on an about ten year old CPU that I want to be the minimum spec (AMD Athlon 64 x2 4400+), and top of the line modern processors' single threaded performance is about three times that, so on even a midrange modern computer that should be more like 150-200 enemies or more.

    This is still less than I hoped for the minimum spec (100 enemies in an area not enough? You crazy, Arima?), but I think I can make it work, though I'll likely have to design a dynamic level loading system that loads sections of a level that are close and saves and deletes sections that are far. I have to be careful when doing that though, or an enemy could wander into a section of the level that isn't there.

    I was hoping to avoid having to implement anything like that for the prototype, but to get a good idea of what the game is like it'll probably have to be there, though I have an idea for a 'cheating' version that will be less effective, but hopefully effective enough and far easier to implement.

    I'm also beginning to doubt a design decision. I've made each unit use physics for its base, which works great for sliding objects along obstacles and allows me to make cool swarms like this:

    However, doing do ups the CPU use, especially since I discovered chrome/node webkit doesn't actually support asm.js for accelerated physics, and I'm not sure it's worth it. I'm going to have to debate it for a while. Perhaps if I'm clever, I can set it up to make it so I can turn on physics use when I want swarms and leave it off otherwise, but then players might wonder why enemies can move through each other sometimes and not others. I'm not sure it's a good idea to be inconsistent on that matter. Hmm, maybe I can dynamically turn it off or on depending if an object is overlapping another or not. Gonna have to play with it a bit to find out if that's effective or not, or even necessary with a dynamically loading level.

  • I agree that an option for static/dynamic rearranging is a good idea.

  • I'm trying to optimize my game, but it's frustrating trying to watch a group's CPU use in the profiler because they keep rearranging themselves constantly. I think it would be far more useful if they didn't rearrange themselves at all.

Arima's avatar

Arima

Member since 11 Jun, 2007

None one is following Arima yet!

Connect with Arima

Trophy Case

  • Coach One of your tutorials has over 1,000 readers
  • Educator One of your tutorials has over 10,000 readers
  • Email Verified

Progress

19/44
How to earn trophies