• 0

    posted a message on 'And' in loop problem

    @Elmaex: Go

    That's right, all three 'And' conditions must return true for a marine to spawn, but that's how it should be as far as I can see.

    Posted in: Triggers
  • 0

    posted a message on 'And' in loop problem

    @Elmaex: Go

    I've made a boolean array that works in a similar trigger. I do like thinking, but I think it should work as it is. So I'm curious why it doesn't.

    Posted in: Triggers
  • 0

    posted a message on 'And' in loop problem
    Trigger
        Events
            UI - Player Any Player presses Escape key Down with shift Exclude, control Exclude, alt Exclude
        Local Variables
        Conditions
        Actions
            General - For each integer A from 0 to 8 with increment 1, do (Actions)
                Actions
                    General - For each integer B from 0 to 8 with increment 1, do (Actions)
                        Actions
                            General - If (Conditions) then do (Actions) else do (Actions)
                                If
                                    And
                                        Conditions
                                            A != 1
                                            B != 1
                                    And
                                        Conditions
                                            A != 4
                                            B != 4
                                    And
                                        Conditions
                                            A != 7
                                            B != 7
                                Then
                                    Unit - Create 1 Marine for player 1 at (Point((86 + (A * 1)), (86 + (B * 1)))) using default facing (No Options)
                                Else
    

    Hi! I want this to create a 9x9 grid of marines(for now), with 3 exceptions: row 1 column 1, row 4 column 4, and row 7 column 7.

    However, row 1, 4, and 7, and column 1, 4, and 7, are devoid of marines.

    Am I not doing it the right way?

    Posted in: Triggers
  • To post a comment, please or register a new account.