Kazuato's Forum Posts

  • 15 posts
  • I'm not sure how to solve your issue, but I'd be willing to bet the cause is somethng to do with the resolution of your screens on each device, I had this same issue when sending a capx to a second pc at my studio but haven't managed to solve it yet, hopefully someone can help more than myself, then i'll be able to fix it on my pc too.

  • okay kicking myself now, turns out line 8 was the entire problem, i took away the line and made sure the enemy object was set to not rotate with pathfinding, and now they're working perfectly, thank you for your help, i would never have figured this out had i not run it in debug mode, so for that i thank thee

  • Hi, so My friends and I are working on a side scrolling shoot em up, all is going well, except for one thing, enemies that spawn during gameplay, won't follow the path that the pre existing enemies follow, I need to know how to get the newly spawned enemies to follow the same behaviour as the enemies that exist on start of layout, Thanks to a tutorial i found, I've got it set up so that the 2 enemies that are there when the layout starts find and follow a path to each waypoint, and this works, after they reach the last waypoint they repeat the cycle again, this works perfectly, however, enemies that spawn during gameplay, will only move to one waypoint and then stop altogether, i figured that using the condition and actions of "(basicEnemy)on created--> find path to (waypoint.x, waypoint.y)" would have them start the path, then the code i have for the two pre existing enemies for what to do when they arrive would take over and have the newly spawned enemies following the pathfinding cycle i have set out, but as i mentioned, they just come to a halt, anyone have any ideas? I've included an image of my event sheet for reference, really hoping it's a case of overlooking something minor.

  • You do not have permission to view this post

  • hi, sorry for taking so long to respond, you've been a massive help so far my dude, i thank you for that, i have a question about the example code, would this also work if i wanted to make all players (including npcs) pick their plot during the same plot cycle? turns out i was wrong about how the plots are meant to be chosen, all players are supposed to pick their plot in the same cycle as only one cycle is meant to happen in each round

  • tarek2

    sorry i forgot to mention that you get to choose a new plot each turn, the turn structure goes like this:

    -players acquire plots of land.

    -players then pick up a mule (gull)

    -players then equip the mule(gull) with a resource

    -players take mule (gull) to their chosen plots

    -the mules (gulls) stay in the plots and produce more of their equipped resource

    -the players end this stage by entering a building (pub)

    -the next stage begins in which the players take turns buying and selling resources from one another

    -the turn then ends and the process is repeated beginning with each player selecting a new plot whilst continuing to own the plots from previous turns.

    the turns are preset at 6 or 12 turns for a full game, this stops the game going on long enough that no plots will be available to buy at the start of a new turn, the reason I've neglected to include this information is because I didn't realize how confusing my explanations would be without the full turn structure included, but the moment I read the quote that confused you again, I realized that I should explain how an entire turn works, I got a little lazy in an earlier post by using a youtube video of the original game hoping it would explain it all but in hindsight, it's a long video and i only directed readers to the part that shows plot selection, so i now realize that if i wanted that video to explain all i should have said for readers of my post to watch the video from start to at least the 2nd turn, still, I've explained the full turn structure now and hopefully this will help with the confusion I've caused

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • the NPCs are allowed to choose any empty plot, as is the player, the event sheet shows it waiting and randomly selecting the NPC plots but that's only because i haven't gotten round to finishing the method the NPCs use to select their plots, this method only exists for me to be able to test other features are working right, eventually what will happen will be like this:

    -plot selector starts its run over the land

    -player clicks button when selector is over the plot they want

    -plot selector begins its cycle anew

    -NPC chooses its plot when selector is over the plot they want

    -plot selector begins its cycle anew

    -next NPC chooses its plot when selector is over the plot they want

    this continues until all four players have selected one plot each, each plot is only allowed to be selected once, so the player cant choose a plot that an NPC owns, the player also can't choose a plot he/she already owns, the same rules apply to each of the NPCs, as for who goes first, in the final product the game will randomly decide which player or NPC gets to choose the first plot and which order the remaining players get to choose, after the first turn, the player who is in the lead will choose the plot first and then the other players will get to choose in order of how well they're doing.

    so the first turn will have a randomly generated order for who chooses their plots and then all future turns will prioritise the winning player (winning chooses first, then 2nd place followed by 3rd followed by 4th).

    so the limited choices the NPCs currently have will not be limited in the final product, they will have the ability to choose any plot that isn't owned simply by choosing it when the plot selector is over the plot they want

    i hope this has cleared up some of the confusion

  • https://imgur.com/a/Vn6wc

    link to pics of plot selector events

  • tarek2

    the background (grass, sand, water) is made using a sprite, there's no underlying grid attached to it for the plot selector to assign plots to, it just spawns a plot sprite at its current location when a player presses a button, I think I'm gonna try replacing the sprite based map with a tilemap instead now though because the loop the plot selector is on isn't tile by tile, I'm using set position to (self.x+65)(self.y) for horizontal movement and then setting it back to its original x position and moving it down on the y axis to start it on the next line down, this has its drawbacks though as it tends to move further and faster each time it begins a new cycle and I cant figure out why, so using a tilemap would give me a better way to control the plot selectors movement and accuracy

  • What I don't understand is how the video you shared shows these "Plots" being selected vs how you describe it. You describe it as a player or NPC picking a "Plot" that they want to own(control?), but the video shows a very scripted, left to right, top to bottom method of scrolling through the plots one by one and assigning them to players...

    the plot selector is designed to run along the screen in this linear fashion and the

    player has to press a button to select a plot once the selector reaches the plot they

    desire, this leaves the possibility of the player selecting the wrong plot open as a way

    of increasing the difficulty, kinda like those machines in an arcade where you have to stop

    a light by pressing a button but it moves so fast you have to time it right to stop the

    light where you want it to stop, and if your timing is off, the light wont land where

    you want it to land, in the final product the plot selector will start back at its original

    position each time a player selects a plot.

    this link:

    Subscribe to Construct videos now

    will take you to a video of the original mule game that we're basing this game on,

    if you skip to 1:10 you'll see the plot selection process happen in the original game,

    hopefully this shows you what i'm trying to explain better than my video or words have

    been able to yet haha

  • I'm using sprites for the plot selector, when a plot is selected it's not changing the colour, it's spawning a separate sprite that is coloured depending on which player owns the plot (red for p1, green p2, blue p3 and yellow p4) would the boolean variable still work in this scenario? i feel like i'd have to run some kind of check with the plot selector so it can check if a sprite has already spawned on the plot or not before it can spawn a new one, but there in lies my problem, I'm not sure how i'd run the check, one suggestion i was given was to use an array instead of my current method, so i've been reading up on arrays in the mean time so i'll know how to implement the array if it turns out to be the best solution

  • Hi there people, i've been building a game, a few of you have helped out in the past, this time i have a video to help explain my problem, basically i want to know how to stop one player (or NPC) being able to choose the same plot of land as itself in the previous turn, or choosing the plot of another player (or NPC) to see how my plot selection works i've provided a short video that shows a small amount of the gameplay (specifically the plots being chosen by the player and then the 3 NPCs) to demonstrate what happens when a plot is selected, what i need to know is how to stop selected plots from being re selected during later turns, or by another player/NPC in the same turn.

    this link will take you to the video:

    https://youtu.be/_wQY_g9LMts

  • I was expecting difficulty, given the specifics of the build i didn't think anyone would be able to give a "do this that and this" answer, i was expecting replies like these, that give me the general idea and i'd have to build on top, which is what i've gotten, it still seems like a daunting aspect, but i'm pretty sure i understand what i've gotta do now, at least enough to get started, currently im experimenting with pathfinding to control the movements of a character based on two stats (taste&inventory) at the start of the layout taste is designated 0 or 1 and the character chooses its food based on that number, when the inventory reaches its capacity, the character heads back to his starting point, i started this test out after reading the initial response from nimos, using a crude stat system to give the character its motive, i'm going to continue to build upon this and the other tips and info from both replies, thank you both for the help so far, i at least have an idea of how to move forward with this now.

  • Hi, had pretty speedy results last time i posted here so I'm gonna make use of the community more often, I'm building a game, it's essentially M.U.L.E. (for those of you that know the game) but customized to specifically reflect the town in which we live, anyway, most aspects are running smoothly and are relatively easy to program, what i am struggling with, mainly because of the absence of the other programmer, I'm left to teach myself how to get the enemy players to do what they need to do each turn alongside the player, I've programmed enemies in other games that simply attack the player or chase the player whilst firing at them, I've also done classic platform enemy movements, but this is different to anything i have experience with, essentially the turns go like this:

    -players take turns to choose a plot of land

    -player, and enemies, then go and fetch "mule" and choose which resource it will carry

    -players then take their chosen "mule" to their plot of land where the "mule" will produce the chosen resource

    -players then go and end their turns by going to the pub, where the remaining time is converted into a reward for the players

    -next the players' plots of land produce resources the players can use in the next stage of the turn

    -the players now head into the commerce stage, where each players can sell excess and buy needed resources to each other

    -at the end of the commerce stage random events trigger that can both benefit and hinder the players

    -The turn then ends and the sequence starts again beginning with plot choice

    what i need help with is programming the enemy players so that each turn they choose their land and buy their resources and participate in the auctions, now, it's easy enough to make them do this stuff in sequence, what i dont know how I'm going to do, is get the enemies doing this by their own choice sort of thing, a reeeeally primitive AI, so they buy relevant resources when they need them and to sell or buy resources intelligently, this is essential because if the enemies just do the same thing every turn, the player will face no challenge and after playing the game once, they'll know what is coming every time and therefore would have no interest in playing a second time, and obviously, as game designers pouring our time and effort into building a game, we want people to enjoy our game enough to play again and again, any help will be greatly appreciated, thank you.

  • Basically the main thing is simply to make sure that things only happen for a given player or AI at a given time. Which sounds logic obviously

    What you can do to control it is simply to make a Variable that keeping track of who's turn it is and make sure that its a condition all the places where its needed. When that player / AI is done you just change the variable to the next turn and so forth.

    Using lots of Functions would be a good idea (in general its a good idea) But what they allow you to do, is to call the function with different variables. In which the Variable that keeps track of who's turn it is could be one of them. That way you can reuse pretty much all the code for both player and all the AIs, if they are suppose to be the same.

    There ain't really a huge difference besides the above mentioned when it comes to a turn based game and a non turn based. Even in real time games things happens in turns, they are just so fast that you don't really notice it.

    Meaning all units in a real time game doesn't reacted at the same time, they simply appears to.

    Thank you, now you've explained it I can't believe I hadn't worked it out yet, I use plenty of functions already, but I don't often make use of the variables, gonna go into the project and start working again now, thank you for this explanation my dude.

  • 15 posts