ShrewdPixel

Members
  • Content Count

    65
  • Joined

  • Last visited

  • Days Won

    4

Reputation Activity

  1. Like
    ShrewdPixel got a reaction from SharedDreams in 12 MiniBattles (Available for Non-Exclusive License)   
    Play tested using Chrome on MacOS Mojave
    Good selection of action match up mini-games that play with a great frame-rate. The controls could use a bit more explanation, since the single button interface is more intuitive for some games than others, but overall a good retro feeling experience.
    It definitely has potential; Good Luck!
  2. Haha
    ShrewdPixel got a reaction from Nagval333 in Anyone using gamedistribution.com as a publisher?   
    I love a good online mystery. (a guilty pleasure of mine, I must admit.)
    So I decided to do some digging. pro style.
    Here's what I found:
    As for the origin of the company being in Turkey, there is some credibility to that, as can be seen on their LinkedIn account. (See Screenshot)
    They also have taken some serious liberties on their Github account, like with Phaser. (Not forked, straight up lifted- see link and screenshot)
    Their domains are protected from whois search for registrar info with a solid lock, so it would cost money to actually find any previous records.
    And the venturebeat article linked to above is valid, so they obviously are not strapped for cash in any way that would prevent them from paying devs.
    Finally, to address their complaint to bestgames above to not give out their personal info, maybe a better solution would be to just pay the devs that have been helping you make so much money that you can buy other companies with it?
    I've provided screenshots because I've noticed their account on here is actually following these threads. (You can see that on people's profile pages, you know?)
    I hope that helps people with their assessment of their available options for online distribution.


    EDIT -- February 4th 2019:
    I've recently noticed that they've taken a sudden interest in my online profiles after this post. (See screenshot) And I don't think it's to see if I want to submit games.  

  3. Like
    ShrewdPixel got a reaction from Nagval333 in SICARIO KID - quick-shot duel   
    Play tested using Chrome on MacOS Mojave.
    Delightful quick-shot game. Performed well without any glitches, with a fun visual style. The difficulty is somewhat unforgiving at first, but encourages the upgrade system to advance to the next tiers of gunfights.
    Nice job taking a simplistic concept and creating an absorbing game from it.
  4. Like
    ShrewdPixel got a reaction from b10b in Password-less login mechanism   
    I might still be learning some of the canvas libraries, but this stuff is my bread and butter.
    I would seriously caution any devs from designing their own authentication system, even if they are quite knowledgeable on the subject, for a simple reason: even large companies get hacked all the time and they have TONS of resources and dedicated personnel to work on these problems. The only reason smaller startups or freelancers get away with it in the short term is through "Security through obscurity", in other words they are too small to show up on the hacker radar or just haven't made any real enemies yet.  ---- OK, enough warnings and on to the info.
    While what you are planning isn't that bad of an idea, (here's a link to a web service that does just that.) before building your own I'd read up on User Enumeration and Session fixation attacks as well as reading up on answers to this question at security.stackexchange.com (link to this very question being answered here and as well here). The TL;DR for that is that you are introducing a single point of failure, and there are several different ways to exploit it that you probably have not thought of yet.
    It's for this main reason I use other web services for my logins; they have more resources to work out all of the possibilities -- also, if they DO get hacked it's on them and not me or my client.
    It's true that Omni-Auth, which is the "sign-in by third party" mechanism I use, is most popular for signing in with Google or Facebook; but it can actually use MANY different options (See list here). While in the past I've been too busy to add more than Facebook or Google for my own sites, on my next project I'll be adding Twitter, Github, LinkedIn, Instagram, and StackExchange. (If one of those doesn't work for the user or dev, there's still a lot of options.) Most notably, it's still the most secure option available for protecting users and devs.
    I also highly recommend watching Tom Scott's (Computerphile) videos on Youtube for overviews on "Why to never take passwords" and a few others on things like "SQL injection attacks" to get a better overall idea of what exploits can be used against a site and it's users. Watching just the exploits demonstrated on that channel should be enough to scare the hell out of anyone thinking of making their own (or bypassing an) authentication system.
    In summary, while yes you can very well do it, it's almost certainly a bad idea unless you've done a ton of research and thought through every potential possibility. But if it's for a very small site that really doesn't need much security, you can probably get away with it. Just keep in mind that if your site/game does get really successful or gains a huge user base, you'll be scrambling to replace it with something more robust and your users may not react well to the change.
    I certainly hope I've at least provided some useful information on this topic. Good Luck!
  5. Thanks
    ShrewdPixel got a reaction from onlineindiangames in Sheep Farm - HTML5   
    Greetings! Play tested using Chrome on MacOS Mojave.
    Pretty graphics on a resource gathering play styled game. While the game is a bit simple, it has music and a congruent graphics style that would appeal to casual gamers. It runs with a solid frame rate and didn't appear to have any bugs that I noticed.
    Good Luck!
  6. Like
    ShrewdPixel got a reaction from vornay in logic bombs for pirates   
    Unfortunately, such measures could easily be disabled by searching through the code for the functions and disabling them. Even with minimization and obfuscations (like Uglifier for Javascript, which I would still use) it wouldn't be very difficult to scan for such options, because the text strings would still show up as plain text in the code.
    The best method I've been able to come up with, after tons of research and years of testing, is to not expose your complete dataset with the use of a database. If you have all of your code in one, easy to copy file it's trivial to copy and pirate. But if your code loads incrementally from a database that is secured with a login and is dolled out as players progress through the game, or it loads variables/values from the database at certain points the attacker would basically have to build the game themselves incrementally. (Not impossible but it would make you a very impracticable target and less likely to be victimized.) 
    Login solutions like Omni-Auth (signing in with Facebook, Google, Github - see link here) can allow you to let users log in without having to make an account. (Link to one of my apps that does that here) You could still provide a demo with limited progress to casual visitors who wanted to try out the game, but require them to sign in to play further.
    This is one of the primary reasons I'm porting the pixi.js library to gems that can be used with RubyOnRails, (See post here) to provide a method of easy database integration for developers who want to protect their games. (There are others, but RoR is very easy to learn for simple apps.)
    I hope that helps shed some light on the situation and helps provide solutions. Good Luck!
  7. Like
    ShrewdPixel reacted to themoonrat in I'm creating Ruby Gems for Pixi.js   
    Good luck! Don't use ruby at all, but it'll be great seeing the results of all your hard work
  8. Like
    ShrewdPixel reacted to themoonrat in What is the benefit of using 'resolution' property?   
    Imagine you create a game at 1920x1080, which runs fine on most devices, but you have some older ones you want to support that aren't performing up to scratch and never will. Ok, well, set the resolution to 0.5, which can also trigger the loader to use @0.5 textures you have provided, and very quickly you have something that can run on lower performing devices. And then you're game gets picked up and you're going to a show to put your game on a big screen. Set the resolution to 2, which can also trigger the loader to use @2 assets provided, and you now have a 4k native resolution game with minimum fuss.
    It's also possible, with a small amount of hackery, to change this resolution property dynamically on the renderer. A lot of video games do that these these days ... they have a target resolution, but will lower it if performance starts to suffer to get the fps back up. And once the fps comes up and is stable, it'll raise the resolution back to it's target again.
  9. Like
    ShrewdPixel reacted to ivan.popelyshev in Problem with pixi rope and texture packer spritesheet.   
    Its not a bad practice, its about whether or not you know what webgl operations are actually happening. Some fields/properties in pixi can be used only if you know underlying WebGL mechanics. Sometimes you can inject different shader that works better for atlas textures, but lacks batching. Sometimes you can make shader with batching, like in pixi-heaven or pixi-projection.
    So, you have to know
    1. Pixi stage
    2. WebGL operations
    3. pixi internal architecture.
    Stage and basic things are available through the docs, but 2-3 can be learned only from source code and WebGL manuals. Of course you can look in this forum and in pixijs issues for a single problem, but I can't answer big questions like this one if a developer see the big picture: 
    In the end, its all about BALANCING different penalties. If you dont have proficiency with atlas to solve small issues like "extrude colors for rope", dont use atlas for rope, change your pipeline.
    It will take minimum a year for me to make articles and examples on everything i know about pixi and WebGL , and because I'm still developing plugins on pixi, it will require a year more.
    PixiJS team released 5.0.0-rc today: https://github.com/pixijs/pixi.js/releases/tag/v5.0.0-rc , but there are no examples of new features, it will take another year. Unfortunately we dont have strong team of mathematicians that made Flash  Instead, developers who use pixi and need its extra features have to learn everything by source code.
  10. Like
    ShrewdPixel got a reaction from khleug35 in I'm creating Ruby Gems for Pixi.js   
    Greetings!      TL;DR - Links to pixi.js Rails gem at the bottom, with more to come.
    I'm a big fan of RubyOnRails as an application framework for a lot of reasons; It has several easy to integrate database options, it now has ActionCable for built in web-sockets, it's stupid fast for developing websites/applications, and it can easily(relatively) be deployed to Digital Ocean on the cheap using dokku.
    I've already been using it to deploy games like the one I have on display in the game showcase (Loyal Online - link to post) when building HTML5 games from scratch without any frameworks. But it's been slow enough going that I've had to upgrade my approach and start learning frameworks/engines like pixi.js.  (Which I already love and am building a new one now.)
    So to speed up and simplify using Rails to make HTML5 games, I've started porting pixi.js to gems that can be easily included in any Rails app. I've already gotten the main library file ported and is now featured in the rubygems.org library. (So it can now just be included in the gemfile of any Rails app and quickly be bundled in.) I'll also be setting up individual gems for the other optional components like projection, filters, sound etc. keeping with the modular nature of Rails. I'll update this thread as I get them setup and tested.
    I know Ruby On Rails hasn't been considered a very viable option for making gaming apps in the past, but I'll be changing that this week.
    https://rubygems.org/gems/pixi_js
    https://github.com/Palmweaver/pixi_js
  11. Like
    ShrewdPixel got a reaction from dekman in [WIP] Zombie Outbreak Arena   
    Play tested using Chrome on MacOS Mojave.
    Top-down Zombie blasting action. Nice.
    Kinda reminded me of both Smash TV(arcade classic) with a touch of the GTA2 aesthetic, but of course with the horror movie theme and the lighting engine. The fact that the enemy zombies cast shadows with the map being briefly illuminated by explosions and lightning helps a lot to deliver the panicked feel of the game.
    From a technical point of view, I haven't seen any games before made with the Construct 2 engine before (I had to look it up - seems almost like Unity for browser games) so all I can say is that it ran with a solid frame-rate and didn't seem buggy. It pretty much held at 60fps with only momentary drops to 55-59 during major lighting changes like lighting, explosions or switches to night-vision.
    As for overall feedback, I'd keep it dark and with the shadows - it adds a lot to the horror feel. The appearance of NPC's add a lot to the gameplay, and seems to suggest it could do well with a multiplayer addition/option. For upgrades, it may be better to have them automatically added, since as the difficulty ramps up over time, I can see having to decide what to upgrade getting players frustratingly killed while choosing.
    I agree it could use some music for the soundtrack, so I've compiled a list of resources you could use to save you some time there. (It would be great to get several, actually, since that would add a lot more flavor to the game if it wasn't always the same track.)
    Here's some resources on the web for getting audio tracks for your game, that have open-source or royalty free licensing:
    http://dig.ccmixter.org/free (LOTS of songs that only need attribution licensing)
    https://freesound.org/browse/ (Simpler beats, that go well for loops)
    https://lifehacker.com/these-1923-copyrighted-works-enter-the-public-domain-in-1825241296 (If you want get really creative and vintage, basically anything written before 1923 is open domain now)
    https://v-play.net/game-resources/free-music-for-games (And finally a whole page of links to similar resources)
    I hope the feedback and links are helpful, and most all Good Luck. It's a fun game.
  12. Like
    ShrewdPixel got a reaction from gafami in [Phaser3][Casual Game]: Throw Apple   
    Greetings! Play tested using Chrome on MacOS Mojave and iPad Pro (12.9-inch 2nd generation) 12.1
    I made it through all 10 stages since I like throwing knives at things in general. It's a simple, casual app that's good for a quick diversion. It could use more additions to hold player attention for longer play times. I'd double check your advertisers mechanics for iOS devices, since it has popups on the iPad for system updates that aren't from Apple.
    I'd also suggest a music soundtrack to add flavor to the game. Since I just left a similar suggestion to another post, I'll paste in the resources I provided here as well:
    Here's some resources on the web for getting audio tracks for your game, that have open-source or royalty free licensing:
    http://dig.ccmixter.org/free (LOTS of songs that only need attribution licensing)
    https://freesound.org/browse/ (Simpler beats, that go well for loops)
    https://lifehacker.com/these-1923-copyrighted-works-enter-the-public-domain-in-1825241296 (If you want get really creative and vintage, basically anything written before 1923 is open domain now)
    https://v-play.net/game-resources/free-music-for-games (And finally a whole page of links to similar resources)
    Good Luck!
  13. Like
    ShrewdPixel got a reaction from Wolfsbane in [Panda2]Make 10! - A card game for Android.   
    Greetings! Tested on Android 7.1.1 using a Moto E
    I've left a good review on Google Play saying "Nice, casual solitaire game with a twist"
    The app performed well and was enjoyable to play. It's kind of a toss-up on Crosswalk - yes the additional file size may be off-putting to some, but folks with older devices tend to have fewer choices on the Play-Store that are compatible, so it may be worth it. I believe the Play-Store has options for having different versions of the App for separate Android versions, so you may be able to have Crosswalk only apply to Android 4.x, and have a smaller version apply to newer versions of Android.
    Most of all, congrats on getting your game on to the Play-Store; it's a very unforgiving platform. Good Luck!
  14. Like
    ShrewdPixel got a reaction from csklimowski in Dot Dungeons: A Procedural Pen-and-Paper Puzzler   
    Greetings! Play tested using Chrome on MacOS Mojave.
    This is a rare find; a very Original feeling game for HTML5 canvas. I only had a few minutes to try it out, and played through the first 2 worlds. But I must say, I think you are definitely on to something here, and I could easily see this becoming a hit on the mobile app or Facebook instant game scene.
    While not overly flashy (which is actually good for an intelligent puzzle game like this) it already has an addictively playful style to it. I would promote the hell out of this and get it on to a paying platform.
    Considering how many games I see that are just rehashes of old ideas, I applaud your originality. Good Work, indeed.
  15. Like
    ShrewdPixel reacted to Wolfsbane in WIP Loyal Online + example code   
    Maybe think about adding a guest login feature at least for a beta?
    (I don't have Facebook, and I try to limit what Uncle Google thinks of me.  )
  16. Like
    ShrewdPixel got a reaction from gafami in [Phaser3][Game Tactic][Laptop, Tablet, Phone]: War IOM   
    Greetings! Play tested with Chrome on MacOS Mojave.
    Cartoonishly chibi violence with a progression of difficulty and world map/shop. Overall a pretty fun experience that had a good frame-rate and didn't seem buggy. I thought it was going to be overly repetitive until the first boss (The giant green ogre) came out and wiped the ground with my forces. (I actually kinda liked that part.)
    From a technical standpoint, I liked how you've made the app dynamically resize with the size of the browser window (a detail often missed).
    For feedback, I would suggest toning down the music volume initially, because I usually wear headphones and found it to be a bit jarring when it kicked it. (Or just have an easily accessible volume control/slider). But I'd also add some sort of music or simple tune to the mini-map, because it seems almost too quiet by comparison when outside of the battles.
    I can tell that you've been adding more over time from the other feedback on this post, which is great to see. I think it has good potential if you keep adding more variety and progression to it. Good Luck!
  17. Like
    ShrewdPixel reacted to csklimowski in Dot Dungeons: A Procedural Pen-and-Paper Puzzler   
    Draw a route through each floor to capture the numbers within! Play through 30 hand-designed levels, or test your skills in an endless procedurally-generated dungeon! It's the weird, niche puzzle game you've always wanted.
    Play it here!
    This game started as a doodle in a notebook 2 years ago, and has finally come to life. This is the first game for which I've made the design, code, art, and music all by myself, and I'm elated with how well it turned out! I'm especially proud of the procedurally-generated levels, which are interesting and challenging even for me!
  18. Like
    ShrewdPixel got a reaction from khleug35 in [Panda2] Dead Gunner   
    Greetings! Play tested using Chrome on MacOS Mojave.
    I really do love retro-styled arcade/console games; this reminded me of both Contra and Metroid in some ways. While it could still use more additions to gameplay and interface, it definitely has a solid foundation  and runs quite well in the broswer.
    If you're looking for more inspiration as to what add, I'd suggest checking out the NES classic "Clash at Demonhead"; it has a similar foundation and from the looks of your code has many features the would seem to be inline with your design structure. But that's just a suggestion for ideas and inspiration.
    Very good game; Good Luck!
     
  19. Thanks
    ShrewdPixel got a reaction from 8Observer8 in Find empty position in map   
    Iterating over a list of entities and calculating whether you are within a certain range of them would be very expensive computationally if you did it with pure math calculations.
    So if you go that route, I'd do it with logic instead.
    For instance, you can define what radius you want to be the minimum by defining a constant, like:
    const personalSpace = 20; If it's a 2D radius, this would apply to both the x and y axis. Then you can use 4 true/false checks to see if there is any overlap:
    if ( !(localplayer.x - localplayer.personalSpace > otherPlayer.x + otherPlayer.personalSpace ||          localplayer.x + localplayer.personalSpace < otherPlayer.x - otherPlayer.personalSpace ||          localplayer.y - localplayer.personalSpace > otherPlayer.y + otherPlayer.personalSpace ||          localplayer.y + localplayer.personalSpace < otherPlayer.y - otherPlayer.personalSpace) )  {     spawnPlayer(); } else {     findNewSpawn(); }  
    The preceding Javascript snippet is basically saying this: Is it above it? Below it? To the Left of it? To the right of it? If it's any of those, then PersonalSpace doesn't overlap and we're good to go. Otherwise, if they all fail, then there is overlap of personal space and try again. The same concept works in 3D(Six true/false checks instead of 4).
    Using true/false logic is much less expensive on performance than pure math calculations, and should be used whenever possible to save processor cycles.
    I hope I've understood what you were going for and that my response is helpful. Good Luck with your game!
  20. Thanks
    ShrewdPixel got a reaction from 8Observer8 in How to make a multiplayer game   
    Designing Multiplayer games has a few general things in common, but much of how you will implement them will vary based upon which platform you use. Here a link to one of my favorite tutorials on the subject that goes as much into the theory as it does the technical walkthrough:
    http://www.schibsted.pl/blog/back-end/developing-lag-compensated-multiplayer-game-pt-1/
    Many tutorials over simplify by just saying "Make it a single player game then add multiplayer support later", which is usually NOT a good idea for most platforms; in the tutorial that I've linked to the writer goes over some of the pitfalls of that approach, pointing out that it's good to design and plan for multiplayer from the start.
    One of the largest challenges for most starting out is getting a good understanding of net-sockets so the clients can communicate, then understanding how to make them sync together. It's good to get a decent understanding of both of those conceptually and technically for your platform before becoming too invested in a large project.
    I'd also highly recommend this article by Gabriel Gametta on general theory of client-server architecture; it covers some of the history of multiplayer games and the concepts that were used as the industry advanced:
    http://www.gabrielgambetta.com/client-server-game-architecture.html
    I totally agree with what has already been said by others on this thread: Start Small. It's a lot easier to learn net-sockets and syncing clients for Pong than Ultima Online.
    Hope that helps, and most all Good Luck!
  21. Like
    ShrewdPixel got a reaction from mattstyles in Hosting recommendations ?   
    If you're on a super tight budget, you can't beat Heroku. (Free and tons of tutorials)
    If you have a good budget, Amazon Web Services. (Pricey, but tons of features and a fair amount of tutorials.)
    If you already know what you're doing and want cheap and fast performance, Digital Ocean. (Fairly cheap, but very few tutorials that aren't out date.)
    I use Digital Ocean, but I wouldn't recommend them for beginners because the learning curve is much steeper. (But I can run a fast gaming server on them for $5 a month).
    And there are others, but I'd say those 3 are the most popular. (And hence you would find the most online documentation for them.)
    Hope that helps!
  22. Like
    ShrewdPixel reacted to mattstyles in best way to convert ES6 syntax to ES5 ?   
    Oooo, this thread could get flamey! Ha ha.
    There are numerous advantages to using ES6, a quick google search will give you heaps of reasons, with the only con being that you probably have to up the complexity to transpile back to es5/3, however, all modern browsers support most of ES6 (and newer) syntax so unless you're supporting really old browsers (and you stick solely to ES6) then you probably don't need to transpile.
    The biggest advantages of ES6 (for me, and I've missed loads here):
    * ES6 was pushed through to create more complex applications, as such it has a lot of syntax that is more useful for doing so. Some are sugar methods only, some actually provide newer functionality (particularly those related to primitives and/or the DOM).
    * New built-in extensions which make many tasks way way easier (and easier means less error-prone)
    * Sugar methods mean less dev typing which generally means less mistakes. Some things ES6 makes easy are very very hard in ES5 and they are often things devs rely on regularly so making them easier to work with means writing code is less error-prone and reading code is clearer so you can focus on what your code does, not how it does it.
    The biggest advantages of setting up a transpilation pipeline are (again, I'm missing loads):
    * Access to a module system
    * Access to whatever new syntax you want
    The con of a transpilation system is increased project complexity and you have introduced a build step which takes some time to run, as your project grows this sometimes becomes prohibitive but you do have to have a very large project for this to happen and most modern build tools abstract away incremental builds and caching i.e. they only re-build the changes so incremental builds become smaller and faster.
    Another con is related to the module system. Modules are awesome, very awesome. However, JS doesn't (yet) natively support them in the browser and even when they do there are additional problems i.e. if you use modules heavily (as you probably should) then your list of dependencies could easily be hundreds or even thousands of files, loading each of these one by one in the browser isn't a good idea and won't be in the foreseeable future.
    A module system also implies that you need some way of getting dependencies. This isn't technically necessary but is often helpful. If you are writing games then often you'll be using one (or maybe two) large frameworks to help, unless they work nicely with a dependency management system (i.e. NPM) then I wouldn't worry about getting them as 'real' modules, just include them on the page and use them, then use a module system for your own code if you want to.
    Newer syntax and mobile games
    Any gaming is typical performance sensitive, newer syntax has a few things to consider:
    * Browsers are well optimised for ES5, this isn't always true to ES6 (although ES6 is pretty good now as its fairly old and almost universally adopted in browsers)
    * Given the above, transpiling is often better for performance
    * The code generated by these tools during transpilation is superb, it is written by many many superb developers and has great community support so the hours invested in it must be astronomical i.e. in many cases these tools will write better code than you or I do!
    * It is not a silver bullet -> if perf is a concern for you then you are still largely the sole arbiter of whether you achieve your perf goals.
    How to use newer language features:
    Babel is the defacto tool (although it isn't your only option). Babel requires a bit of setup work and additionally requires you to set up a build process for your code. Again, there is tooling for this. Additionally, there are many project scaffolds out there (and tools for creating them) that can abstract this away.
    The absolute easiest way of getting access to these new language features but supporting older browsers is to use parceljs.
    Parcel abstracts away most of the complicated build stuff and has a superb feature set. It involves a few pre-requisites:
    * You must know how to run simple commands from the command line
    * You must have Node and NPM installed
    Once you have these things (which is generally true of any JS build system you might want to employ) then running builds is a simple one-line command. A watch task is also bundled in, this is another simple one-line command to run and watches the file system, every time you save a change it rebuilds only what has changed and propagates that to the browser. Parcel relies heavily on caching and multi-threading so is very very fast.
    Other tools include webpack (which is very complicated, although newer versions I think make things way way easier for most use-cases) and browserify (which is simpler in scope, but can feel a little low-level for many people).
  23. Like
    ShrewdPixel got a reaction from 8Observer8 in Christmas Breakout (classic Breakout with an xmas theme)   
    Great going making what appears to be one of your first games! Play tested using Chrome on MacOS Mojave.
    After looking over the responses to the post and playing the game for a bit, there's not a lot for me to add. But one thing I can definitely recommend from making a breakout style game myself is adding directional aim with the paddle. (Basically, adding code so that if the ball hits the center of the paddle it goes straight up, but if it hits the sides of the paddle it goes flying off at the angle it's on, allowing the player to aim their shots with it.) It cannot be overstated how much this adds to the fun and strategy to the gameplay. 
    I've attached a screenshot that illustrates that a bit. (FYI, it's from the book Hands-On Intro to Game Programming). Also, here's a code snippet from when I last made a breakout game to illustrate how to write such a function:
    function paddleHitsBall() { // Handle the paddle sending the ball away after a bounce
        ballSpeedVertical *= -1; // Send the ball back upwards at the same speed
        var centerOfPaddleHorizontal = paddleHorizontal + PADDLE_WIDTH/2; // compute what the center of the player paddle is
        var ballDistFromPaddleCenter = ballHorizontal - centerOfPaddleHorizontal; // compute the distance from center the ball hit the paddle
        ballSpeedHorizontal = ballDistFromPaddleCenter * 0.25; // Left/Right speed of ball is determined by distance from center with 1/4 modifier
      }
    Basically, you measure where the center of the paddle is, and base the horizontal speed on how far the ball hit from that center.
    I hope that feedback helps with your progress, and most all Good Luck!

  24. Thanks
    ShrewdPixel got a reaction from 8Observer8 in Zombie Strike   
    By "consistent frame rate" I was just making a visual observation during gameplay that the game did not stutter or pause during the actual gameplay while I was testing it.
     
    More broadly, those terms can be also refer how your game logic is setup. HTML5 canvas can be very finicky about how your code execution is ordered. 
    Looking at the code that you've linked to, requestAnimationFrame is called at the beginning of the runLoop function, which is great since otherwise the browser may have to wait for the next execution to render the frame. (I've seen people do opposite, putting it at the bottom of their function, and that will badly affect performance in all browsers.)
    It's also a good idea to put all of your draw calls (your this.draw function) right after requestAnimationFrame, because otherwise if the browser gets bogged down it may have to wait until after the input or game logic for the next frame, resulting in dropped frames and lowered performance.
    Finally, if you can keep most of the other functionality (input, enemy AI, garbage collection) out of the render loop and possibly in another execution loop (like a web worker) this can have massive performance gains, since once again the browser doesn't get stuck waiting for a frame to be available. (Most libraries like pixi and phaser do this already, and it took me while to get good at that.)
    While this may not be noticeable on a fast desktop computer, these sort of tweaks have huge effects on mobile platforms like Android and iOS where the processing power and browser optimization are more scarce.
    For example, (see screenshot) just moving your call to this.draw to be right after the requestAnimationFrame in your main loop will probably gain you a boost of several frames per second on mobile devices. 
     
    I only had a coupIe minutes to read your post and look at the code; I hope I was able to understand what you were needing, and I hope even more that what I said is of any help to you. Good Luck!

  25. Thanks
    ShrewdPixel got a reaction from Riddik in Zombie Strike   
    Greetings!
    Play tested using Chrome on MacOS Mojave.
    Nice game; it has good graphics, consistent frame rate and addictive gameplay. Based upon the feedback you've already received in this thread, my best suggestion would be the addition of other themes to either individual level or player selectable; it wouldn't affect the gameplay(and as such wouldn't take a lot of code to add) but would add a lot more visual variety to the game.
    The design looks pretty solid; Good Luck!