Paste #65027: prerender map

Date: 2020/02/06 09:54:40 UTC-08:00
Type: Denizen Script

View Raw Paste Download This Paste
Copy Link


TestCommand:
    type: command
    debug: false
    name: test
    script:
    - define line:<context.args.first.div[16].round_up>:
    - repeat <[line]>:
        - define number:->:<[value]>
    - define quadrat:<[line].mul[line].round_up>
    - repeat <[line]>:
        - define int:<[number].get[<[loop_index]>]>
        - foreach <[number]> as:index:
        #mix together
            - narrate <player.location.chunk.add[<[int]>,<[index]>]>
            - narrate <player.location.chunk.add[<[index]>,<[int]>]>
        # sub number left & right
            - narrate <player.location.chunk.sub[<[int]>,<[index]>]>
            - narrate <player.location.chunk.sub[<[index]>,<[int]>]>
        # add number right, sub number left
            - narrate <player.location.chunk.add[<[index]>,<[int]>].sub[<[int]>,<[index]>]>
            - narrate <player.location.chunk.add[<[int]>,<[index]>].sub[<[index]>,<[int]>]>
        # add number left sub number right
            - narrate <player.location.chunk.sub[<[int]>,<[index]>].add[<[index]>,<[int]>]>
            - narrate <player.location.chunk.sub[<[index]>,<[int]>].add[<[int]>,<[index]>]>
        # add and sub both
            - narrate <player.location.chunk.add[<[index]>,<[index]>]>
            - narrate <player.location.chunk.sub[<[index]>,<[index]>]>
            - narrate <[index]>
    - narrate "Chunks Total: <[quadrat]>"