Tag Info

New answers tagged

0

Do it with a SPA framework. Like Backbone.js Then you can make it so that your whole frontend has 0 page reloads. http://backbonejs.org/ You should make it so that your PHP backend is RESTful. Maybe with Slim.php http://www.slimframework.com/


2

Your approach is unfortunately not framerate independent. You correctly notice the need to factor in the amount of time passed between each update in your physics calculations. However, you still specify the amount of time passed in units of frames. If your framerate changes, now your speeds have all changed with respect to the passing of real time. What you ...


0

I've edited your example, you can now rotate using the keys, it uses CSS3 rotations. If you want to move more fluid, you can either update the move() faster, or add some easing animations. You can still make several improvements, but here is one solution: http://codepen.io/anon/pen/jPraGK The css rotation code: $("#block_green").css({'-webkit-transform' ...


0

If you are trying to use tile dimensions to break up the fact that its a tiled game, you should check out Wang tiling. Its a really nice way to make tiled graphics that looks organic and non tiled. http://blog.demofox.org/2014/08/13/wang-tiling/


0

If you are doing webgl and can make pixel shaders, check out signed distance textures. They are textures but scale like vector graphics. http://blog.demofox.org/2014/06/30/distance-field-textures/


3

Your LevelCollider is attached to a Collider that is a trigger. That means it will not call OnCollisionEnter. It will call OnTriggerEnter. Try adding this to LevelCollider: void OnTriggerEnter(Collider other) { Application.LoadLevel("Level1"); } That should do ya!


2

Detect collisions with OnCollisionEnter then load your level there. I.e.: void OnCollisionEnter (Collision col) { Application.LoadLevel("Level1"); } If your character's Collider is a trigger, then you need to use OnTriggerEnter. I.e.: void OnTriggerEnter (Collider other) { Application.LoadLevel("Level1"); } If neither of these work, try ...


0

You have to cast it to ClientValues type. var cSharpScript = (ClientValues)gObject2.GetComponent("Clientvalues"); or var cSharpScript = gObject2.GetComponent("Clientvalues") as ClientValues; First one causes runtime error if cast fails and the second one returns null if it fails. Important difference. But both should do the trick.


2

Clearing the screen is only one half of the puzzle. I'm going to bet you also only re-draw the rectangles if/when they move. To confirm, you could make the red cube continue to move across the screen, I would expect there to be no graphical glitches. The solution: Draw everything (on screen) every frame. There are fancier ways to deal with this, but they ...


0

Hope this may help : (from Physics.Raycast docu) Notes: Raycasts will not detect colliders for which the raycast origin is inside the collider. If you move colliders from scripting or by animation, there needs to be at least one FixedUpdate executed so that the physics library can update it's data structures, before a Raycast will hit the collider at it's ...


0

There are objects in Construct 2 which offer some specific API features of the services/OSs you can deploy. These objects can be added to your project. if your question is about using HTML5/JS scripts in C2, take a look at: https://www.scirra.com/forum/extending-construct-2_f150?sid=04080f153f8f7940445939647640abd7


0

You can add a box collider (Add -> Physics -> Box Collider) in the inspector. Then, add a script with a function OnCollisionEnter(Collision other) then add that script to the cube you want to collide with. More info in here: https://unity3d.com/learn/tutorials/modules/beginner/physics/colliders-as-triggers


0

The command to load a level is Application.LoadLevel(). Call that from an "On Collision" function on the cube.


-1

I found the answer : the .jpg image was to hi-res, I just had to reduce it.


0

try opening a new thread like in this video tut and use that for your connections. https://www.youtube.com/watch?v=6G_W54zuadg there may be some useful info in this video hope it helps



Top 50 recent answers are included