Search:

Type: Posts; User: Elysia

Search: Search took 0.08 seconds.

  1. Replies
    11
    Views
    3,181

    Both your GetTank and MoveTank functions look...

    Both your GetTank and MoveTank functions look correct.
    It would be easier if you actually provided the smallest possible compilable example of your code that you are having trouble with.
  2. Replies
    11
    Views
    3,181

    That was my point. That is what the OP is trying...

    That was my point. That is what the OP is trying to do, and I am simply saying that such a conversion will never make any sense.
    You have to explicitly tell the compiler how it makes sense by doing...
  3. Replies
    11
    Views
    3,181

    Ah, I missed that. But that one is also easy to...

    Ah, I missed that.
    But that one is also easy to answer. TankState is a type that is totally unrelated to a unsigned short. There is simply no context in which such a conversion can take place. The...
  4. Replies
    11
    Views
    3,181

    tankState is a type because of the "typedef"...

    tankState is a type because of the "typedef" before the struct. You haven't created an actual instance.
    Also, more appropriate names than a, b, c, d is recommended.
Results 1 to 4 of 4