timcs's Forum Posts

  • Thanks lionz During the course of the game I am trying to find the best way of getting a random instance picked again - at the moment I use a function which is called at the start of the layout, however this is being called "every tick" which now see is why it picks them all as like you said call it once.

    So with that in mind I need to find a way of calling it again (the function that is) every so often like another random call for example

    Thanks

    Tim

  • Hi,

    Its been a while since I used Construct 2 and am I trying to remember how I have a set of sprites where the enemy can randomly target one .

    I first tried copy and paste these sprites however when I change the animation it changes them all.

    I then cloned them and put them in a family - again once I set the choose a random instance I am struggling to only pick one of these sprites to change their status and/or animation.

    TIA

    TimCS

  • dop2000

    Thank you for your reply. This is what I was thinking of doing but wondered about the amount of usage of memory this would take to add these extra sprites to the game to achieve this. Especially if there were a lot of different paths to take.

  • Hi all,

    It's been a while since I looked at making a game and what with many things happening such as being a father in these difficult times and having to move home three times! I never thought an idea of a game would be one of them!

    I have to admit that due to limited time on my hands I hope everyone here is ok with me asking this question.

    So the game has one main enemy/boss and the player has to control many characters in order for the boss/enemy not to target them.

    With regards the pathfinder is there a way to create random or alternative fixed paths to one point that is triggered by a set of conditions. I was thinking of having several non visible solid sprites that would be randomly enabled to force the enemy to take a given path but I was also wondering if there was a more efficient way?

    Thanks

    Tim

  • timcs try Rex MATCH PLUGIN FOR c2

    ALSO YOU WILL FIND THIS PLUGIN IN MY DROPBOX TOO.

    Thanks Lordshiva1948 I will look at this and give it a go , funny thing is , I have used plugins from Rex before and I did check the site but was not looking hard enough . Currently using his CSVtoArray plugin to get the data from a google online exported spreadsheet from a tutorial I read here.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hmm... maybe you could use variables. Card 1 could be match1 and if card = match1 then call this function and then so on for each card. If it doesn't match you can call a function that puts the card back. Maybe that could work ??

    Yes but how would I best store the information to make the check ? My first thoughts were to feed the French and English meanings into an array so that the first row would be french and the second would be english.

    My only issue then would be how to jumble the values up to assign them to each card but also find a way of matching them up as well. When I thought about that, I then wondered if there was a way to store the array positions against each card via a variable. All of this would have to be done when each card is spawned randomly on each side of the display.

    My aim is to have e.g. the french cards on the left, the "matching drop box" in the middle and the english cards on the right. Then when two cards are dropped into the "matching drop box" the game checks to see if they are correct.

  • Hi mikewalton206 thanks for your reply. I have already figured out the animation part of the project, my main issue is how to match the text objects that only appear when the cards are flipped over, I have since thought that the cards could be dragged into a central "box" but they would still need to be some logic to match them or if they do not match to snap them back to their location

  • Hi

    I have been racking my brains (or what is left of them) to work out the best way to create a card game called snap but instead of matching pictures, one side of cards will have a word or phrase in French and the other side in English.

    I have found out how to create a "flip" effect now and when it flips , it shows text so I am starting in the right direction but I need to be able to create more than one card on each side with their text generated randomly and then when the user chooses a card (also how to do this) from each, the game can check and state whether it is correct or not

  • Thanks for your reply GreatProgPluto sorry for not replying sooner, busy busy all things with life! . Ideally I wish Construct had a proper database system like the Android SDK does that is held locally. I was looking at this tutorial

    https://www.scirra.com/tutorials/276/who-said-you-cant-create-a-database-with-construct2 but I am not sure even with it being web based if it will work on later versions as I do not see a "webstore" object that is mentioned.

    With your suggestion I presume you are referring to using NW.js , I did not think this would work with Android as from the Manual it only mentions desktop OS. Is this the case?

    Sorry to go a little of topic here but....

    If construct 3 had a dedicated database object I would consider moving over to it but I have not noticed one yet. I know this is more a gaming engine than an app creator but because they make it so easy but powerful to create with, it can do both if more functionality was there.

    and thank you for your encouragement on my French ! I am trying to use Construct 2 to a means of helping me learn it by writing an app that I can update with new information and use that to test me on various things like verbs and phrases but it makes the creation harder by the lack of a database engine sadly.

  • hi

    I too would like to get TTS working in my spelling game.

    I found this plugin "cordova-plugin-tts" in the cocoon.io in the plugin section of your project within the project setting options.

    I think requires the "Cordova TextToSpeech: text to speech" from the Construct2 Cordova Plugins.

    Have a look at this link

    https://github.com/vilic/cordova-plugin-tts#readme

    hope this helps

    I have this plug in but I still cannot get it to work with phonegap

  • Hi

    I am starting an app using construct 2 where I can take notes by writing on the script. So I looked around for how to draw on the screen and found this page

    https://www.scirra.com/tutorials/1207/h ... ing-canvas

    My only problem is that when I start to draw the line object appears from off the screen. I first thought this was because I had the line object outside of the screen for when I needed to spawn it , so I set on start of layout to destroy the line but this made no difference , here is a link to my project, I have altered it a lot to try and get it to work so it may not be in its original state.

    https://drive.google.com/file/d/0B5zCtsJ4bwwOdXFRQTZnSmFkaWs/view

    My second part of the project is to password project a note but I will see if this is possible before I ask questions on that

    **EDIT 1/09/2017 **

    I think the issue is that the line uses the dot1 location to start from, this is currently sitting outside of the view

    and that is where it sets the start position from. However I am not sure how to get around this at dot2 and dot1 use each other and if I destroy them on start up, they would then need to be created before they are used when drawing

  • This is not as easy task as it seems.

    I made a demo:

    https://www.dropbox.com/s/81zheoqpust7c ... .capx?dl=0

    Thanks dop2000 i appreciate this, I will hopefully understand what you have done <img src="{SMILIES_PATH}/icon_e_smile.gif" alt=":)" title="Smile">

  • Hi

    Following on from this post :

    I need to be able to count and find records with the same value in them and then get both the key and value from that. I am sure this is simple but I cannot see a way of doing this

  • Please download this demo I created:

    https://www.dropbox.com/s/0jptlam49u7ugse/spawningDemo.capx?dl=0

    I hope it answers all your current and future questions

    Thank you again dop2000 I really appreciate your help with this, I will try not to bother you again

  • [quote:1vrwfzku]So in your example is the enemytype set against the enemy object or the spawnpoint or both?

    EnemyType instance variable is defined on the spawnpoint object. And then you set it either to "z" or "v" for each of the 24 spawnpoint instances that you have.

    You can do something similar with enemies objects - create a bunch of instance variables to store enemy type, health, damage, armor etc. etc..

    Note, that I updated the picture in my previous comment, there was a slight mistake - you need to first pick spawnpoints by EnemyType and then loop through them.

    Hi dop2000 , I must be missing something with my logic here because using your example (the updated one) no objects are being spawned

    How does the enemytype variable logic work , if I am calling this by a function, does this need a parameter?

    ** EDIT **

    Found the issue missed out the * loopindex after the wait 0.5 doh! . However with your logic the overlapping issue has come back, should I still be using the used true/false or destroy options ?