Need coding help


#1

Okay so i was wounder if there was a way to make a choice depend on two stats.
for example
*choice
# get help
*if (communityawesome >=10)
Help received.
Well i want it to not just depend on communityawesome but also on communityknowhow how would that be done?


#2

`
*temp newflag
*set newflag false

*if (communityawesome >=10) and (communityknowhow > 10)
*set newflag true

*choice
*if newflag #get help

`
There may be easier ways but that’s how I do it.


#3

I think what you’re looking for is actually use if ‘and’ in ‘*if’ variables. Most of the complex stuff is at least touched on here: http://www.choiceofgames.com/make-your-own-games/choicescript-advanced/

So the middle part of @JimD’s code is an example of what I think you’re looking for. If you want it to be based on a combination of the two, you just
`
*temp communitystrength
*set communitystrength communityawesome
*set communitystrength + communityknowhow

*choice
#Get Help
*if communitystrength >= 20
Help Received
`

I hope something of that answers your question (although I’m not 100% certain what exactly you’re looking for).


#4

that helps a bunch thanks to both of you.


#5

*if (communityawesome >= 10) and (communityknowhow >= 5)
You get help.
*goto
*else
They’re useless.
*goto