Cytopia icon indicating copy to clipboard operation
Cytopia copied to clipboard

WIP Set tile id in map node

Open SimplyLiz opened this issue 2 years ago • 5 comments

wip...

Remaining tasks:

  • [x] Clicking on water crashes game (empty tile ID) - initial m_originCoordinate value wasn't part of the move constructor
  • [ ] Buildings can be placed multiple times
  • [ ] Check multi tiles if placement is allowed
  • [ ] Serialize origin coords

SimplyLiz avatar May 29 '22 10:05 SimplyLiz

@SimplyLiz why removed the const ? it's mainly meant for checking and it makes sense that it will be const

Because I need to use getMapNode instead of direct access and this must be a reference and I didn’t want to introduce a new function that does absolutely the same but is const

SimplyLiz avatar Jun 08 '22 11:06 SimplyLiz

@SimplyLiz why removed the const ? it's mainly meant for checking and it makes sense that it will be const

Because I need to use getMapNode instead of direct access and this must be a reference and I didn’t want to introduce a new function that does absolutely the same but is const

if it's exactly the same why not use const then ? didn't understand

Mograbi avatar Jun 08 '22 13:06 Mograbi

@SimplyLiz why removed the const ? it's mainly meant for checking and it makes sense that it will be const

Because I need to use getMapNode instead of direct access and this must be a reference and I didn’t want to introduce a new function that does absolutely the same but is const

if it's exactly the same why not use const then ? didn't understand

Because in a lot of cases we’ll need to Manipulate the mapnode objects. And in some we don’t which would need an exact duplicate of the getNode function but being const

SimplyLiz avatar Jun 13 '22 05:06 SimplyLiz

Hi! @SimplyLiz , Can I work on thie pr now? I want to fix this problem: https://github.com/CytopiaTeam/Cytopia/issues/892.

iaGuoZhi avatar Nov 25 '22 06:11 iaGuoZhi