paulscottrobson's Forum Posts

  • The way I have done this is every tick, I check whether the cursor is in the right area or not. If it is, I store that in instance variables which are "last known good position". If it is not in the right area, I set the position from the last known good position. If you have a look at my centipede game (see URL below) this has exactly this - in Centipede (it's a 1980s arcade game) the player can move anywhere in about the bottom 1/4 or so of the screen - so things like layout constraints won't do. Though you can use a layout constraint for the other three sides, as it is only the upper boundary that is odd.

  • Probably not. For security reasons Javascript tends to limit access to various things, otherwise the web would be full of dodgy scripts which changed all sorts of things. Javascript is very sandboxed.

    I don't quite see why you'd want to. Your 5 JSON files are your games initial state, and your localstorage version is the current state of the game. Overwriting your original files sounds like a bad idea - supposing you wanted to restart the whole game, where would you get your original data from.

    More to the point, does it *matter* ? JSON files, even quite complicated ones, take up very little space compared to sound or graphics files.

  • Yes. I think C3 is more of a new *editor* than a new product per se, as I believe they are keeping much of the original runtime.

  • The only thing that's slightly difficult is the multiple hitboxes thing - I think C2 only has one collision rectangle. It is possible to work round this however.

  • Or you can bitwise and with 1 which extracts the 2^0 bit from a number. You sometimes have to be careful with modular arithmetic as negative numbers can be odd.

  • Probably not the objects per se that are the problem - do you have very big sound and music ? very hi res graphics ? The actual code part is not likely to be too large.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Is the array global ?

  • The best way is probably to have a global variable called "heroName" which is initially empty. In layout 1, only go to layout 2 if this is empty, otherwise go to layout 3. Obviously copy it in in layout2, and because it is global it is available to use in layout3.

  • Well.... that's a whole question in itself. It really depends how far down the line you want to go. Perhaps something like, for each character in the correct answer, find the nearest character in the typed answer, work out the character difference and probably raise it by a power 1.5 or something so further away scores increasingly worse. I'd remove all controls, punctuation and case before you test.

  • Tie them together. Every tick copy y from one to the other.

  • You can't (I think) put code in here, just specific values. What you want is <thingummy> OnCreated => set fx parameter (0) to floor(random(0,100)) and repeat for 2 and 3.

  • TWG is correct. They see C2 as a "lock in" technology. They want something they can either change themselves or find someone reasonably easily who could change it.

    I think they are wrong, personally. I suspect there are problems with C2 but they are related to documentation and application construction (put together in an adhoc fashion and not documented). I would have thought in terms of the overall cost a copy of C2 doesn't register.

  • If it is 64 bit, then there are 63 bits + sign bit. Given you can't back a 10 digit value into 3 bits this puts an upper bound on the number of digits at 21, and ByteMonkey's number is 24 digits long.

  • RPGs are often engines on engines. So there is a level of programming that does the graphics, interface etc. and built on top of that is a second level which controls the flow of the game itself.

    But basically, yes. C2 struggles a bit with complex object hierarchies and data structures, but it's not really designed for that sort of thing. Something like this may benefit from code in an app-specific plugin for example.

  • In C2 (I think !) events run sequentially, but triggers - collisions, keystrokes etc. fire on as needed basis. I don't know where these fire in the 'event processing' though - if they could fire in mid event then this might be whats causing your problem.