neutrinox's Forum Posts

  • Dang it, it wasn't so simple after all. On the other hand I'm relieved, because I thought I was just an idiot for not finding this easy solution.

    The problem with your solution LittleStain is that when the user scrolls the rectangle downwards, the top part of the screen is no longer covered by it..

    So I'm still searching for a solution after all...

  • brunopalermo

    There are many reasons, like for example I'm destroying the text objects when they get out of the view (and re-creating them when they are entering back) to not have a huge amount of text sitting around doing nothing. I also need to colorize the different sentences with different colors depending on who is speaking.

    LittleStain

    Could it be that simple! I will try that immediately!

    Edit:

    LittleStain it seems to work nicely! I'm embarrassed how simple the solution was. Too much staring at the screen and too little sleep.

  • Hi!

    I'm developing a plugin-free dialogue system, in which the user can scroll the dialogue history as he wishes.

    The way I have been implementing it is that I have a big rectangular sprite, that has the drag and drop behavior (for the scrolling). When a new sentence is added on the screen, it is instantly pinned to the rectangle.

    It's working quite nicely already, but I'm not sure about something that might be a simple problem:

    I want my rectangular area to always fill the whole screen, so that the user can grab it no matter how much it has been scrolled. I can't simply change it's position, because the sentences are pinned to it. My first idea was to change the size of it, but it seems like I can only grow the size in one direction and then it doesn't cover the other side of the screen.

    This would be super easy to do if there was a way to set the coordinates of the four corners of this area, but I'm not sure if there any such possibility in construct?

    Edit: Another approach that I was thinking about (I have no idea about if this is feasible) would be to dynamically add "slices" to the top and bottom edges of the rectangle to grow it. Would something like this be possible with containers? In other words, could I make one big container that everything gets pinned to and then keep adding parts to this container to always have it fill the screen?

    Edit2: I studied containers a bit more, and that approach will probably not work.

    To summarize: is there a clever way to keep dragging a rectangle while always having it cover the whole screen?

  • Good idea, thanks I will try this!

  • Hi!

    Is it possible to detect how many line breaks (also called text wraps/newlines) the text inside a text object has?

    Another solution to my problem might be to automatically set the height of a text object based on the lines it's will contain. Is that possible?

    I need this in order to figure out if the text I'm dynamically inserting to a text object has one or two lines, so that I can create a new text object below it at the correct y-distance.

    Besides the wording I used in the title, I also tried searching with the following search words: "detect line wrap", "number of line wraps".

  • Hi!

    Does anyone know how to approach the following problem:

    Say I have a free version with a limited amount of levels available in Google Store. I also want to sell a full version for one dollar. The two games are separate entities. Is there a way to make the full version retrieve the game state from the free version, so that the client doesn't have to replay old levels?

    I tried searching the forums with keywords like "sell", "free", "unlock", "remember game state" but didn't really find any resources. Is there any tutorials on the subject I could check?

    ANY help is highly appreaciated!

  • Hi! No, sorry, I should have mentioned I try to avoid all external dependencies, and that includes plugins. I'm currently working on separating the text with pipes and looping through it with getTokenAt. I will report back later how it went (please remind me if I forget).

    Things I've noticed so far:

    Large strings look really ugly in the event sheet, so It's best to put those into their own event sheets where you don't have to look at them much.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I understand that the data has to be created and that part I have already done with Chat Mapper. I can easily export the data from Chat Mapper to any kind of format that might help. But is there any such way I could format the data that I could simply paste it into Construct once and then loop trough it to populate the array? Instead of manually populating the array with actions.

    Now that I think of it... Would it be possible to separate the values with pipes | and copy them to Construct as a single string and then use tokenAt to loop trough the values in order to populate the array.. That seems like something worth trying! Is there any limitations to string lengths that might come into play here?

  • Hi!

    I'm trying to create a dialogue system for my game and have decided to host all the text in an 2-dimensional array.

    I started filling this array with "set value at XY" -events and it became tedious quite quickly, which made me wonder if there is any way of populating this array more automatically.

    My goal is not to depend on any external files (like JSON-files). Is there some way of importing all this text to an array without the use of external files or tens of thousands of event sheet rows?

  • Ever since I started learning Construct, I've gotten this weird feeling of it being something new that is really going to revolutionize things.

    However, I have really struggled with my skepticism around Construct not being as good as writing "pure code". Today I understood why it doesn't matter. Because at the very core coding is essentially building logic. And Construct can do that just the same, but with the joys of a graphical user interface. Construct does to coding, what Windows did to Ms Dos. The graphics make it easier to stay organized, avoid mistakes and understand complicated projects.

    Insisting that Construct is inferior to plain coding is like insisting Dos is better than Windows. In some situations that might indeed be the case. The point is that for most tasks people would rather use Windows than Dos. And for the same reasons I prefer working with Construct instead of working with plain code.

  • Oh wow, didn't know that! Thank you very much!

  • Hi!

    I try to name all my assets carefully when I'm doing complicated projects. It would be really nice if the sprites imported to Construct would automatically get their default names from the imported files, because it would save a lot of trouble of always having to rename these sprites after import.

    I understand this might not work for every situation/user, but it would be really nice to have this behavior as an option in the settings.

  • Thanks for this workaround, it's certainly better than nothing!

  • Hi!

    I'm starting to have so many global variables, that I wanted to make my main event sheet a bit cleaner looking. So I had the idea that I would make a new event sheet called "globalVariables" and include that event sheet into my main event sheet.

    That didn't work however: After I have copied the variables and included the globalVariables event sheet to my main even sheet, I deleted the old global variables from the main event sheet. At that point Construct will think those global variables got deleted (even when they are really in the included event sheet) and removes all references to them from the events.

    It would be nice if Construct would also check the includes before determining if global variables don't exist anymore.

  • Can't find local variables in the debugger either. And I don't mean instance variables, but local variables.

    One work around is to use the browser object and it's alert action to show the value of local variable. That's not suitable for every case though, especially if you are running big loops.