lightning_'s Forum Posts

  • I have created several topics but no one answers my topics. Neither the admins nor the most active users of the forum, they just pass by my topic. Maybe I am doing something wrong or creating a topic not according to the rules, what should I fix, ladies and gentlemen?

  • The data comes in

    player nickname and player Y coordinate

    You need to enter them somewhere and output them to text input sorted from the largest value to the smallest by player coordinates, and of course first enter a number, that is, his account number, that is, for example

    1) Jayson 456

    2)Ashley 578

    3)Drop2000 949

  • Доп2000 на мою тему не ответил,ждал от тебя ответ как от активного. Этож вопросы быстро решаются,создал несколько тем и ждад пока доп2000 ответит но не фига ((((

  • I didn't find it anywhere. How to run the game in the background. That is, so that all events in the game occur even if the game browser window tab is not open in the preview. In c2 there was a plugin for this waker

    Tagged:

  • Friends when I play my game in preview from the computer - fps 144. But when I open the game in the phone browser also as preview - it plays at fps 60. How to increase fps in the phone too. mobile game for phones

    Tagged:

  • The mobile preview was work but now not working

  • And by the way, I don't understand. Why is there a preview version. I exported the game to html and transferred it to the server. I haven't tried it in preview yet.

  • I exported the project to html 5 and opened it on open server. I also have reg.php and connect.php files there. But the game doesn't want to send an ajax request to it. Regular registration page

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Friends, I did everything as stated in the video here youtube.com/watch

    Nothing worked for me. I downloaded and installed the library as it was said. I installed the phpmyadmin database and then did everything according to the instructions.

    I used the author's script reg.php filled everything where necessary. The connection to the database is also correct. I did the project in the constructor myself, but then I used his project because you never know. But he couldn't do anything.

    I just don’t know how to correctly fix the jamb error, where he will fix it himself

    Worked for openserver. I enter the login password email press ok. But nothing appears in the database.

    The project itself was uploaded here on Google Drive. Who can quickly test I will be very grateful

    drive.google.com/drive/folders/...sp=sharing

    Tagged:

  • Friends, i have api from google translator and you need to throw post requests.

    I want to send them using ajax.

    I have already learned how to throw requests to find out the ip address, network data, currencies, etc.

    The other day I found an api from Google for translating words, but I don’t know how to correctly formulate the request and throw

    Here is the request for js

    // Imports the Google Cloud client library
    const {Translate} = require('@google-cloud/translate').v2;
    
    // Creates a client
    const translate = new Translate();
    
    /**
     * TODO(developer): Uncomment the following lines before running the sample.
     */
    // const text = 'The text to translate, e.g. Hello, world!';
    // const target = 'The target language, e.g. ru';
    
    async function translateText() {
     // Translates the text into the target language. "text" can be a string for
     // translating a single piece of text, or an array of strings for translating
     // multiple texts.
     let [translations] = await translate.translate(text, target);
     translations = Array.isArray(translations) ? translations : [translations];
     console.log('Translations:');
     translations.forEach((translation, i) => {
     console.log(`${text[i]} => (${target}) ${translation}`);
     });
    }
    
    translateText();
  • at ExpValue.set_int (ExpressionValue, set integer)

    Photon.RoomPlayerCount (Count as in number, as in int)

    str(13_room_names.SelectedText) (turns 13_room_names.SelectedText into a string, which it already is so using str() is unneccesary anyway)

    I'm not 100% sure what you exactly wanted to do. It's either that you wanted to do

    Photon.RoomPlayerCount(int(13_room_names.SelectedText))

    Or, since you have room_names in there, you didn't want to set Photon.RoomPlayerCount but Photon.RoomName (or something along those lines. I'm not familiar with Photon)

    What I want, I will explain briefly. I want to know how many players are in the room without connecting to it.

    Photon.RoomPlayerCount(int(13_room_names.SelectedText))

    I already wrote this line on "int" he swears and says that the value should be only string.

    I wrote the room number

    Photon.RoomPlayerCount("1") and so on but nothing helps, an error pops up. I don't know what to do. I do not know how to find out how many players are in the room without connecting to it.

  • I am using photon function "Photon.RoomPlayerCount(str(13_room_names.SelectedText))"

    And it gives me this error I can not understand for a week

  • I haven't used it before so I'm not sure - but have you tried putting both quotes and no quotes around the name?

    Photon.RoomPlayerCount(Name)

    Photon.RoomPlayerCount("Name")

    Then the line swears that there is no expression for the name of the object or the variable "Name"

  • Friends, I've been struggling with this problem for a whole week and I can not find an answer.

    I think there is a bug in the plugin itself

    I need to count how many players are in the room without entering it.

    There is such a function in a photon and it can be seen only by casting to a string

    "Photon.RoomPlayerCount(Name)" it constantly returns "0" to the string.

    If there are 2+ players in the room or there are no players at all, it still returns "0" I can not understand what the problem is.

    I tried in a new project but no, it doesn’t work, it constantly gives 0

  • There is a simple project.

    2 buttons.

    Create a room and enter the room.

    First I create a room.

    and another tab in the browser I connect to the room.

    The text should display information about how many players are in a certain room. But I see an error. I need to be able to see the number of players in any room by its name

    See screenshots

    c2community.ru/forum/download/file.php

    c2community.ru/forum/download/file.php

    c2community.ru/forum/download/file.php