gumshoe2029's Forum Posts

  • We are using "Scale outer" for "Fullscreen in browser" mode, which makes enormous differences in where the "edges" of the screen are relative to the internal coordinate system in Construct.

    I have found this to work fairly reliably across different modes:

    CanvasToLayerY("backdrop",0,0)  // top of screen
    CanvasToLayerY("backdrop", WindowWidth, WindowHeight)  // bottom of screen
    CanvasToLayerX("backdrop",WindowWidth, WindowHeight)  // right side of screen
    CanvasToLayerX("backdrop",0,0)  // left side of screen
    [/code:1x97qc0t]
    I use these to make my user interfaces in Construct fully dynamic (i.e. if the user resizes the window, Construct will automatically resize everything inside).
    
    Note: "backdrop" is my primary display layer's name.
  • You could just have the app list displayed as a JSON string then import it into your Construct app?

  • What plugin? Your question is kind of vague.

  • You have to include all three dimensions when working with C2-array JSON strings. You were missing the last dimension in your original string. It was included in korbaach 's string.

  • And it doesn't have a byte parser built in? Perhaps you could modify that plugin and add that functionality to it.

    I have modified a few of Rex's plugins. It is FAR easier to modify plugins than to write new ones.

  • I could, but it would be a lot of work. I haven't become really competent with the IDE myself. I mostly work on the server side in Java.

    How did you come about receiving a byte array to begin with?

  • I had to write a Java object to convert from Java arrays into Construct-friendly JSON.

    This is my half-way solution (it only converts to a one-dimensional Width-based C2 array):

    public class C2 {
    	//-------------------------------------------------------------------------------------------------------------------
    	// Method to output Construct-compatible JSON Array structures
    	//-------------------------------------------------------------------------------------------------------------------
    	public static String outputToC2Array(ArrayList<String> list){
    		
    		StringBuilder sb = new StringBuilder("");
    		try{
    			if(list!=null && list.size()>0){
    				sb.append("{\\\"c2array\\\":true,\\\"size\\\":[" + list.size() + ",1,1],\\\"data\\\":[");
    				
    				for(int i=0 ; i < list.size() ; i++){
    					sb.append("[[" + list.get(i) + "]]");
    					if(i < list.size() - 1) sb.append(","); //skips the last comma
    				}				
    				sb.append("]}");
    			}
    			return sb.toString().replaceAll("\\\\\"", "\"");
    		} finally {
    			sb = null;
    		}
    	}
    	//-------------------------------------------------------------------------------------------------------------------
    	// Method to reconstruct arrays from Construct-compatible JSON strings
    	//-------------------------------------------------------------------------------------------------------------------
    	public static ArrayList<String> arrayFromC2jsonString(String c2json){
    		ArrayList<String> returnList = new ArrayList<String>();
    		try{
    			if(c2json.contains("data\":")){
    				String subS = c2json.substring(c2json.indexOf("data\":", 0)+9, c2json.length()-4);
    				String[] pieces = subS.split("\\]\\],\[\[");
    				for(String piece : pieces){
    					returnList.add(piece);
    				}
    			}
    			return returnList;
    		}finally{
    			returnList = null;
    		}
    	}
    }
    [/code:cwm5su9d]
    
    Basically, I just parse the array into a C2-friendly JSON string.
  • It was at the top?! I never look at dates. :-p

  • What does "catched" mean in your context? Sorry, I make assumptions in order to draw meaning from missing information.

  • I had issues with data.js also, because it is not tied to the "/images" or "/resources" file directories in Construct. I had to put a copy of it on my webserver root, which means that it is open to manipulation by anyone who manages to hack our gateway Apache.

    Actually, I should try and produce a specific proxy for that file...

    I am going to assume that you have some manner of proxy setup which you do not have configured properly?

  • Your question is extremely vague.

  • There are a lot of other 3D game development suites out there already. It is part of the charm of Construct.

    You could make 'faux' 3D using isometrics and clever layering controls.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • A simple if manSprite collides or overlaps with floorSprite doesn't work?

  • Make sure you use PreparedStatements, please!

    Don't end up like this: