Anyone well versed with Python or A.I. please read.

Hello, first off I want to thank anyone that can offer me any help of even attempts to do so. I am fairly new to Blender (not to game development) so please excuse me if any of these questions seem pedestrian.

I have been fairly impressed with Blenders capabilities and the support that it receives. I would like to use it to develop my first independent title but I need to know if it is capable as a game engine of following the logic that I need for this particular title. I cannot show the GDD to anyone that is not under a Non-disclosure contract (you understand) however I can give a fairly concise breakdown of the requirements that I will need. These all concern NPC character A.I… I need to know if Python is capable of doing the following:

  • moving characters along a series of checkpoints placed in an environment (these points will exist in 3-d space along all three axis) either moving between points at random or moving between predetermined points

  • being able to hold the character for a predetermined amount of time at each point, adjustable on a point by point basis

  • arriving at one of these points will have to be able to trigger an animation

  • having a field of view that can recognize the users character if the user character is in a certain state (the user character will have multiple states)

  • recognizing other NPC characters (only in direct proximity to the said NPC)

  • being able to switch states (the first state will encompass all of the above)

  • the second state will have the character move between points the same as in the first state, however there will be no waiting time between points. If the NPC encounters another character in this state, it triggers the end of the game

if anyone can let me know if Blender is capable of any or all of these it would be greatly appreciated. If anyone would like to contact me personally for more information, or to clarify any of these points, please feel free to email me ([email protected]) I apologize if the information above is confusing or vague, I cannot go into much further detail in a public forum.

Much appreciation,

  • Jon

with work and patience yes tou can do all the above in Blender

Thank you, I appreciate the quick response.

  • moving characters along a series of checkpoints placed in an environment (these points will exist in 3-d space along all three axis) either moving between points at random or moving between predetermined points
    there are a multitude of AI examples on the forums that do this (mostly using logic bricks, but it translates to python fairly easily)
  • being able to hold the character for a predetermined amount of time at each point, adjustable on a point by point basis
    simple use of a timer property will do this (you can copy the property of the waypoint, if you want to change this per waypoint)
  • arriving at one of these points will have to be able to trigger an animation
    whatever event tells it to change to the next waypoint can also change animations
  • having a field of view that can recognize the users character if the user character is in a certain state (the user character will have multiple states)
    radar sensor should do this, not sure how well it works
  • recognizing other NPC characters (only in direct proximity to the said NPC)
    near sensors seem to be broken/ not fully functional as of late, but in theory this should be very easy (as a last resort you could loop through all objects and test the distance, but this is a bit inefficient)
  • being able to switch states (the first state will encompass all of the above)
    states aren’t built in, but using a property to keep track of which state an object is in, and then if/then statements, one can do this. be careful about organization though, it can get to be quite a mess.
  • the second state will have the character move between points the same as in the first state, however there will be no waiting time between points. If the NPC encounters another character in this state, it triggers the end of the game
    again, many waypoint AI systems have been/are being worked on on these forums, a little time and they could be transferred to python.

I think that about covers everything, hope I helped ^^

[edit] wow, this makes AI programming sound so easy. don’t be mislead by it’s innocent appearance XP

[QUOTE
Quote:

  • having a field of view that can recognize the users character if the user character is in a certain state (the user character will have multiple states)
    radar sensor should do this, not sure how well it works

][/QUOTE]

You can use messaging also, as your ‘states’ by using invisible planes parented to the charaters to provide collision detecting and then send the message…to check states, etc…

Hello Kuzuboshii,

Yes, blender/python is capable of all the things afore mentioned. The only main drawback would be with the animations, as the “blend-in” feature (fades animations together for a smooth transition) is broken/has bugs, ect. So the logic of it all is definitely possible, but it’s a bit harder to make it look nice. It would depend on the complexity of your game.

Good Luck!

~~Stu

Thank you all for the help, I really appreciate it, I know that I have a long uphill battle ahead of me but the difficulty of any goal is never a deterrent for me, just the possibility. If it can be done, I don’t mind how hard it is to do. Again thanks for the great responses.