rfisher's Forum Posts

  • I got a maze type game that displays about 900 physics sprites and when i change the origin of the sprite the performance drops from about 55 fps to about 30 fps in IE9. Unchanged in Chrome. Anybody have an idea of why this happens?

  • I'm getting 26-29 FPS with IE9 and about 20 FPS with Chrome.

  • Thanks for the info. I was concerned since there are alot of physic sprites on the layout. The maze is created using a plugin i made implementing the Recursive backtracker algorithm. Which means there are alot of sprites created on the layout and its known that when you have alot of physic sprites your performance decreases.

  • I have made a maze type game. Right now there is not much to the game, you can just use the arrow keys to navigate through the maze. I'm really interested in the FPS you get, its shown in the upper right corner.

    Maze Game

  • Ashley

    I tried

    var width = obj.width;

    var height = obj.height;

    and i got a assertion failure. I think i'm still not doing something wrong.

    I just figured it out.

    var width = obj.instances[0].width;

    var height = obj.instances[0].height;

    THANK YOU!!!

  • I'm making a plugin and in the edittime.js i'm using AddObjectParam to add a object to my action. Then in runtime.js in the action function i would like to be get the object width and height. I could only fine the following method as a reference.

    var inst = this.runtime.createInstance(obj, layer,parseInt(temp[0]),parseInt(temp[1]));
    var width = inst.width;
    var height = inst.height;

    I would like to not have to create a instance of the object to just get the width and height.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Its now working in r91. I just removed a unused code left over from the example.

  • Thank you for the information, but To try and fix what is not broke in r90 which is broke in r91 is beyond me. I need some kind of feedback to let me know whats wrong.

  • Kyatric

    Well i did fix my plugin so that no more errors happen when using r91. No errors did occur with r90 otherwise i would have never posted about it. So just to fix the problems, i installed r91 on a different computer and when i run my test capx the result is not the same as with r90. So what i mean is, the plugin works with r90 correctly and with r91 is doesn't work correctly.

    Its a simple example that displays a number on the screen. With r90 it displays "200". With r91 is displays "0".

  • Kyatric

    Well I installed r91 on another computer and checked out my plugin and fixed all the problems and now it doesn't work like it did before. On r90 it still works. I'm only interested to know whats wrong and what i have to change as a learning experience.

  • I didn't get a error with r90 and if all i got to do is add the variable "a" it will be easily fixed.

    I also didn't know about "tokenat" or i would have not made the plugin. It was a good learning experience.

    I did ask how to do this a couple of days ago - http://www.scirra.com/forum/place-100-sprites-with-plugin_topic52422.html If i just would have read Mipey's second sentence i would have known what to do days ago.

    I didn't use ARRAY because i didn't understand how to use it and load data into it in a easy way. Although i have no trouble using arrays in PHP & C.

  • I have made my first plugin for Construct 2 and it is used to parse a comma delimited string full of numbers. You set the string like "100,200,300,400" and access each number by referencing its index. Like if you want 200, this index would be 1.

    I'm using it so that i can place alot of the same sprite all over the layout in a easy way.

    my string is like "x1,y1,x2,y2,x3,y3" and then i reference each variable to place the sprite.

    parse plugin

    parse example capx

  • rexrainbow

    I'm having trouble with this plugin. I have made a very simple capx and it work perfectly. Then i put the same code in a already made game and it doesn't work.

    When i say it doesn't work, i mean that 4 instances of the sprite are created at cordinates in the table when it works and all of them at 0,0 when it doesn't.

    <img src="http://www.ishopcart.com/e1.jpg" border="0" />

  • I have it working now, I was not using Col and Row Headers which is how you index to a value.

  • rexrainbow

    Well after playing around for about a hour i still don't know how to use the CSV plugin. I created a CSV file with Excel and then copied the contents to "load table" forom the CSV plugin. I then tried to access the table by using CSV.At(0,0) which did not work. I then tried CSV.At(str(0),str(0)) which only returned 0 and not the value of 50 that was loaded there. I just don't understand, is there example CAPX to look at. I already looked at the text_csv capx examples which don't show what i'm looking for.