November 23, 2024, 12:53:05 AMLatest Member: Foldinajubre
BoutCheetah » Forum » Other » Off Topic » Serious question - 5000 Zylon Coins or other great reward

Serious question - 5000 Zylon Coins or other great reward

Started by Allie, October 22, 2013, 03:29:40 AM

Previous topic - Next topic

Purple

Quote from: CyberSox on October 22, 2013, 10:12:44 AM
Quote from: Purple on October 22, 2013, 09:55:10 AM
She wants a formula, not websites. I've already linked/read about 15 sites.

Those websites contain the matrices, making it easier, as you can't directly copy and paste them. But the most simple matrix for 3rd rotation:

(click to show/hide)

"...and noone in BC is either smart enough, or willing to go further than finding a page and telling me to figure it out from there"
- Allie 2013



^**** im special xd

CyberSox

Quote from: Purple on October 22, 2013, 10:15:34 AM
Quote from: CyberSox on October 22, 2013, 10:12:44 AM
Quote from: Purple on October 22, 2013, 09:55:10 AM
She wants a formula, not websites. I've already linked/read about 15 sites.

Those websites contain the matrices, making it easier, as you can't directly copy and paste them. But the most simple matrix for 3rd rotation:

(click to show/hide)

"...and noone in BC is either smart enough, or willing to go further than finding a page and telling me to figure it out from there"
- Allie 2013


I don't see any reason why I should listen to you. Stop pretending you're Allie's little sidekick, and going off topic. All I see you doing on this forums is being negative about others while not doing anything useful yourself. Back on topic, it's clear you haven't even clicked on the website, it contains a few of the required matrices to do the rotation. She asked for help, and that's the formula. She has to plug in her own values for Theta, Phi and Psi.



Socks.

Purple

Quote from: CyberSox on October 22, 2013, 10:27:06 AM
Quote from: Purple on October 22, 2013, 10:15:34 AM
Quote from: CyberSox on October 22, 2013, 10:12:44 AM
Quote from: Purple on October 22, 2013, 09:55:10 AM
She wants a formula, not websites. I've already linked/read about 15 sites.

Those websites contain the matrices, making it easier, as you can't directly copy and paste them. But the most simple matrix for 3rd rotation:

(click to show/hide)

"...and noone in BC is either smart enough, or willing to go further than finding a page and telling me to figure it out from there"
- Allie 2013


I don't see any reason why I should listen to you. Stop pretending you're Allie's little sidekick, and going off topic. All I see you doing on this forums is being negative about others while not doing anything useful yourself. Back on topic, it's clear you haven't even clicked on the website, it contains a few of the required matrices to do the rotation. She asked for help, and that's the formula. She has to plug in her own values for Theta, Phi and Psi.

I don't see where i've become Allie's 'sidekick', I was simply saying that linking a website isn't what she asked for. I already linked her that website and pointed that out, apparently it's not what she wants. I guess I should stop going offtopic though.



^**** im special xd

paranoia

Quote from: CyberSox on October 22, 2013, 10:27:06 AM
Quote from: Purple on October 22, 2013, 10:15:34 AM
Quote from: CyberSox on October 22, 2013, 10:12:44 AM
Quote from: Purple on October 22, 2013, 09:55:10 AM
She wants a formula, not websites. I've already linked/read about 15 sites.

Those websites contain the matrices, making it easier, as you can't directly copy and paste them. But the most simple matrix for 3rd rotation:

(click to show/hide)

"...and noone in BC is either smart enough, or willing to go further than finding a page and telling me to figure it out from there"
- Allie 2013


I don't see any reason why I should listen to you. Stop pretending you're Allie's little sidekick, and going off topic. All I see you doing on this forums is being negative about others while not doing anything useful yourself. Back on topic, it's clear you haven't even clicked on the website, it contains a few of the required matrices to do the rotation. She asked for help, and that's the formula. She has to plug in her own values for Theta, Phi and Psi.

There are different formulas for different modeling/game languages such as python, assembly, java, c, c++, etc. There not all the same, however I do commend you on showing her the websites you have offered( considering there pretty good/useful) It probably wont help her in this situation. Allie should have posted the current axis of the model to make it much easier.
EGK!

Iridion

Quote from: paranoia on October 22, 2013, 10:42:44 AM
Quote from: CyberSox on October 22, 2013, 10:27:06 AM
Quote from: Purple on October 22, 2013, 10:15:34 AM
Quote from: CyberSox on October 22, 2013, 10:12:44 AM
Quote from: Purple on October 22, 2013, 09:55:10 AM
She wants a formula, not websites. I've already linked/read about 15 sites.

Those websites contain the matrices, making it easier, as you can't directly copy and paste them. But the most simple matrix for 3rd rotation:

(click to show/hide)

"...and noone in BC is either smart enough, or willing to go further than finding a page and telling me to figure it out from there"
- Allie 2013


I don't see any reason why I should listen to you. Stop pretending you're Allie's little sidekick, and going off topic. All I see you doing on this forums is being negative about others while not doing anything useful yourself. Back on topic, it's clear you haven't even clicked on the website, it contains a few of the required matrices to do the rotation. She asked for help, and that's the formula. She has to plug in her own values for Theta, Phi and Psi.

There are different formulas for different modeling/game languages such as python, assembly, java, c, c++, etc. There not all the same, however I do commend you on showing her the websites you have offered( considering there pretty good/useful) It probably wont help her in this situation. Allie should have posted the current axis of the model to make it much easier.


a formula is a formula

2+2 is the same thing in every language


Quote from: Madproxyes because Iri & Kp can change the rules!
thats how we roll maddie

droid zylon1

October 22, 2013, 11:28:11 AM #20 Last Edit: October 22, 2013, 11:35:35 AM by droid zylon1
I want be able to help until this weekend but i have the forumla's saved on my laptop at my moms. If your still in need of them then i will either post here or pm them to you. (there is 2 formula's u can use. im asuming 1 is for bc.)


http://stackoverflow.com/questions/16663647/3x3-matrix-rotation-in-c   (this is 2d but it could possibly help)


http://www.youtube.com/watch?v=PpUJsw7Y-x0   (this is a youtube video that may help rotating 3d)


Hope i helped.

paranoia

Quote from: Iridion on October 22, 2013, 10:50:44 AM
Quote from: paranoia on October 22, 2013, 10:42:44 AM
Quote from: CyberSox on October 22, 2013, 10:27:06 AM
Quote from: Purple on October 22, 2013, 10:15:34 AM
Quote from: CyberSox on October 22, 2013, 10:12:44 AM
Quote from: Purple on October 22, 2013, 09:55:10 AM
She wants a formula, not websites. I've already linked/read about 15 sites.

Those websites contain the matrices, making it easier, as you can't directly copy and paste them. But the most simple matrix for 3rd rotation:

(click to show/hide)

"...and noone in BC is either smart enough, or willing to go further than finding a page and telling me to figure it out from there"
- Allie 2013


I don't see any reason why I should listen to you. Stop pretending you're Allie's little sidekick, and going off topic. All I see you doing on this forums is being negative about others while not doing anything useful yourself. Back on topic, it's clear you haven't even clicked on the website, it contains a few of the required matrices to do the rotation. She asked for help, and that's the formula. She has to plug in her own values for Theta, Phi and Psi.

There are different formulas for different modeling/game languages such as python, assembly, java, c, c++, etc. There not all the same, however I do commend you on showing her the websites you have offered( considering there pretty good/useful) It probably wont help her in this situation. Allie should have posted the current axis of the model to make it much easier.


a formula is a formula

2+2 is the same thing in every language
Your not understanding that each programming language works different and reads code different.
EGK!

Rebuck

class Map extends EventEmitter
  constructor: (size) ->
    throw new Error "Size must be between 1 and 255" unless 1 < size < 255

@constant

    @size = size

    @setMaxListeners 2

@constant

initialize grid

    @grid = new Array Math.pow(@size, 3)
    for x in [0...Math.pow(@size, 3)]
      @grid
  • = null

        @rotation = 0

        map = @
        @blockDidChangeListener = ->
          map.emit 'didChange'

        @emit 'didChange'

      forceUpdate: ->
        @emit 'didChange'

    Sets the block at the given coordinates to the given block.

      setBlock: (block, x, y, z, silent = no) ->
        @validateCoordinates x, y, z
        block.setCoordinates x, y, z if block

        [x, y] = @applyRotation x, y if @rotation
        position = x + y * @size + z * @size * @size

        @grid[position]?.removeListener 'didChange', @blockDidChangeListener
        @grid[position] = block
        @grid[position]?.addListener 'didChange', @blockDidChangeListener

        @emit 'didChange' unless silent

    Returns the block at the given coordinates.

      getBlock: (x, y, z) ->
        @validateCoordinates x, y, z
        [x, y] = @applyRotation x, y if @rotation
        return @grid[x + y * @size + z * @size * @size]

    Returns the block at the given coordinates and removes it from the map.

      removeBlock: (x, y, z, silent = no) ->
        block = @getBlock x, y, z
        @setBlock null, x, y, z, yes

        block?.removeListener 'didChange', @blockDidChangeListener
        block?.setCoordinates null, null, null

        @emit 'didChange' unless silent

        return block

    Returns the height of the block stack at the given coordinates.

      heightAt: (x, y) ->
        @validateCoordinates x, y, 0

        height = 0
        while height < @size and @getBlock x, y, height
          height++
        return height

    Returns all blocks at the given coordinates.

      getStack: (x, y, z = 0) ->
        @validateCoordinates x, y, z

        return [] if z > height = @heightAt x, y

        blocks = new Array
        for currentZ in [z...height]
          blocks.push @getBlock x, y, currentZ
        return blocks

    Blaces a stack of blocks at the given coordinates

      setStack: (blocks, x, y, z = 0, silent = no) ->
        @validateCoordinates x, y, z
        unless blocks.length - 1 + z < @size
          throw new Error "Cannot place stack, height out of bounds"

        for block in blocks
          @setBlock block, x, y, z++, yes

        @emit 'didChange' unless silent

    Returns the stack at the given coordinates and removes it from the map.

      removeStack: (x, y, z = 0, silent = no) ->
        stack = @getStack x, y, z

        for currentZ in [z...z + stack.length]
          @setBlock null, x, y, z++, yes

        @emit 'didChange' unless silent

        return stack

    Validates the map. TODO: Currently only checks for floating blocks. Validate block stacks regarding matching low and top properties.

      validate: ->
        @blocksEach (block) =>
          [x, y, z] = block.getCoordinates()
          if block and z > 0 and not @getBlock x, y, z - 1
            throw new Error "Encountered floating block at #{x}:#{y}:#{z}"

    Makes sure that the given coordinates are within the bounds of the map.

      validateCoordinates: (x, y, z) ->
        throw new Error "Index out of bounds #{x}:#{y}:#{z}" unless 0 <= x < @size and
                                                                    0 <= y < @size and
                                                                    0 <= z < @size

    Given a pair of coordinates, transforms the coordinates based on the rotation of the map.

      applyRotation: (x, y) ->
        switch @rotation
          when  90 then return [@size - 1 - y,             x]
          when 180 then return [@size - 1 - x, @size - 1 - y]
          when 270 then return [            y, @size - 1 - x]
          else
            return [x, y]

    Iterates over all block on the map, applies the given function.

      blocksEach: (functionToApply) ->
        x = @size - 1
        while x + 1
          y = 0
          while y < @size
            z = 0
            while z < @size
              functionToApply block if block = @getBlock(x, y, z)
              z++
            y++
          x--

      coordinatesEach: (functionToApply) ->
        x = @size - 1
        while x + 1
          y = 0
          while y < @size
            z = 0
            while z < @size
              functionToApply(x, y, z)
              z++
            y++
          x--

    Rotates the map 90 degrees clockwise

      rotateCW: -> @rotate true

    Rotates the map 90 degrees counter-clockwise

      rotateCCW: -> @rotate false

      rotate: (clockwise, silent = no) ->
        if clockwise
          @rotation = (@rotation +  90) % 360
        else
          @rotation = (@rotation + 270) % 360

        for block in @grid
          if block
            block.rotate clockwise, yes, yes, yes, yes
            [x, y, z] = block.getCoordinates()
            if clockwise
              [x, y] = [            y, @size - 1 - x]
            else
              [x, y] = [@size - 1 - y,             x]
            block.setCoordinates x, y, z

        @emit 'didRotate', clockwise unless silent

Xx Itz Ian

Quote from: Iridion on October 22, 2013, 10:50:44 AM
Quote from: paranoia on October 22, 2013, 10:42:44 AM
Quote from: CyberSox on October 22, 2013, 10:27:06 AM
Quote from: Purple on October 22, 2013, 10:15:34 AM
Quote from: CyberSox on October 22, 2013, 10:12:44 AM
Quote from: Purple on October 22, 2013, 09:55:10 AM
She wants a formula, not websites. I've already linked/read about 15 sites.

Those websites contain the matrices, making it easier, as you can't directly copy and paste them. But the most simple matrix for 3rd rotation:

(click to show/hide)

"...and noone in BC is either smart enough, or willing to go further than finding a page and telling me to figure it out from there"
- Allie 2013


I don't see any reason why I should listen to you. Stop pretending you're Allie's little sidekick, and going off topic. All I see you doing on this forums is being negative about others while not doing anything useful yourself. Back on topic, it's clear you haven't even clicked on the website, it contains a few of the required matrices to do the rotation. She asked for help, and that's the formula. She has to plug in her own values for Theta, Phi and Psi.

There are different formulas for different modeling/game languages such as python, assembly, java, c, c++, etc. There not all the same, however I do commend you on showing her the websites you have offered( considering there pretty good/useful) It probably wont help her in this situation. Allie should have posted the current axis of the model to make it much easier.


a formula is a formula

2+2 is the same thing in every language
however that is true there is a lot of difference within each programming language.

@rebuck
I think Allie is looking for something she can just copy paste, so you should remove the texts within each line.
League of Legends:
http://euw.op.gg/summoner/userName=ianv
http://euw.op.gg/summoner/userName=smurf+leblanc
http://euw.op.gg/summoner/userName=qqdz


▬▬▬▬▬▬▬▬▬▬ஜ۩۞۩ஜ▬▬▬▬▬▬▬▬▬
  Xx ItZ Ian
▬▬▬▬▬▬▬▬▬▬ஜ۩۞۩ஜ▬▬▬▬▬▬▬▬▬

Rebuck

Without Text!!!

class Map extends EventEmitter
  constructor: (size) ->
    throw new Error "Size must be between 1 and 255" unless 1 < size < 255



    @size = size

    @setMaxListeners 2


    @grid = new Array Math.pow(@size, 3)
    for x in [0...Math.pow(@size, 3)]
      @grid
  • = null

        @rotation = 0

        map = @
        @blockDidChangeListener = ->
          map.emit 'didChange'

        @emit 'didChange'

      forceUpdate: ->
        @emit 'didChange'


      setBlock: (block, x, y, z, silent = no) ->
        @validateCoordinates x, y, z
        block.setCoordinates x, y, z if block

        [x, y] = @applyRotation x, y if @rotation
        position = x + y * @size + z * @size * @size

        @grid[position]?.removeListener 'didChange', @blockDidChangeListener
        @grid[position] = block
        @grid[position]?.addListener 'didChange', @blockDidChangeListener

        @emit 'didChange' unless silent


      getBlock: (x, y, z) ->
        @validateCoordinates x, y, z
        [x, y] = @applyRotation x, y if @rotation
        return @grid[x + y * @size + z * @size * @size]


      removeBlock: (x, y, z, silent = no) ->
        block = @getBlock x, y, z
        @setBlock null, x, y, z, yes

        block?.removeListener 'didChange', @blockDidChangeListener
        block?.setCoordinates null, null, null

        @emit 'didChange' unless silent

        return block


      heightAt: (x, y) ->
        @validateCoordinates x, y, 0

        height = 0
        while height < @size and @getBlock x, y, height
          height++
        return height


      getStack: (x, y, z = 0) ->
        @validateCoordinates x, y, z

        return [] if z > height = @heightAt x, y

        blocks = new Array
        for currentZ in [z...height]
          blocks.push @getBlock x, y, currentZ
        return blocks


      setStack: (blocks, x, y, z = 0, silent = no) ->
        @validateCoordinates x, y, z
        unless blocks.length - 1 + z < @size
          throw new Error "Cannot place stack, height out of bounds"

        for block in blocks
          @setBlock block, x, y, z++, yes

        @emit 'didChange' unless silent


      removeStack: (x, y, z = 0, silent = no) ->
        stack = @getStack x, y, z

        for currentZ in [z...z + stack.length]
          @setBlock null, x, y, z++, yes

        @emit 'didChange' unless silent

        return stack


      validate: ->
        @blocksEach (block) =>
          [x, y, z] = block.getCoordinates()
          if block and z > 0 and not @getBlock x, y, z - 1
            throw new Error "Encountered floating block at #{x}:#{y}:#{z}"


      validateCoordinates: (x, y, z) ->
        throw new Error "Index out of bounds #{x}:#{y}:#{z}" unless 0 <= x < @size and
                                                                    0 <= y < @size and
                                                                    0 <= z < @size


      applyRotation: (x, y) ->
        switch @rotation
          when  90 then return [@size - 1 - y,             x]
          when 180 then return [@size - 1 - x, @size - 1 - y]
          when 270 then return [            y, @size - 1 - x]
          else
            return [x, y]


      blocksEach: (functionToApply) ->
        x = @size - 1
        while x + 1
          y = 0
          while y < @size
            z = 0
            while z < @size
              functionToApply block if block = @getBlock(x, y, z)
              z++
            y++
          x--

      coordinatesEach: (functionToApply) ->
        x = @size - 1
        while x + 1
          y = 0
          while y < @size
            z = 0
            while z < @size
              functionToApply(x, y, z)
              z++
            y++
          x--


      rotateCW: -> @rotate true


      rotateCCW: -> @rotate false

      rotate: (clockwise, silent = no) ->
        if clockwise
          @rotation = (@rotation +  90) % 360
        else
          @rotation = (@rotation + 270) % 360

        for block in @grid
          if block
            block.rotate clockwise, yes, yes, yes, yes
            [x, y, z] = block.getCoordinates()
            if clockwise
              [x, y] = [            y, @size - 1 - x]
            else
              [x, y] = [@size - 1 - y,             x]
            block.setCoordinates x, y, z

        @emit 'didRotate', clockwise unless silen

Rebuck


Iridion

Quote from: Xx Itz Ian on October 22, 2013, 01:20:38 PM
Quote from: Iridion on October 22, 2013, 10:50:44 AM
Quote from: paranoia on October 22, 2013, 10:42:44 AM
Quote from: CyberSox on October 22, 2013, 10:27:06 AM
Quote from: Purple on October 22, 2013, 10:15:34 AM
Quote from: CyberSox on October 22, 2013, 10:12:44 AM
Quote from: Purple on October 22, 2013, 09:55:10 AM
She wants a formula, not websites. I've already linked/read about 15 sites.

Those websites contain the matrices, making it easier, as you can't directly copy and paste them. But the most simple matrix for 3rd rotation:

(click to show/hide)

"...and noone in BC is either smart enough, or willing to go further than finding a page and telling me to figure it out from there"
- Allie 2013


I don't see any reason why I should listen to you. Stop pretending you're Allie's little sidekick, and going off topic. All I see you doing on this forums is being negative about others while not doing anything useful yourself. Back on topic, it's clear you haven't even clicked on the website, it contains a few of the required matrices to do the rotation. She asked for help, and that's the formula. She has to plug in her own values for Theta, Phi and Psi.

There are different formulas for different modeling/game languages such as python, assembly, java, c, c++, etc. There not all the same, however I do commend you on showing her the websites you have offered( considering there pretty good/useful) It probably wont help her in this situation. Allie should have posted the current axis of the model to make it much easier.


a formula is a formula

2+2 is the same thing in every language
however that is true there is a lot of difference within each programming language.

@rebuck
I think Allie is looking for something she can just copy paste, so you should remove the texts within each line.

but each formula in each programming language  has its "normal" version and thats what allie probably wants

for example |x| is done differently in c or vb.net but in both ways it is |x|


Quote from: Madproxyes because Iri & Kp can change the rules!
thats how we roll maddie

Rebuck

class Map extends EventEmitter
  constructor: (size) ->
    throw new Error "Size must be between 1 and 255" unless 1 < size < 255



    @size = size

    @setMaxListeners 2


    @grid = new Array Math.pow(@size, 3)
    for x in [0...Math.pow(@size, 3)]
      @grid
= null

    @rotation = 0

    map = @
    @blockDidChangeListener = ->
      map.emit 'didChange'

    @emit 'didChange'

  forceUpdate: ->
    @emit 'didChange'


  setBlock: (block, x, y, z, silent = no) ->
    @validateCoordinates x, y, z
    block.setCoordinates x, y, z if block

    [x, y] = @applyRotation x, y if @rotation
    position = x + y * @size + z * @size * @size

    @grid[position]?.removeListener 'didChange', @blockDidChangeListener
    @grid[position] = block
    @grid[position]?.addListener 'didChange', @blockDidChangeListener

    @emit 'didChange' unless silent


  getBlock: (x, y, z) ->
    @validateCoordinates x, y, z
    [x, y] = @applyRotation x, y if @rotation
    return @grid[x + y * @size + z * @size * @size]


  removeBlock: (x, y, z, silent = no) ->
    block = @getBlock x, y, z
    @setBlock null, x, y, z, yes

    block?.removeListener 'didChange', @blockDidChangeListener
    block?.setCoordinates null, null, null

    @emit 'didChange' unless silent

    return block


  heightAt: (x, y) ->
    @validateCoordinates x, y, 0

    height = 0
    while height < @size and @getBlock x, y, height
      height++
    return height


  getStack: (x, y, z = 0) ->
    @validateCoordinates x, y, z

    return [] if z > height = @heightAt x, y

    blocks = new Array
    for currentZ in [z...height]
      blocks.push @getBlock x, y, currentZ
    return blocks


  setStack: (blocks, x, y, z = 0, silent = no) ->
    @validateCoordinates x, y, z
    unless blocks.length - 1 + z < @size
      throw new Error "Cannot place stack, height out of bounds"

    for block in blocks
      @setBlock block, x, y, z++, yes

    @emit 'didChange' unless silent


  removeStack: (x, y, z = 0, silent = no) ->
    stack = @getStack x, y, z

    for currentZ in [z...z + stack.length]
      @setBlock null, x, y, z++, yes

    @emit 'didChange' unless silent

    return stack


  validate: ->
    @blocksEach (block) =>
      [x, y, z] = block.getCoordinates()
      if block and z > 0 and not @getBlock x, y, z - 1
        throw new Error "Encountered floating block at #{x}:#{y}:#{z}"


  validateCoordinates: (x, y, z) ->
    throw new Error "Index out of bounds #{x}:#{y}:#{z}" unless 0 <= x < @size and
                                                                0 <= y < @size and
                                                                0 <= z < @size


  applyRotation: (x, y) ->
    switch @rotation
      when  90 then return [@size - 1 - y,             x]
      when 180 then return [@size - 1 - x, @size - 1 - y]
      when 270 then return [            y, @size - 1 - x]
      else
        return [x, y]


  blocksEach: (functionToApply) ->
    x = @size - 1
    while x + 1
      y = 0
      while y < @size
        z = 0
        while z < @size
          functionToApply block if block = @getBlock(x, y, z)
          z++
        y++
      x--

  coordinatesEach: (functionToApply) ->
    x = @size - 1
    while x + 1
      y = 0
      while y < @size
        z = 0
        while z < @size
          functionToApply(x, y, z)
          z++
        y++
      x--


  rotateCW: -> @rotate true


  rotateCCW: -> @rotate false

  rotate: (clockwise, silent = no) ->
    if clockwise
      @rotation = (@rotation +  90) % 360
    else
      @rotation = (@rotation + 270) % 360

    for block in @grid
      if block
        block.rotate clockwise, yes, yes, yes, yes
        [x, y, z] = block.getCoordinates()
        if clockwise
          [x, y] = [            y, @size - 1 - x]
        else
          [x, y] = [@size - 1 - y,             x]
        block.setCoordinates x, y, z

    @emit 'didRotate', clockwise unless silen

Copyright © ZylonGaming 2009 - 2024
-Terms of Use-