nimos100's Forum Posts

  • [quote:21y0ke04]Can I ask you why you'd need a group for distance checking? Wouldn't simple comparison of distance be enough?

    • Distance < n

    -- Is overlapping

    --- do stuff

    I guess you might be able to do that as well, but I haven't tested that, so not sure what performance that would get you. But from guessing I would assume that you would get worse performance, as you are just introducing another check for no apparent reason. You might as well just use "Is overlapping" without the distance check, as C2 will still check for overlapping regardless of that distance check.

    What my group does is it actually turn Off/On whether an object should even be checked for collisions based on distance between objects. So as C2 checks for collisions for each object, suddenly there are far less objects (Those outside range) what it doesn't test against and therefore its basically a test whether its better to just make collision checks for each object, or if its worth using distance checks to turn off collision detection all together for certain objects, even though it requires a distance check to do it. And based on my testing at least it can in fact improve performance quite a lot, as to not doing it.

    (Just disable the group called "Disable collision" to see the difference, and yes its a terrible group name )

  • Think the easiest way, is to just add several imagepoints to the tree where you want the coconuts to be. And then when you spawn it you just tell it to spawn it at a random imagepoint. Imagepoint(Int(Random(5)+1) and just change "5" so it matches the number of imagepoints you have added to the tree.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • That wont work correctly, "Bot" and "Enemies" are two different objects, even though "Bot" is part of "Enemies", it doesn't know what "Enemies" you are talking about in the second screenshot. If you change all "Bot" to "Enemies" in screenshot 2 it should work.

  • I understand where you coming from. I tell you about my pattern of working. Might help you organize things for now. Basically, I try to keep things simple. Have a look at this image.

    I fully understand what you mean and think everyone that comment there code, find ways to do it so its easier to work and keep track of things, I do that my self as well.

    But in my opinion comments used in the way you do it, is only due to you not having the right tools available and therefore you do it that way, which is logic. But I think most people that uses functions, name them so from the name it self you know what it does. So normally you wouldn't need to comment a function call at all. But rather you would comment the function it self. So in my opinion it is just an area where C2 could help the users a bit better. And its not really something you would see the greatest importance of, if you were working on a small project, because they ofc are fairly easy to track.

  • Ashley often states that suggestions should be shown to be of use to most users and not just to the person making the suggestion.

    It would help to give more examples of how it would be useful.

    Would it be possible to have an event sheet that just has all your functions on it and include it wherever needed? That way all functions are readily accessible.

    If you take Megatronx screenshot, what you would do is simply Shift+left click "Call "CastSpell...." and C2 would go to where you have defined that function, so you wouldn't have to track it yourself through your different event sheets. Its basically just a quick search for functions. Besides making navigating a project a lot easier, it would also help make troubleshooting easier, as you can very quickly follow a path through your project and check where things might go wrong.

    And as stated its mostly for big projects, in my project for instant I have 27 event sheets with 3454 events, where most are functions, but think most people that are even working on semi big projects would benefit a lot from such feature.

  • Yeah agree it could be useful, but already using a lot of comments. And in your case it would work. But when you have events where there might be 9-12 lines before a function call and maybe even several calls after each other which again call other functions. It start to take quite some time to track through the code. You would almost end up having more comments than code

  • Are there any chance that something like this could be added....soon ?

    When working on big projects, at least in my opinion the number one thing you really start to feel is missing in C2 is tools that help you organize you project. Even though this might not solve all of it, it would really improve coding speed for such projects.

    Some other things that would also be a huge improvement, is a search functionality that goes through all event sheets and list those event sheets where there are a match.

    Also the ability to drag several objects at the same time in the project window.

  • Do you have this problem with other images as well? It looks like antialiasing is turned off.

  • [quote:yh0c4699]What i would normally do is, make an event 'when ball is in collision with obj1-turn ball blue'. Now what if added another condition of 'ball is within x' , where the object lies within the x limit. Will this help on improving performance?. instead of checking for collisions every tick for every ball-object comb, it would only check if ball is within the object's x range. Does it work that way?, or have i mistaken it?

    There are some things you can do to improve performance. First of all never use "On collision", which sounds a bit weird when that is what you want to do . However that event for some reason is very demanding and if you need to do a lot of collision detection that will kill performance quite fast. Instead use "Is overlapping".

    Also your idea of only check for collision based on range seems to be the most effective way of improving performance, This is from a test I did some time ago:

    [quote:yh0c4699]

    (Collision group is the name of the group in my program that does the distance checking, not something you find in C2)

    1. Using overlapping (With the Collision group disabled)

    Number of objects: 2490

    FPS: 8-9

    Collision checks per sec: 18000-21000

    2. Using On collision event (With the Collision group disabled)

    Number of objects: 2512

    FPS: 2-3

    Collision checks per sec: 1013025+

    3. Using overlapping (With the Collision group Enabled)

    Number of objects: 2501

    FPS: 29-30

    Collision checks per sec: 12000-15000

    4. Using On collision event (With the Collision group enabled)

    Number of objects: 2464

    FPS: 3-4

    Collision checks per sec: 2048000-3100000

    These are my tests that I just did, as it removes overlapping objects before checking collisions, there is a slight difference in amount of objects. But nothing that will change the results in any significant way.

    But if you look at the collision per secs, which is from the debugger, it goes nuts on the On collision event, even when you remove the squares that are overlapping. So something is clearly not the same but there aint really a lot you can do with the "On collision" event as its part of C2 and cant be modified.

    Number 3 uses a functionality that disable collision checking based on range. So adding something like this can increase performance quite a lot.

  • I don't think there are any way to stop it as it done in "external". Actually thought if you triggered a new find path, it would cancel the last one. Are you sure that your code is correct?

    Also they are planning on improving the path finding as far as I have been told as its pretty weak at the moment.

  • [quote:1shr1gkx]Let me know if that resolves the issue.

    This resolves the issue for me, at least the thing i was testing against seems to be working as intended. Thank you

  • I have had weird problems with some things suddenly stopped working or doing it wrong when i installed r166, however its a bit hard to explain, but at least for me r167 didnt fix it. But hopefully someone can confirm it?

  • Create a Family with the objects you want it to collide against and then test vs that.

  • Wow! That looks awesome!

    I like your gamedesign! It seems you have thought very well about what you want to do.

    But you have a lot of features, I hope you find the motivation to keep on programming.

    Are you doing this game all on your own?

    Thanks a lot, its actually really really hard to explain the game in whole as there are actually a lot more than I presented here, but hopefully it will be added over time.

    Yeah im working alone on it, so it take quite a long time to make as a lot of the feature I have never tried making before. But I hope I can get it to a playable state soon, so I can start test the flow of it.

  • Here is a short presentation of the project im currently working on with the working title of Dragonhelm. Even though it quite some time before its finished.

    As I have always enjoyed playing roleplaying games and especially rogue style roleplaying games, where gameplay is in the driving seat and graphics and sound is of less important I decided to kick off my own project, which aim is to mix the things that I enjoyed the most from all these types of games, and add several new elements to expand on the areas that I thought was missing. This gave the idea to make this game.

    The game is designed to be primarily a roleplaying game, but also features strategic elements as the player are also the ruler of there own city and land. This is not just by title, the player is in full control of how they choose to rule the city and treat their citizens. Whether the player choose to use the treasury as a personal piggy bank or buy food for the starving citizens, the choice is theirs.

    However Dragonhelm is only a small city and of little importance to the four huge empires who are all ruled by a supreme ruler chosen amongst one of these. And the laws chosen here also apply to the player, which will force them to maintain a good relationship with the supreme ruler, as he/she can also decide the fate of a disobedient player who choose not to follow the laws.

    So besides just being a roleplaying game, the player will have a lot of choices to make regarding the political situation going on through out the land, and the game will evolve based on what the player decide to do in certain situations.

    An example could be that one of the players trading caravans have been robbed in a foreign empire, and its very likely the work of the empire it self, but are trying to blame the lack of protection of the caravan on the player, How the player choose to solve it, will affect how the game plays out.

    Since it is primarily a roleplaying game a huge part of game is about levelling and evolving the characters and as the rest of game it is based on freedom. So there are currently no level cap and only a few abilities have limits to how many skill points can be put into them.

    Besides abilities the game also features skills, which range from a skill like "Guard" which will allow one character to absorb all damage done to another character for the remaining of the combat round, to skills such as "Riding" which will allow a character to use mount in combat.

    The game is tactical turn based so the player will control each of there characters in combat the same way you will see it in a game like UFO - Enemy unknown.

    So the overall idea is to make a game where the player is presented with choices and choose what to do rather than guided along a fix path chosen by the game, Which aims to make the game feel fresh each time and so the player never really knows what will happen next.

    These are a mixture of feature already in the game and those under consideration.

      • Open ended world.
      • Event driven world.
      • Skill system featuring currently 53 skills.
      • Random dungeon generator.
      • City management including wage, happiness and crime/judgement system.
      • Resource management current 8 types. These are material that are used by citizens and trading.
      • Extensive crafting system with weapon crafting, armor crafting, magic item crafting, spell crafting and poison and alchemy crafting.
      • 4 different races.
      • 6 different classes which can be customized as the player see fit. Which will add close to endless possibilities.
      • Individual relationship between empires and people.
      • Random generated quests.
      • 57 different types of weapons.
      • Real time system which feature day, week, month and year.
      • System handling ageing and behaviours of rulers.
      • Weather system.
      • System for handling diseases.
      • Counsellors that help advise the player what to do. (If not corrupted.)
      • Expanding empire.
      • Building construction.
      • Fame system that can help the player through rough times and help them influence the empires.

    It is currently a bit to early to show a lot of screenshots of the game as the graphics in the game is just working material.

    Screenshot of the map and the surrounding around Dragonhelm which are the city the player rules. (Map is not completed yet.)

    Character creation sheet.

    First attempt to make a character in inkscape to test out the program. Since I couldn't figure out how to make gradients I decided to just make the character as flat as a pancake and since the size of the characters ain't larger than 64x64 pixels i will have to check if its worth spending time on.

    Second character, went a bit better workflow wise, but still cant figure out how to add shadows correctly.

    For the third character I decided it was time to create a rogue and see if I could add some shadows and highlights to it. As I couldn't find any good way to do it automatically I decided to add them my self.

    Decided to save the priest character as there was still hope for that one and in the process change some of the things I didn't like with the first one.

    Dwarf - Druid with wolf companion

      Give a rough estimate of how far each part is. Character creation |-----------------------X--| Skill system |-----X--------------------| Music/sound |X-------------------------| Graphics |X-------------------------| Tactical combat |-------X------------------| Map features |------------------X-------| Quest feature |----------X---------------| Dungeons |---------------X----------| Event system |----X---------------------| City management |----------------------X---|
      22-05-14 - Have been working a lot on trying to get the tactical part working with focus on the AI of the enemy movement. Which is a lot harder than I expected. Which is mainly due to the path finding behavior being very limited and not very solid for tile based movement it seems, it have severe problems with directional movement and collision detection. So I have been forced to make workarounds for these things. But believe I have dealt with the main issues. 05-05-14 - Finally finished working on the character sheet, at least for now. And also had to update the character creation with the new sprite lists, so it now works in both. Also did some updates as skills already bought would still show up in the lists. So fixed that as well. So now I have started working on the tactical combat part of the game, and so far made it so rooms themselves are randomly generated. And now im looking to make a generator that can place clutter in the rooms so they will look a bit more interesting and give the player some environment to work with which I hope will make the fights more tactical in the end. 01-05-14 - Been working a bit on my character sheet, so It is now possible to open it from anywhere in the game. Besides that I replaced the skill lists with sprite lists instead which seems a lot better in my opinion, so very pleased with that. 28-04-14 - After a request from the forum about a tutorial for the dungeon generator, I decided to spend some time making that. Which took a bit of time, but it let me go through the code in details step by step and I did find some garbage code that I could remove. However it took some time off from further developing my own generator, but I did manage to integrate it into my game and create an object layer, which will be used for dungeon clutter, ladders and so on. Which will help make the dungeons more unique and give them a more interesting environment. I also managed to integrate a full save and load functionality, so players can exit and re-enter any dungeon that they have former visited should they need to go to town to sell loot or revive a fallen group member and also managed to add depth levels to it so it now support any depth that I would like. Since I integrated it into the game, there will be no more demos of it, as the other ones were developed in separated projects and could easy be turned into demos. Tutorial for Dungeon generator Tutorial for Dungeon Generator 25-04-14 - Yet another updated version of the dungeon generator, with player dummy object and light control. Demo of the dungeon generator version 2.2 - Alpha: Demo of the dungeon generator version 2.2 - Player dummy and light control 25-04-14 - Updated version of the dungeon generator, which allow different sizes and room support. Demo of the dungeon generator version 2.1 - Alpha: Demo of the dungeon generator version 2.1 - Size and room support 24-04-14 - Have been working on new design for a dungeon generator based on a node system rather than path finding. Also it doesn't use rooms the same way as the original, since I didn't really knew how to make it fit the game the way I wanted. But the generator is still in an early stage and still need to add a way to set the size of the dungeons. Demo of the dungeon generator version 2 - Alpha: Demo of the dungeon generator version 2 17-04-14 - While C2 had some unexpected problems due to an update that made my game not work probably, I decided to update the character creation sheet a bit. Also tried Inkscape to make a trial character to test out the program. With some more experience with the program I think it will suit my needs fine. 14-04-14 - Currently working on my random dungeon generator. Which is way harder than I thought, but its starting to work quite well even though there are some minor bugs. Demo of the dungeon generator - Alpha: Demo of the dungeon generator