lennaert's Recent Forum Activity

  • Could you post a capx, UberDark, with your ajax request or a screenie of the events involving the ajax action.

    In my network tab on the Chrome console, my requests show up as POST methods.

  • To avoid physics, I would put the origin of the sprite on the hinge.

    And when hitting the door, make the door rotate 90 degrees in the direction the door needs to swing open.

    Kyatric

    It kind of resemble the layout in those snapshots, ........ posted nearly 2 years ago

  • Add pick all MainHand above the pick by evaluate.

    But, the mainhand is already involved in the collision,

    Shouldnt it then be:

    Mainhand on collision with hitbox

    Pick all peer

    pick peer where peer.peerid = mainhand.peerid

    or

    Mainhand on collision with hitbox

    Pick all peer

    pick peer where peer.peerid = hitbox.peerid

    depending on who is doing what

  • 1)

    Common

    On peer disconnect, Multiplayer.PeerID should reference the object(s)** to be destroyed.

    2)

    When a game starts and you have your own variables stored locally or from some ajax, you can simply set those values and relay them through the host with the other players. When a new player joins, it should request those values from the host.

    3)

    The current multiplayer mechanics are geared toward web based hosts and peers.

    The signalling server in the store is for a dedicated hosting of server that allows the connections between web hosts and peers, not a game host itself.

    For MMOs you could look into Ajax and PHP to centralize a player database.

    4)**

    As with point 1, you simply need to add references. Though you synch the peer object, with PeerID, you can pass that peer id to anything you create while creating the players assets.

    Player.peerid = 01A0

    Hitbox.peerid = 01A0

    Sword.peerid = 01A0

    Helmet.peerid = 01A0

    On peer disconnect

    Pick objects with peerid = 01A0 (Multiplayer.PeerID) and destroy.

    Voor PvP make them enter a room with max 2 players

  • Compare X

    Bullet.X > ViewportRight("Layer")

    destroy bullet

    Kyatric that looks pretty old already

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I am simply wondering why everything I do keeps showing up in the network view (shown below) as using GET even if both php and Construct2 are set to use POST.

    Perhaps calling the wrong function/Ajax call ?

    Some info

    GET method: This uses a method where the data is processed in the url. This leaves traces in various logs at different points between your connection over the http. Obviously, having passwords etc could be troublesome.

    POST method: leaves far less traces like the GET method.

    Difference, you can make simple links with the GET, like http://mysite/index.php?page=home

    Whereas POST methods require various FORM elements in web pages before being able to send stuff somewhere.

    Ajax takes care of the whole FORM formatting of your data request using POST.

    If you really want to protect your content, you should start by having a https capable server.

    By default, with https, your web connection will be encrypted and better protected.

    So your Ajax POST requests should point to files on your sever over https://yoursite/mypage.php

    You have control of what the user can enter, for instance, you could create a certain set of keys only to be allowed to enter, leaving out various mischievous characters.

    Next to that, you should encode manually entered content which are being passed

    You could use in construct 2

    URLEncode(str)

    URLDecode(str)

    Convert to and from a string in a format suitable for including in a URL or POST data.

    and in PHP you would use the base64_encode base64_decode counter part.

    mysql_real_escape_string is handy too; in PHP there are various options to strip certain undesired content from user input.

    When I have a user table in a game's database, I tend to generate md5 strings from the connection and browser information, gives me more in depth control of what to allow from a player.

    I would also try and add some flooding protection if the user is sending passwords to enter something, preventing brute force attempts.

  • You should place the objects in the HUD layer in the dotted rectangle at the top.

    This is expected behavior.

    like, place the spritefont in the top most level in that layout. ie points.X = 48, points.Y = 192 , and run it.

    The idea of the HUD layer is that you can use the space in the dotted square in the top left of the layout, and that objects placed here will remain in your viewport as the game runs.

  • Haha conceptually, it is something new and unique! So can't wait to see how they do it. Haha really want to know in what way the aliens are going to use video games to attack, hack all games? Or recreate all the game characters and attack earth.....or perhaps digitize the world into a gaming realm....or even make earth like GTA...(wait it already is :p). Haha now I am really interested in this movie!

    There is a small video preview (below the main image between the images) which even has the creator of pacman in it

    It looks pretty good graphically

  • header('Access-Control-Allow-Origin: *');

    You only need that one in the top of your PHP file.

    header('Access-Control-Allow-Methods: GET, PUT, POST, DELETE, OPTIONS');

    header('Access-Control-Max-Age: 1000');

    header('Access-Control-Allow-Headers: Content-Type, Authorization, X-Requested-With');

    Remove these.

    Remove all the request header stuff in your events.

    Also, try setting a text object's text with the Ajax.LastData instead and remove the check if not 0.

  • This caught my eye when nosing through the imdb this afternoon, I thought it was funny and figured I'd share

    When aliens misinterpret video feeds of classic arcade games as a declaration of war, they attack the Earth in the form of the video games.

lennaert's avatar

lennaert

Early Adopter

Member since 8 Oct, 2013

Twitter
lennaert has 13 followers

Connect with lennaert

Trophy Case

  • 11-Year Club
  • Forum Contributor Made 100 posts in the forums
  • Forum Patron Made 500 posts in the forums
  • Forum Hero Made 1,000 posts in the forums
  • x5
    Popular Game One of your games has over 1,000 players
  • Famous Game One of your games has over 10,000 players
  • x2
    Coach One of your tutorials has over 1,000 readers
  • Educator One of your tutorials has over 10,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • Enduring Visitor Visited Construct.net 90 days in a row
  • RTFM Read the fabulous manual
  • x2
    Great Comment One of your comments gets 3 upvotes
  • Delicious Comment One of your comments gets 10 upvotes
  • Email Verified

Progress

25/44
How to earn trophies