Quick Links: Download Gideros Studio | Gideros Documentation | Gideros community chat | DONATE
any demo code for lua socket — Gideros Forum

any demo code for lua socket

edited June 2012 in General questions
Hi everyone,
I found that gideros support luasocket but can not find a demo code to implement this.
So can you show some line of code to using this feature (Open socket and send some bytes to server)
And about websocket, is gideros support for websocket?
Thanks!
Coming soon
Tagged:

Comments

  • JaviJavi Member
    edited June 2012
    Add /All Plugins/LuaSocket/Source/socket.lua to your project.
    Now you can use sockets, example (download Google's robots.txt file using HTTP GET method):
    local socket = require("socket")
    client = socket.connect("google.com", 80)
    client:send("GET /robots.txt HTTP/1.0\r\n\r\n")
    while true do
      s, status, partial = client:receive(1024)
      print(s or partial)
      if status == "closed" then 
        break 
      end
    end
    client:close()
    You can also add and use FTP, SMTP, etc.

    Note: To use WebSocket you'll need to implement the WebSocket protocol using LuaSockets.
    http://www.whatwg.org/specs/web-socket-protocol/
    http://stackoverflow.com/questions/9347612/how-do-i-generate-a-websocket-handshake-from-lua
    +1 -1 (+3 / -0 )Share on Facebook
  • Thanks for your help, i feel very happy :x
    Coming soon
  • Ah one more question, how can i using socket to send byte arrays? :P
    Coming soon
  • JaviJavi Member
    Ah one more question, how can i using socket to send byte arrays? :P
    In my last post I gave you a basic example of how to do it; how to make a connection with a server, send and receive "byte arrays".
    Just use strings, in Lua a string is nothing more than an array of bytes. So if you need to send a table, for example, serialize it in a string.
    +1 -1 (+1 / -0 )Share on Facebook
  • Thanks Javi,
    Let me tell more detail about my purpose:


    I plan to communicate with Cubeia Firebase server:

    http://www.cubeia.org/index.php/component/content/article/1

    So in protocol i thinks it must truly send bytes data:

    https://docs.google.com/document/pub?id=1-FWLsdxkkvuf1zdvSCZINCkevHaVzkBC2F_WO2E1vpc#h.y0pg3rtwt1g1

    So can you show me some way to do this
    Thanks!
    Coming soon
  • JaviJavi Member
    Thanks Javi,
    Let me tell more detail about my purpose:


    I plan to communicate with Cubeia Firebase server:

    http://www.cubeia.org/index.php/component/content/article/1

    So in protocol i thinks it must truly send bytes data:

    https://docs.google.com/document/pub?id=1-FWLsdxkkvuf1zdvSCZINCkevHaVzkBC2F_WO2E1vpc#h.y0pg3rtwt1g1

    So can you show me some way to do this
    Thanks!
    You'll need to implement the Firebase protocol, it seems to be simple, based on packets [total_size_of_the_packet, type_id, arguments...] for each operation/request.

    To build the packets you'll need to serialize integers in big-endian format.
    Download and add to your project "numberlua.lua" to be able to perform bit-wise operations.
    https://github.com/davidm/lua-bit-numberlua

    Something like this should work:
    local bit32 = require "numberlua".bit32
     
    -- Integer 32 bit serialization (big-endian)
    function serializeInt32(value)
      local a = bit32.band(bit32.rshift(value, 24), 255)
      local b = bit32.band(bit32.rshift(value, 16), 255)
      local c = bit32.band(bit32.rshift(value, 8), 255)
      local d = bit32.band(value, 255)
     
      return string.char(a, b, c, d)
    end
     
     
    -- Base function to build Firebase packets
    function packet(body)
      local size = #body + 4
     
      return serializeInt32(size) .. body
    end
     
     
    -- Example, function to build VERSION packets (type_id = 0)
    function versionPacket(game_id, operator_id, protocol_version)
      local body = string.char(0) .. serializeInt32(game_id) .. serializeInt32(operator_id) .. serializeInt32(protocol_version)
     
      return packet(body)
    end
     
    -- More functions to create the rest of the packets, type_id=1, type_id=2...
    (...)
     
     
    -- <version_packet_str> is the packet serialized as a string
    local version_packet_str = versionPacket(123, 456, 1)
    (...)
    local response_packet_str = sendPacketToFirebaseServer(version_packet_str)
    (...)
    +1 -1 (+1 / -0 )Share on Facebook
  • Thanks Javi for very very detail help! :x
    Coming soon
  • JaviJavi Member
    You're welcome :)
    +1 -1 (+1 / -0 )Share on Facebook
  • Hi Javi,
    I'm implement protocol and in sendPacketToFirebaseServer, i try this:

    function sendPacketToFirebaseServer(version_packet_str)
    client = socket.connect("localhost", 4123)
    client:send(version_packet_str)
    while true do
    s, status, partial = client:receive(1024)
    print(s or partial)
    if status == "closed" then
    break
    end
    end
    client:close()
    return "done";
    end

    But the player become not response (Server work well)

    So can you show me the right way to receive server response?

    And can you please show me how to pack String argument?
    (example login request : https://docs.google.com/document/pub?id=1-FWLsdxkkvuf1zdvSCZINCkevHaVzkBC2F_WO2E1vpc#id.l9sgb8g2sp39)
    Coming soon
  • JaviJavi Member
    edited June 2012
    Hi Javi,
    I'm implement protocol and in sendPacketToFirebaseServer, i try this:

    function sendPacketToFirebaseServer(version_packet_str)
    client = socket.connect("localhost", 4123)
    client:send(version_packet_str)
    while true do
    s, status, partial = client:receive(1024)
    print(s or partial)
    if status == "closed" then
    break
    end
    end
    client:close()
    return "done";
    end

    But the player become not response (Server work well)

    So can you show me the right way to receive server response?

    And can you please show me how to pack String argument?
    (example login request : https://docs.google.com/document/pub?id=1-FWLsdxkkvuf1zdvSCZINCkevHaVzkBC2F_WO2E1vpc#id.l9sgb8g2sp39)
    I don't use/know Firebase but I suppose that first you need to send a login request packet to the server.
    function serializeInt16(value)
      local a = bit32.band(bit32.rshift(value, 8), 255)
      local b = bit32.band(value, 255)
     
      return string.char(a, b)
    end
     
    function int32(str)
      return string.byte(str, 1) * 16777216 + string.byte(str, 2) * 65536 + string.byte(str, 3) * 256 + string.byte(str, 4)
    end
     
    function int16(str)
      return string.byte(str, 1) * 256 + string.byte(str, 2)
    end
     
    function stringLuaToStringFirebase(lua_str)
      return serializeInt16(#lua_str) .. lua_str
    end
     
    function stringFirebaseToStringLua(firebase_str)
      return string.sub(firebase_str, 3, int16(firebase_str) + 2)
    end
     
    function stringLuaToArrayFirebase(lua_str)
      return serializeInt32(#lua_str) .. lua_str
    end
     
    function arrayFirebaseToStringLua(firebase_str)
      return string.sub(firebase_str, 5, int32(firebase_str) + 4)
    end
     
    function typeOfPacket(packet)
      if packet == nil or #packet < 6 then
        return nil
      end
     
      return string.byte(string.sub(packet, 5))
    end
     
    function loginRequestPacket(user, password, operator_id, credentials)
      local body = string.char(10) .. stringLuaToStringFirebase(user) .. 
                  stringLuaToStringFirebase(password) .. 
                  serializeInt32(operator_id) .. 
                  stringLuaToArrayFirebase(credentials)
     
      return packet(body)
    end
     
    function printLoginResponsePacket(packet)
      local pos = 6
     
      local screen_name = stringFirebaseToStringLua(string.sub(packet, pos))
      pos = pos + #screen_name + 2
     
      local pid = int32(string.sub(packet, pos))
      pos = pos + 4
     
      local status = string.byte(string.sub(packet, pos))
      pos = pos + 1
     
      local code = int32(string.sub(packet, pos))
      pos = pos + 4
     
      local message = stringFirebaseToStringLua(string.sub(packet, pos))
      pos = pos + #message + 2
     
      local credentials = arrayFirebaseToStringLua(string.sub(packet, pos))
     
      print("Screen name: " .. screen_name)
      print("PID: " .. pid)
      print("Status: " .. status)
      print("Code: " .. code)
      print("Message: " .. message)
    end
     
    function sendPacketToFirebaseServer(packet)
      client = socket.connect("127.0.0.1", 4123)
      client:send(packet)
      local response_packet = ""
      while true do
        local s, status, partial = client:receive(1024)
        local str = s or partial
        if str then
          response_packet = response_packet .. str
        end
        if status == "closed" then 
          break 
        end
      end
      client:close()
     
      return response_packet
    end
     
    local login_packet_request = loginRequestPacket("username", "password", 123, 456)
    local response_packet = sendPacketToFirebaseServer(login_packet_request)
    if typeOfPacket(response_packet) == 11 then
      printLoginResponsePacket(login_packet_response)
    else
      (...)
    end

    PD: Do not print directly the response packets, unpack them (see printLoginResponsePacket(...) as an example).
    +1 -1 (+1 / -0 )Share on Facebook
  • Thanks Javi for more detail function.
    When server receive packet, it show hex dump
    00 00 00 16 0A 00 06 74 69 6E 68 6C 68 00 03 31 32 33 00 00 00 7B
    And do not accept message.

    INFO SessionHandler - Exception caught for session. Closing session: (SOCKET, R
    : /127.0.0.1:2789, L: /127.0.0.1:4123, S: /0.0.0.0:4123)
    org.apache.mina.filter.codec.ProtocolDecoderException: java.nio.BufferUnderflowE
    xception (Hexdump: 00 00 00 16 0A 00 06 74 69 6E 68 6C 68 00 03 31 32 33 00 00 0
    0 7B)
    at org.apache.mina.filter.codec.ProtocolCodecFilter.messageReceived(Prot
    ocolCodecFilter.java:165)

    So do we packed it right?
    Coming soon
  • JaviJavi Member
    Thanks Javi for more detail function.
    When server receive packet, it show hex dump
    00 00 00 16 0A 00 06 74 69 6E 68 6C 68 00 03 31 32 33 00 00 00 7B
    And do not accept message.

    INFO SessionHandler - Exception caught for session. Closing session: (SOCKET, R
    : /127.0.0.1:2789, L: /127.0.0.1:4123, S: /0.0.0.0:4123)
    org.apache.mina.filter.codec.ProtocolDecoderException: java.nio.BufferUnderflowE
    xception (Hexdump: 00 00 00 16 0A 00 06 74 69 6E 68 6C 68 00 03 31 32 33 00 00 0
    0 7B)
    at org.apache.mina.filter.codec.ProtocolCodecFilter.messageReceived(Prot
    ocolCodecFilter.java:165)

    So do we packed it right?
    I forgot to write the credentials in quotes:
    local login_packet_request = loginRequestPacket("username", "password", 123, "456")
    If the problem persists try excluding the size of the first field:
    -- Base function to build Firebase packets
    function packet(body)
      local size = #body
     
      return serializeInt32(size) .. body
    end
    +1 -1 (+1 / -0 )Share on Facebook
  • Hi Javi,
    I try as you comment but it still cause error.
    For detail and debug information, i send you Server code and Client Code.
    To start Server, go to pom.xml file folder and type maven command: mvn firebase:run
    (No Database and Setup require)
    Many Thanks!

    http://dl.dropbox.com/u/55451790/firegame.zip
    http://dl.dropbox.com/u/55451790/Socket.zip
    Coming soon
  • JaviJavi Member
    edited June 2012
    It works, the problem was you used stringLuaToStringFirebase(credentials) instead of stringLuaToArrayFirebase(credentials).

    The server doesn't close the connection so I've modified also sendPacketToFirebaseServer(...).
    function packet(body)
      local size = #body + 4
     
      return serializeInt32(size) .. body
    end
     
    function loginRequestPacket(user, password, operator_id, credentials)
      local body = string.char(10) .. stringLuaToStringFirebase(user) .. 
        stringLuaToStringFirebase(password) .. 
        serializeInt32(operator_id) .. 
        stringLuaToArrayFirebase(credentials) -- This is an ARRAY!
     
      return packet(body)
    end
     
    function sendPacketToFirebaseServer(packet)
      client = socket.connect("127.0.0.1", 4123)
      client:send(packet)
      local response_packet = ""
      while true do
        local s, status, partial = client:receive(1)
        local str = s or partial
        if str then
          response_packet = response_packet .. str
        else
          response_packet = nil
          break
        end
        local response_packet_size = #response_packet
        if response_packet_size > 4 then
          if response_packet_size == int32(response_packet) then
            -- OK, packet received
            break
          end
        end
        if status == "closed" then 
          response_packet = nil
          break 
        end
      end
      client:close()
     
      return response_packet -- Note: if any problem response_packet == nil
    end
     
    local login_packet_request = loginRequestPacket("tinhlh", "123", 123, "456")
    local response_packet = sendPacketToFirebaseServer(login_packet_request)
    local type_of_packet = typeOfPacket(response_packet)
    if type_of_packet == nil then
      print("Connection error!")
    elseif type_of_packet == 11 then
      printLoginResponsePacket(response_packet)
    else  -- Rest of packets...  elseif type_of_packet == X then (...)
      print("Type of packet received: " .. type_of_packet)
    end
    Now just follow the protocol and implement the rest of the packets, ok?
    +1 -1 (+2 / -0 )Share on Facebook
  • SinisterSoftSinisterSoft Maintainer
    An example on how to comms using sockets to an OAuth 2.0 systsem would be great, this way we could login to Facebook, Twitter and loads more online systems.
    Coder, video game industry veteran (since the '80s, ❤'s assembler), arrested - never convicted hacker (in the '90s), dad of five, he/him (if that even matters!).
    https://deluxepixel.com
  • edited June 2012
    Wow wow!
    It works like a charm!
    Thanks Javi so much for your Patient support!
    I've updated client code and share to community (http://www.giderosmobile.com/forum/discussion/1098/complete-code-client-server-for-building-multiplayer-game)

    Again, thanks Javi! :)>-

    Likes: ndoss, MoKaLux

    Coming soon
    +1 -1 (+2 / -0 )Share on Facebook
  • @Javi & @vitalitymobile ... thanks for sharing ... this is nice!
  • JaviJavi Member
    You are all welcome
  • A simple code but help me so much!
    It's easy to understand and practice...
    Thanks so much
    +1 -1 (+1 / -0 )Share on Facebook
  • That's nice
    Thanks @Javi and @vitalitymobile
    +1 -1 (+1 / -0 )Share on Facebook
  • Apollo14Apollo14 Member
    edited August 2018
    Hi guys!
    I'm trying to create basic luasocket project.
    How to fix this error? It seems that a file is missing, though I'm using Gideros 2018.6.2, everything should be there. All plugin files are present in C:\Program Files(x86)\Gideros\All Plugins\luasocket
    (I've enabled plugin "Lua Socket" in my project's settings)
    All I have in my 'main.lua':
    local socket = require("socket")
    client = socket.connect("google.com", 80)
    client:send("GET /robots.txt HTTP/1.0\r\n\r\n")
    while true do
    	s, status, partial = client:receive(1024)
    	print(s or partial)
    		if status == "closed" then 
    			break 
    		end
    end
    client:close()
    Console error:
    main.lua is uploading.
    Uploading finished.
    main.lua:14: module 'socket' not found:
    	no field package.preload['socket']
    	no file './socket.lua'
    	no file './socket/init.lua'
    	no file './_LuaPlugins_/socket.lua'
    	no file './_LuaPlugins_/socket/init.lua'
    	no file '/usr/local/share/lua/5.1/socket.lua'
    	no file '/usr/local/share/lua/5.1/socket/init.lua'
    	no file '/usr/local/lib/lua/5.1/socket.lua'
    	no file '/usr/local/lib/lua/5.1/socket/init.lua'
    	no file './socket.so'
    	no file '/usr/local/lib/lua/5.1/socket.so'
    	no file '/usr/local/lib/lua/5.1/loadall.so'
    stack traceback:
    	main.lua:14: in main chunk
    main.lua is uploading.
    Uploading finished.
    main.lua:1: module 'socket' not found:
    	no field package.preload['socket']
    	no file './socket.lua'
    	no file './socket/init.lua'
    	no file './_LuaPlugins_/socket.lua'
    	no file './_LuaPlugins_/socket/init.lua'
    	no file '/usr/local/share/lua/5.1/socket.lua'
    	no file '/usr/local/share/lua/5.1/socket/init.lua'
    p. s. When I'm trying to open Arthur's example project, error:
    Uploading finished.
    cannot open socket.lua: No such file or directory
    socket.lua cannot be opened.
    > Newcomers roadmap: from where to start learning Gideros
    "What one programmer can do in one month, two programmers can do in two months." - Fred Brooks
    “The more you do coding stuff, the better you get at it.” - Aristotle (322 BC)
  • olegoleg Member
    add the plugin to the project
    my games:
    https://play.google.com/store/apps/developer?id=razorback456
    мій блог по гідерос https://simartinfo.blogspot.com
    Слава Україні!
  • oleg said:

    add the plugin to the project

    I've added it first of all.
    > Newcomers roadmap: from where to start learning Gideros
    "What one programmer can do in one month, two programmers can do in two months." - Fred Brooks
    “The more you do coding stuff, the better you get at it.” - Aristotle (322 BC)
  • *attached my gproj to this post
    zip
    zip
    LuaSocketTest.zip
    1001B
    > Newcomers roadmap: from where to start learning Gideros
    "What one programmer can do in one month, two programmers can do in two months." - Fred Brooks
    “The more you do coding stuff, the better you get at it.” - Aristotle (322 BC)
  • uh, I had to add 'socket.lua' to my project's files, together with 'main.lua'
    Got some response from Google! :D
    socket.lua is uploading.
    Uploading finished.
    HTTP/1.0 200 OK
    Accept-Ranges: none
    Vary: Accept-Encoding
    Content-Type: text/plain
    Date: Sat, 11 Aug 2018 07:44:50 GMT
    Expires: Sat, 11 Aug 2018 07:44:50 GMT
    Cache-Control: private, max-age=0
    Last-Modified: Fri, 25 May 2018 19:00:00 GMT
    X-Content-Type-Options: nosniff
    Server: sffe
    X-XSS-Protection: 1; mode=block

    User-agent: *
    Disallow: /search
    Allow: /search/about
    Allow: /search/static
    Allow: /search/howsearchworks
    Disallow: /sdch
    Disallow: /groups
    Disallow: /index.html?
    Disallow: /?
    Allow: /?hl=
    Disallow: /?hl=*&
    Allow: /?hl=*&gws_rd=ssl$
    Disallow: /?hl=*&*&gws_rd=ssl
    Allow: /?gws_rd=ssl$
    Allow: /?pt1=true$
    Disallow: /imgres
    Disallow: /u/
    Disallow: /preferences
    Disallow: /setprefs
    Disallow: /default
    Disallow: /m?
    Disallow: /m/
    Allow: /m/finance
    Disallow: /wml?
    Disallow: /wml/?
    Disallow: /wml/search?
    Disallow: /xhtml?
    Disallow: /xhtml/?
    Disallow: /xhtml/search?
    Disallow: /xml?
    Disallow: /imode?
    Disallow: /imode/?
    Disallow: /imode/search?
    Disallow: /jsky?
    Disallow: /jsky/?
    Disallow: /jsky/searc
    h?
    Disallow: /pda?
    Disallow: /pda/?
    Disallow: /pda/search?
    Disallow: /sprint_xhtml
    Disallow: /sprint_wml
    Disallow: /pqa
    Disallow: /palm
    Disallow: /gwt/
    Disallow: /purchases
    Disallow: /local?
    Disallow: /local_url
    Disallow: /shihui?
    Disallow: /shihui/
    Disallow: /products?
    Disallow: /product_
    Disallow: /products_
    Disallow: /products;
    Disallow: /print
    Disallow: /books/
    Disallow: /bkshp?*q=*
    Disallow: /books?*q=*
    Disallow: /books?*output=*
    Disallow: /books?*pg=*
    Disallow: /books?*jtp=*
    Disallow: /books?*jscmd=*
    Disallow: /books?*buy=*
    Disallow: /books?*zoom=*
    Allow: /books?*q=related:*
    Allow: /books?*q=editions:*
    Allow: /books?*q=subject:*
    Allow: /books/about
    Allow: /booksrightsholders
    Allow: /books?*zoom=1*
    Allow: /books?*zoom=5*
    Allow: /books/content?*zoom=1*
    Allow: /books/content?*zoom=5*
    Disallow: /ebooks/
    Disallow: /ebooks?*q=*
    Disallow: /ebooks?*output=*
    Disallow: /ebooks?*pg=*
    Disallow: /ebooks?*jscmd=*
    Disallow: /ebooks?*buy=*
    Disallow: /ebooks?*zoom=*
    Allow: /ebooks?*q=related:*
    Allow: /ebooks?*q=editions
    :*
    Allow: /ebooks?*q=subject:*
    Allow: /ebooks?*zoom=1*
    Allow: /ebooks?*zoom=5*
    Disallow: /patents?
    Disallow: /patents/download/
    Disallow: /patents/pdf/
    Disallow: /patents/related/
    Disallow: /scholar
    Disallow: /citations?
    Allow: /citations?user=
    Disallow: /citations?*cstart=
    Allow: /citations?view_op=new_profile
    Allow: /citations?view_op=top_venues
    Allow: /scholar_share
    Disallow: /s?
    Allow: /maps?*output=classic*
    Allow: /maps?*file=
    Allow: /maps/api/js?
    Allow: /maps/d/
    Disallow: /maps?
    Disallow: /mapstt?
    Disallow: /mapslt?
    Disallow: /maps/stk/
    Disallow: /maps/br?
    Disallow: /mapabcpoi?
    Disallow: /maphp?
    Disallow: /mapprint?
    Disallow: /maps/api/js/
    Disallow: /maps/api/staticmap?
    Disallow: /maps/api/streetview
    Disallow: /mld?
    Disallow: /staticmap?
    Disallow: /maps/preview
    Disallow: /maps/place
    Disallow: /help/maps/streetview/partners/welcome/
    Disallow: /help/maps/indoormaps/partners/
    Disallow: /lochp?
    Disallow: /center
    Disallow: /ie?
    Disallow: /blogsearch/
    Disallow: /blogsearch_feeds
    Disallow: /advanced_blog_searc
    h
    Disallow: /uds/
    Disallow: /chart?
    Disallow: /transit?
    Disallow: /extern_js/
    Disallow: /xjs/
    Disallow: /calendar/feeds/
    Disallow: /calendar/ical/
    Disallow: /cl2/feeds/
    Disallow: /cl2/ical/
    Disallow: /coop/directory
    Disallow: /coop/manage
    Disallow: /trends?
    Disallow: /trends/music?
    Disallow: /trends/hottrends?
    Disallow: /trends/viz?
    Disallow: /trends/embed.js?
    Disallow: /trends/fetchComponent?
    Disallow: /trends/beta
    Disallow: /trends/topics
    Disallow: /musica
    Disallow: /musicad
    Disallow: /musicas
    Disallow: /musicl
    Disallow: /musics
    Disallow: /musicsearch
    Disallow: /musicsp
    Disallow: /musiclp
    Disallow: /urchin_test/
    Disallow: /movies?
    Disallow: /wapsearch?
    Allow: /safebrowsing/diagnostic
    Allow: /safebrowsing/report_badware/
    Allow: /safebrowsing/report_error/
    Allow: /safebrowsing/report_phish/
    Disallow: /reviews/search?
    Disallow: /orkut/albums
    Disallow: /cbk
    Allow: /cbk?output=tile&cb_client=maps_sv
    Disallow: /maps/api/js/AuthenticationService.Authenticate
    Disallow: /maps/api/js/QuotaService.RecordEvent
    Disallow
    : /recharge/dashboard/car
    Disallow: /recharge/dashboard/static/
    Disallow: /profiles/me
    Allow: /profiles
    Disallow: /s2/profiles/me
    Allow: /s2/profiles
    Allow: /s2/oz
    Allow: /s2/photos
    Allow: /s2/search/social
    Allow: /s2/static
    Disallow: /s2
    Disallow: /transconsole/portal/
    Disallow: /gcc/
    Disallow: /aclk
    Disallow: /cse?
    Disallow: /cse/home
    Disallow: /cse/panel
    Disallow: /cse/manage
    Disallow: /tbproxy/
    Disallow: /imesync/
    Disallow: /shenghuo/search?
    Disallow: /support/forum/search?
    Disallow: /reviews/polls/
    Disallow: /hosted/images/
    Disallow: /ppob/?
    Disallow: /ppob?
    Disallow: /accounts/ClientLogin
    Disallow: /accounts/ClientAuth
    Disallow: /accounts/o8
    Allow: /accounts/o8/id
    Disallow: /topicsearch?q=
    Disallow: /xfx7/
    Disallow: /squared/api
    Disallow: /squared/search
    Disallow: /squared/table
    Disallow: /qnasearch?
    Disallow: /app/updates
    Disallow: /sidewiki/entry/
    Disallow: /quality_form?
    Disallow: /labs/popgadget/search
    Disallow: /buzz/post
    Disallow: /compressiontest/
    Disallow: /analytics/feeds/
    Disallow: /analytics/
    partners/comments/
    Disallow: /analytics/portal/
    Disallow: /analytics/uploads/
    Allow: /alerts/manage
    Allow: /alerts/remove
    Disallow: /alerts/
    Allow: /alerts/$
    Disallow: /ads/search?
    Disallow: /ads/plan/action_plan?
    Disallow: /ads/plan/api/
    Disallow: /ads/hotels/partners
    Disallow: /phone/compare/?
    Disallow: /travel/clk
    Disallow: /hotelfinder/rpc
    Disallow: /hotels/rpc
    Disallow: /flights/rpc
    Disallow: /async/flights/
    Disallow: /commercesearch/services/
    Disallow: /evaluation/
    Disallow: /chrome/browser/mobile/tour
    Disallow: /compare/*/apply*
    Disallow: /forms/perks/
    Disallow: /shopping/suppliers/search
    Disallow: /ct/
    Disallow: /edu/cs4hs/
    Disallow: /trustedstores/s/
    Disallow: /trustedstores/tm2
    Disallow: /trustedstores/verify
    Disallow: /adwords/proposal
    Disallow: /shopping/product/
    Disallow: /shopping/seller
    Disallow: /shopping/reviewer
    Disallow: /about/careers/applications/
    Disallow: /landing/signout.html
    Disallow: /webmasters/sitemaps/ping?
    Disallow: /ping?
    Disallow: /gallery/
    Disallow: /landing/now/ontap/
    Allow:
    /searchhistory/
    Allow: /maps/reserve
    Allow: /maps/reserve/partners
    Disallow: /maps/reserve/api/
    Disallow: /maps/reserve/search
    Disallow: /maps/reserve/bookings
    Disallow: /maps/reserve/settings
    Disallow: /maps/reserve/manage
    Disallow: /maps/reserve/payment
    Disallow: /maps/reserve/receipt
    Disallow: /maps/reserve/sellersignup
    Disallow: /maps/reserve/payments
    Disallow: /maps/reserve/feedback
    Disallow: /maps/reserve/terms
    Disallow: /maps/reserve/m/
    Disallow: /maps/reserve/b/
    Disallow: /maps/reserve/partner-dashboard
    Disallow: /about/views/
    Disallow: /intl/*/about/views/
    Disallow: /local/dining/
    Disallow: /local/place/reviews/
    Disallow: /local/place/rap/
    Disallow: /local/tab/
    Disallow: /travel/hotels/
    Allow: /finance
    Disallow: /finance?*q=*

    # Certain social media sites are whitelisted to allow crawlers to access page markup when links to google.com/imgres* are shared. To learn more, please contact images-robots-whitelist@google.com.
    User-agent: Twitterbot
    Allow: /imgres

    User-agent: facebookexternalhit
    Allow: /img
    res

    Sitemap: http://www.gstatic.com/s2/sitemaps/profiles-sitemap.xml
    Sitemap: https://www.google.com/sitemap.xml
    > Newcomers roadmap: from where to start learning Gideros
    "What one programmer can do in one month, two programmers can do in two months." - Fred Brooks
    “The more you do coding stuff, the better you get at it.” - Aristotle (322 BC)
  • olegoleg Member
    edited August 2018
    в Arthur's example project , відсутній файл socket.lua(файл є але запорчений) - додай його
    https://github.com/gideros/gideros/blob/master/plugins/luasocket/source/socket.lua

    в мене цей приклад працює

    Likes: Apollo14

    my games:
    https://play.google.com/store/apps/developer?id=razorback456
    мій блог по гідерос https://simartinfo.blogspot.com
    Слава Україні!
    +1 -1 (+1 / -0 )Share on Facebook
  • oleg said:

    в Arthur's example project , відсутній файл socket.lua(файл є але запорчений) - додай його
    https://github.com/gideros/gideros/blob/master/plugins/luasocket/source/socket.lua

    в мене цей приклад працює

    now it works! thx!

    Likes: MoKaLux

    > Newcomers roadmap: from where to start learning Gideros
    "What one programmer can do in one month, two programmers can do in two months." - Fred Brooks
    “The more you do coding stuff, the better you get at it.” - Aristotle (322 BC)
    +1 -1 (+1 / -0 )Share on Facebook
Sign In or Register to comment.