tetah
Member
|
posted 10-19-16 05:19 AM EDT (US)
i got a 2 problems on this script when i compile the first is in the line : if(choice==1){ and the second in the last line : } who can help here is my script :
scenario {
labels { //Add any constant labels here in a comma separated list. }
run_once { //Insert commands that should be executed only once when the script is loaded here. popup_dialog("The americans are lost, help them find a way!"); if (any_object_near_build(1,1,3,137,5)){ objective_complete("move"); popup_choice("the Japanese are in war with other americans, you can't go! do you want to ally?","yes","no"); if(choice==1){ popup_dialog("i'm happy to hear it, the Americans are north of here but watch out for there army!, i help you!"); declare_war(2,1); switch_teams(1,3,2016); switch_teams(1,3,36); switch_teams(1,3,24); switch_teams(1,3,2015); } else { popup_dialog("i am sorry to hear ... ATTACK THEM!"); declare_war(3, 1); make_alliance(1, 2); create_unit(1,167,184,"Assault Marines", 10); create_unit(1,167,184,"Advanced Machine Gun", 10); }
//Main script body. //Add triggers and other commands to be executed each game frame here. //Use Edit->Insert Trigger Function to select from the list of available functions //Use Edit->Insert Trigger Block to add a blank trigger block. //See ./scenario/sample_script.bhs for additional documentation
}
|