Rushino's Recent Forum Activity

  • Nevermind, look like its my lack of knowledge in the array object. To have initially zero element you must set..

    width: 0

    height: 1

    depth: 1

    if you set all zero everywhere, it won't add anything to the array.. which make sense since there no height or depth. At least you need 1 height and 1 depth to represent a 1D array.

  • Hi,

    I was playing with the array and poping an item in an array increase the number of element of that array..it is normal ?

    I mean once i poped it, it should have removed it not adding element to it. The element is empty.. but it is still added.

    But i have a guess which is probably the size of the array that incrementing. Is there a way to avoid this ? even reducing the array size after the pop doesn't work.

    Thanks!

  • Offcourse i am not talking about UI logic or anything like that. However i would be interestes to know which kind of logic you have on mind.

  • No theses things are problems in html 5 games and even normal games on desktop in general. If someone have access to game client logic you must take into consideration it can be altered. The only way to counter this is to put all the logic on the server there no other ways. You will probably (depending how you coded it on the client.. either by refreshing the stats regulary or whatever) end up with your scenario at some through where the dude that altered it get into a false sense of winning cause all he did is teleported himself to x y pos. But the server alway know the truth, he know that the player are not at this position because of server game state logic. So wht happen if he execute a move based on wrong origin coords ? Well at this point its up to you.. you can kick him for having sent bad data once you validate it. But in the end you wouldnt really care since you know its secure ans cant change the game state.

  • Ok, i wish to take some minutes to present my upcoming project which are about to take advantage of WebSockets technologies. Its called Skirmish Commanders! I moved this from another engine to Construct 2 for technicals and productive reasons.

    Its gonna be a commercial online turn-by-turn tactical drones game which mixing aspects of several games such Pokemon (Varieties), EVE Online (Customization), Final Fantasy Tactics (Kind of game) and Front Mission (Combat deep details).

    This is rather huge i know, but i am pretty sure that Construct 2 will be a lots of help here comparing to what i was using before. This game gonna be fully HTML 5 with a Desktop version! A kickstarter is planned cause i really believe i can't finish it without poeple help and there are many things that still need to be developped. The server-side is ready just need to put logic in. I worked 1 year on a solution using WebSockets and came to a point where i am pretty confident it will work.

    The game will have interesting combat features like ability to target drone subsystems, etc drones will have balanced stats the idea is to try to make a drone unique and even if its bigger than another drone that won't meant its better or more powerful. At some point you will be able to customize the stats or adding abilities to the drones via pluggable modules. There will be high level of complexity when it come to stats of the drones such precision, energy, module slots, rate of fire, weapon type, etc.

    Then i plan to enable 2vs2 battles in the futur and different game modes.

    Have a look at the devblog : pyroswarm.com/devblog

    ** Please note all the content on the blog are copyrighted to me.

    Thanks for your interest! :)

  • Alright! Thanks!

  • ramones this fixed it! it make sense actually i wanted to take each button one by one to apply this logic so.

    Thanks a lots!

  • I use the default mouse button for this. I check if its over id not i set the active/over state off which is what the events are showing. Mouse is definiticly over one of the instance but the second button should not show the over state when i am not on it.

  • Does the event 'mouse cursor on object' actually pick the instance ? because i have some kind of nasty bug that happen when i am over an object and then switching to another instance of the object pretty near.. it make it look like its still on the first object..

    Here the strange behavior..

    <img src="http://s12.postimg.org/zajodc0jx/nastybug.png" border="0" />

    Here my events..

    <img src="http://s18.postimg.org/dlmrdhnvd/bug.png" border="0" />

    Any ideas ? Normally the event Cursor is over 'Button' should pick the correct instance.

    Thanks!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hello,

    Just wondering... i was currently (probably making a mistake) cloning objects.. such txtUsername or txtPassword for my textfields.. but i think it doesn't work that way.. i could just make Textfield and use different instances.

    So it is better to use different instances of one object or use many objects of the same kind ?

    What the kind of impact on performance for the both methods ?

    Thanks!

  • Hello,

    It is normal that the text in the editor have antialiasing and the same text at runtime have no antialiasing even if WebGL is on and Sampling is Linear ?

    See what i mean...

    <img src="http://s24.postimg.org/haci06i1x/antialiasing.png" border="0" />

    Thanks!

  • You could use animation frame to do this mixed with instance variable. Add a variable which is called "NumberOfItems" so if you push + you increate this number and if you push - you decrease it. Then, depending on the number you show the exact frame number relative to this number.

    This would work if you have a max number of items to be stackable.

    However, if you really need a new object. Then still use instance variables.. if your object have NumberOfItems lets say 2 then the next object created Y position will be Object.Height * NumberOfItems (because you already have 2 objects, if your object height is 10 then the result will be 20) + Object.Height (because the base coordinates are top-left, you haveto include the object height you want to add, so now the result will be 30 for the Y position).

    This formulea doesn't take spacing between objects into consideration but this could easily be added.

Rushino's avatar

Rushino

Member since 15 Sep, 2013

None one is following Rushino yet!

Connect with Rushino

Trophy Case

  • 11-Year Club
  • x2
    Coach One of your tutorials has over 1,000 readers
  • RTFM Read the fabulous manual
  • Email Verified

Progress

14/44
How to earn trophies