stolk / GPGOAP

General Purpose Goal Oriented Action Planning
558 stars 63 forks source link

Function to get worldstate atoms #10

Closed MisterProjectLC closed 3 years ago

MisterProjectLC commented 3 years ago

I've added a function to get the value from a worldstate atom. Its signature is similar to the setter function. I haven't tested it extensively, but considering it's a pretty simple functionality, I don't think I've screwed up. I do have to mention, however, that this is my first foray into open source contributing - as such, I urge you to nevertheless look over what I did and make sure there aren't any mistakes.

stolk commented 3 years ago

This code is incorrect. The test for -1 will always fail. The function will never return false.

Furthermore, in the interest of minimalism, I think GPGOAP can manage without a get functionality.

MisterProjectLC commented 3 years ago

Alright, thanks for the quick response, and sorry for any inconvenience.