Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
API User Wishes
Author Message
Chiantii Offline
Member
***

Posts: 121
Joined: Feb 2013
Post: #11
RE: API User Wishes
(17-06-2013 02:40 AM)Nando28R Wrote:  High camp/outpost indicator

It can be like a game of where's wally finding high level camps/ outposts
Be good if a script had ability to enter what level and higher wanted and they would glow/flash same as they do when mouse hovers over them.

Will assist visually to spot the camps want to attack

That's what topper is talking about with regard to complexity.

That "flash" when you mouse over an object is another layer added to the image - for instance, https://eaassets-a.akamaihd.net/cncallia...7c42c7.png is for a GDI Command center - but only the base image. There is another spritesheet just to highlight the animated radar dish, etc.
17-06-2013 03:27 AM
 Search   Quote 
Topper42 Offline
Developer
***

Posts: 248
Joined: Dec 2011
Post: #12
RE: API User Wishes
(17-06-2013 03:27 AM)Chiantii Wrote:  
(17-06-2013 02:40 AM)Nando28R Wrote:  High camp/outpost indicator

It can be like a game of where's wally finding high level camps/ outposts
Be good if a script had ability to enter what level and higher wanted and they would glow/flash same as they do when mouse hovers over them.

Will assist visually to spot the camps want to attack

That's what topper is talking about with regard to complexity.

That "flash" when you mouse over an object is another layer added to the image - for instance, https://eaassets-a.akamaihd.net/cncallia...7c42c7.png is for a GDI Command center - but only the base image. There is another spritesheet just to highlight the animated radar dish, etc.

It is possibile and i saw such a script already.
17-06-2013 08:30 AM
 Search   Quote 
Topper42 Offline
Developer
***

Posts: 248
Joined: Dec 2011
Post: #13
RE: API User Wishes
(17-06-2013 03:15 AM)Chiantii Wrote:  
(16-06-2013 08:26 PM)Topper42 Wrote:  
(15-06-2013 10:56 PM)Chiantii Wrote:  Hey Topper - I figured I'd follow forum convention and post this here. In the other post, I asked about animating a structure or unit, and you responded indicating you guys use your own custom classes to do so. You also suggested that it would be difficult for one of us to write our own version.

Therefor, while I'm still going to give it a shot, I'd like to request that an API be added for this purpose. For instance:

Code:
this._foo = ClientLib.File.FileManager.GetInstance().GetAnimatedImage("buildings/gdi/moo");

Thanks, Topper Smile

Our effects are more complex than just an sprite sheet. They contain of multiple sprite sheet which are on different layers and have relative position in the effect and can get scaled over time, etc ...

Code:
ClientLib.Res.ResMain.GetInstance().GetGamedata().effects

There are all effects from the game in our data structure, but the properties are simplyfied.

Oh, trust me, I know. There is the _base image of the structure, then the sprite sheets for the various elements - like this one for a GDI accum: https://eaassets-a.akamaihd.net/cncallia...cdae02.png or this for a GDI Construction Yard: https://eaassets-a.akamaihd.net/cncallia...0bc67c.png . I also realize the construction yard needs the Radar sprite, among other things. Like the lower left corner of a GDI Power Plant being one of it's elements: https://eaassets-a.akamaihd.net/cncallia...3dfbfa.png

Either way, the final animated structure is being assembled by your code - so I figured you could create an API that returns that final "object", if at all possible. Just leave out the complexity of dynamic scaling if it makes things easier... make the size of the returned object one of the parameters, perhaps

Something like:

Code:
var foo = qx.ui.cncAnimated.Image(gdi/buildings/CnstrYrd", sizeModifier, etc);

Where a size modifier of '0.9' would return the animated image, only 90% of it's normal size.

Obviously not an emergency. However, since what we see as an image is already being built somewhere in ClientLib (layers sprites keyframes and all), I figure the final "structure" could be returned as a widget we can .add

Hi,

ok in that case you probably are aware of the amount of work ^^.

I'm afraid i can't or won't make engine classes public, this would result in a change of the visibility of a bunch of classes. Even if i build a wrapper around the class it wouldn't help you much, everything needs a Scene and this is created via a factory depending which browser and hardware you use. With this scene the effect will create its images and all other stuff it needs. It is just too much stuff that needed to be changed in our engine to work in qooxdoo direcly without loosing the obfuscation.

But i can explain the data structure to you so you could build your own qooxdoo classes for that, if you want. I guess this is even the easier way.
17-06-2013 08:44 AM
 Search   Quote 
Chiantii Offline
Member
***

Posts: 121
Joined: Feb 2013
Post: #14
RE: API User Wishes
Topper, explaining the structure (and giving normal property names) would be absolutely incredible - THANK YOU! Let's use the GDI Construction Yard as an example.

I see entries in ".Tech" ".buildings" and ".effects" for the construction yard. Am I missing anything? linkTypes?

I sent you a private message about the script I'm coding (it's actually more like an addon at this point), so I'd sincerely appreciate if you could explain the structure and give normal property names for the corresponding entries.

For instance, in .Tech, I see property "e" is 51, which happens to correspond to "51" in .effects, so I would assume that "e" in .Tech stands for "effect", and is mapped to .effects. However, it's mapped in "sic" as well, (I think) and I have no idea what "sic" stands for. Either way, explaining and giving the properties normal names, and ultimately going over the .effects structure so I could animate the buildings/units myself would absolutely be the most amazing thing you've ever done.

I have to admit, I'm less than a month away from taking down the fortress on my world, at which point I plan to stop playing the game for quite a while. The producers have a long long way to go before they meet player expectations.

However, because of how active and willing you are to help out developers, I plan to continue coding for a long long time, irrespective of me actively playing. Thank you again, Topper.

Just put comments inline if it makes things easier:

.Tech entry

Code:
        "1" : {
            "n" : "GDI_Construction Yard",
            "dn" : "Construction Yard",
            "dnuc" : "CONSTRUCTION YARD",
            "ds" : "Unlocks buildings and limits available Construction Slots. Storage of local resources. Stores and generates Repair Time for your Base. Unique building (cannot be placed next to other unique buildings).",
            "sds" : "Unlock buildings. Construction slots and base storage.",
            "t" : 9,
            "x" : -1,
            "y" : -1,
            "sic" : [{
                    "img" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd.png",
                    "e" : 51
                }, {
                    "img" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_dmgd.png",
                    "e" : 52
                }, {
                    "img" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_dstrd.png",
                    "e" : 53
                }
            ],
            "di" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd.png",
            "ddi" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_detail.png",
            "ci" : "baseview/gdi/buildings/CnstrCrn/CnstrCrn.png",
            "qi" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd.png",
            "ri" : null,
            "e" : 51,
            "ce" : -1,
            "pe" : -1,
            "v" : true,
            "rp" : 100,
            "s" : 1,
            "sc" : 0,
            "mc" : 0,
            "bf" : 1,
            "da" : false,
            "tp" : [],
            "trq" : [],
            "r" : [null, {
                    "rr" : [],
                    "lm" : [{
                            "i" : 79,
                            "v" : 50.0,
                            "t" : 2
                        }, {
                            "i" : 82,
                            "v" : 50.0,
                            "t" : 5
                        }, {
                            "i" : 92,
                            "v" : 4.0,
                            "t" : 14
                        }, {
                            "i" : 114,
                            "v" : 40.0,
                            "t" : 29
                        }, {
                            "i" : 127,
                            "v" : 3600.0,
                            "t" : 40
                        }, {
                            "i" : 128,
                            "v" : -1.0,
                            "t" : 38
                        }, {
                            "i" : 130,
                            "v" : 35.05,
                            "t" : 37
                        }
                    ],
                    "lr" : []
                }, {
                    "rr" : [{
                            "t" : 1,
                            "c" : 10.0
                        }
                    ],
                    "lm" : [{
                            "i" : 79,
                            "v" : 360.0,
                            "t" : 2
                        }, {
                            "i" : 82,
                            "v" : 360.0,
                            "t" : 5
                        }, {
                            "i" : 92,
                            "v" : 8.0,
                            "t" : 14
                        }, {
                            "i" : 114,
                            "v" : 260.0,
                            "t" : 29
                        }, {
                            "i" : 127,
                            "v" : 3600.0,
                            "t" : 40
                        }, {
                            "i" : 128,
                            "v" : -1.0,
                            "t" : 38
                        }, {
                            "i" : 130,
                            "v" : 38.55,
                            "t" : 37
                        }
                    ],
                    "lr" : []
                }, {
                    "rr" : [{
                            "t" : 1,
                            "c" : 15.0
                        }
                    ],
                    "lm" : [{
                            "i" : 79,
                            "v" : 1450.0,
                            "t" : 2
                        }, {
                            "i" : 82,
                            "v" : 1450.0,
                            "t" : 5
                        }, {
                            "i" : 92,
                            "v" : 14.0,
                            "t" : 14
                        }, {
                            "i" : 114,
                            "v" : 1150.0,
                            "t" : 29
                        }, {
                            "i" : 127,
                            "v" : 3600.0,
                            "t" : 40
                        }, {
                            "i" : 128,
                            "v" : -1.0,
                            "t" : 38
                        }, {
                            "i" : 130,
                            "v" : 42.41,
                            "t" : 37
                        }
                    ],
                    "lr" : []
                }, {
                    "rr" : [{
                            "t" : 1,
                            "c" : 30.0
                        }, {
                            "t" : 5,
                            "c" : 3.0
                        }
                    ],
                    "lm" : [{
                            "i" : 79,
                            "v" : 2650.0,
                            "t" : 2
                        }, {
                            "i" : 82,
                            "v" : 2650.0,
                            "t" : 5
                        }, {
                            "i" : 92,
                            "v" : 17.0,
                            "t" : 14
                        }, {
                            "i" : 114,
                            "v" : 2500.0,
                            "t" : 29
                        }, {
                            "i" : 127,
                            "v" : 3600.0,
                            "t" : 40
                        }, {
                            "i" : 128,
                            "v" : -1.0,
                            "t" : 38
                        }, {
                            "i" : 130,
                            "v" : 46.65,
                            "t" : 37
                        }
                    ],
                    "lr" : []
                }, {
                    "rr" : [{
                            "t" : 1,
                            "c" : 60.0
                        }, {
                            "t" : 5,
                            "c" : 15.0
                        }
                    ],
                    "lm" : [{
                            "i" : 79,
                            "v" : 6000.0,
                            "t" : 2
                        }, {
                            "i" : 82,
                            "v" : 6000.0,
                            "t" : 5
                        }, {
                            "i" : 92,
                            "v" : 18.0,
                            "t" : 14
                        }, {
                            "i" : 114,
                            "v" : 8000.0,
                            "t" : 29
                        }, {
                            "i" : 127,
                            "v" : 3600.0,
                            "t" : 40
                        }, {
                            "i" : 128,
                            "v" : -1.0,
                            "t" : 38
                        }, {
                            "i" : 130,
                            "v" : 51.32,
                            "t" : 37
                        }
                    ],
                    "lr" : []
                }, {
                    "rr" : [{
                            "t" : 1,
                            "c" : 440.0
                        }, {
                            "t" : 5,
                            "c" : 110.0
                        }
                    ],
                    "lm" : [{
                            "i" : 79,
                            "v" : 14400.0,
                            "t" : 2
                        }, {
                            "i" : 82,
                            "v" : 14400.0,
                            "t" : 5
                        }, {
                            "i" : 92,
                            "v" : 19.0,
                            "t" : 14
                        }, {
                            "i" : 114,
                            "v" : 19000.0,
                            "t" : 29
                        }, {
                            "i" : 127,
                            "v" : 3600.0,
                            "t" : 40
                        }, {
                            "i" : 128,
                            "v" : -1.0,
                            "t" : 38
                        }, {
                            "i" : 130,
                            "v" : 56.45,
                            "t" : 37
                        }
                    ],
                    "lr" : []
                }, {
                    "rr" : [{
                            "t" : 1,
                            "c" : 1440.0
                        }, {
                            "t" : 5,
                            "c" : 360.0
                        }
                    ],
                    "lm" : [{
                            "i" : 79,
                            "v" : 22800.0,
                            "t" : 2
                        }, {
                            "i" : 82,
                            "v" : 22800.0,
                            "t" : 5
                        }, {
                            "i" : 92,
                            "v" : 21.0,
                            "t" : 14
                        }, {
                            "i" : 114,
                            "v" : 33000.0,
                            "t" : 29
                        }, {
                            "i" : 127,
                            "v" : 3600.0,
                            "t" : 40
                        }, {
                            "i" : 128,
                            "v" : -1.0,
                            "t" : 38
                        }, {
                            "i" : 130,
                            "v" : 62.09,
                            "t" : 37
                        }
                    ],
                    "lr" : []
                }, {
                    "rr" : [{
                            "t" : 1,
                            "c" : 4400.0
                        }, {
                            "t" : 5,
                            "c" : 1100.0
                        }
                    ],
                    "lm" : [{
                            "i" : 79,
                            "v" : 33000.0,
                            "t" : 2
                        }, {
                            "i" : 82,
                            "v" : 33000.0,
                            "t" : 5
                        }, {
                            "i" : 92,
                            "v" : 23.0,
                            "t" : 14
                        }, {
                            "i" : 114,
                            "v" : 45000.0,
                            "t" : 29
                        }, {
                            "i" : 127,
                            "v" : 3600.0,
                            "t" : 40
                        }, {
                            "i" : 128,
                            "v" : -1.0,
                            "t" : 38
                        }, {
                            "i" : 130,
                            "v" : 68.3,
                            "t" : 37
                        }
                    ],
                    "lr" : []
                }, {
                    "rr" : [{
                            "t" : 1,
                            "c" : 12800.0
                        }, {
                            "t" : 5,
                            "c" : 3200.0
                        }
                    ],
                    "lm" : [{
                            "i" : 79,
                            "v" : 38000.0,
                            "t" : 2
                        }, {
                            "i" : 82,
                            "v" : 38000.0,
                            "t" : 5
                        }, {
                            "i" : 114,
                            "v" : 50000.0,
                            "t" : 29
                        }, {
                            "i" : 92,
                            "v" : 24.0,
                            "t" : 14
                        }, {
                            "i" : 127,
                            "v" : 3600.0,
                            "t" : 40
                        }, {
                            "i" : 128,
                            "v" : -1.0,
                            "t" : 38
                        }, {
                            "i" : 130,
                            "v" : 75.13,
                            "t" : 37
                        }
                    ],
                    "lr" : []
                }, {
                    "rr" : [{
                            "t" : 1,
                            "c" : 35200.0
                        }, {
                            "t" : 5,
                            "c" : 8800.0
                        }
                    ],
                    "lm" : [{
                            "i" : 79,
                            "v" : 42000.0,
                            "t" : 2
                        }, {
                            "i" : 82,
                            "v" : 42000.0,
                            "t" : 5
                        }, {
                            "i" : 114,
                            "v" : 55000.0,
                            "t" : 29
                        }, {
                            "i" : 92,
                            "v" : 25.0,
                            "t" : 14
                        }, {
                            "i" : 127,
                            "v" : 3600.0,
                            "t" : 40
                        }, {
                            "i" : 128,
                            "v" : -1.0,
                            "t" : 38
                        }, {
                            "i" : 130,
                            "v" : 82.64,
                            "t" : 37
                        }
                    ],
                    "lr" : []
                }, {
                    "rr" : [{
                            "t" : 1,
                            "c" : 89600.0
                        }, {
                            "t" : 5,
                            "c" : 22400.0
                        }
                    ],
                    "lm" : [{
                            "i" : 79,
                            "v" : 50000.0,
                            "t" : 2
                        }, {
                            "i" : 82,
                            "v" : 50000.0,
                            "t" : 5
                        }, {
                            "i" : 114,
                            "v" : 66000.0,
                            "t" : 29
                        }, {
                            "i" : 92,
                            "v" : 26.0,
                            "t" : 14
                        }, {
                            "i" : 127,
                            "v" : 3600.0,
                            "t" : 40
                        }, {
                            "i" : 128,
                            "v" : -1.0,
                            "t" : 38
                        }, {
                            "i" : 130,
                            "v" : 90.91,
                            "t" : 37
                        }
                    ],
                    "lr" : []
                }, {
                    "rr" : [{
                            "t" : 1,
                            "c" : 192000.0
                        }, {
                            "t" : 5,
                            "c" : 48000.0
                        }
                    ],
                    "lm" : [{
                            "i" : 79,
                            "v" : 60000.0,
                            "t" : 2
                        }, {
                            "i" : 82,
                            "v" : 60000.0,
                            "t" : 5
                        }, {
                            "i" : 114,
                            "v" : 75000.0,
                            "t" : 29
                        }, {
                            "i" : 92,
                            "v" : 27.0,
                            "t" : 14
                        }, {
                            "i" : 127,
                            "v" : 3600.0,
                            "t" : 40
                        }, {
                            "i" : 128,
                            "v" : -1.0,
                            "t" : 38
                        }, {
                            "i" : 130,
                            "v" : 100.0,
                            "t" : 37
                        }
                    ],
                    "lr" : []
                }
            ],
            "tr" : null,
            "pg" : [],
            "f" : 1,
            "c" : 112
        },

.buildings entry:

Code:
        "1" : {
            "n" : "GDI_Construction Yard",
            "dn" : "Construction Yard",
            "ds" : "Unlocks buildings and limits available Construction Slots. Storage of local resources. Stores and generates Repair Time for your Base. Unique building (cannot be placed next to other unique buildings).",
            "t" : 9,
            "mimg" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd.png",
            "x" : -2,
            "y" : -2,
            "pg" : [],
            "r" : {
                "1" : {
                    "r" : [{
                            "t" : 1,
                            "c" : 0
                        }, {
                            "t" : 2,
                            "c" : 0
                        }
                    ]
                },
                "2" : {
                    "r" : [{
                            "t" : 1,
                            "c" : 10
                        }, {
                            "t" : 2,
                            "c" : 0
                        }
                    ]
                },
                "3" : {
                    "r" : [{
                            "t" : 1,
                            "c" : 15
                        }, {
                            "t" : 2,
                            "c" : 0
                        }
                    ]
                },
                "4" : {
                    "r" : [{
                            "t" : 1,
                            "c" : 30
                        }, {
                            "t" : 2,
                            "c" : 0
                        }
                    ]
                },
                "5" : {
                    "r" : [{
                            "t" : 1,
                            "c" : 60
                        }, {
                            "t" : 2,
                            "c" : 0
                        }
                    ]
                },
                "6" : {
                    "r" : [{
                            "t" : 1,
                            "c" : 440
                        }, {
                            "t" : 2,
                            "c" : 0
                        }
                    ]
                },
                "7" : {
                    "r" : [{
                            "t" : 1,
                            "c" : 1440
                        }, {
                            "t" : 2,
                            "c" : 0
                        }
                    ]
                },
                "8" : {
                    "r" : [{
                            "t" : 1,
                            "c" : 4400
                        }, {
                            "t" : 2,
                            "c" : 0
                        }
                    ]
                },
                "9" : {
                    "r" : [{
                            "t" : 1,
                            "c" : 12800
                        }, {
                            "t" : 2,
                            "c" : 0
                        }
                    ]
                },
                "10" : {
                    "r" : [{
                            "t" : 1,
                            "c" : 35200
                        }, {
                            "t" : 2,
                            "c" : 0
                        }
                    ]
                },
                "11" : {
                    "r" : [{
                            "t" : 1,
                            "c" : 89600
                        }, {
                            "t" : 2,
                            "c" : 0
                        }
                    ]
                },
                "12" : {
                    "r" : [{
                            "t" : 1,
                            "c" : 192000
                        }, {
                            "t" : 2,
                            "c" : 0
                        }
                    ]
                }
            },
            "rp" : 100,
            "c" : 112
        },

.effects entry

Code:
        "51" : {
            "a" : {
                "0" : {
                    "l" : 16000.0,
                    "r" : 2,
                    "d" : [{
                            "x" : [0.0, 1.0, 1000.0, 15.999, 1400.0, 15.999, 2600.0, 1.0, 3000.0, 1.0, 4000.0, 16.0],
                            "t" : 2,
                            "m" : 8,
                            "p" : 2,
                            "l" : true
                        }, {
                            "x" : [0.0, 1.0, 100.0, 2.0, 900.0, 7.0, 1000.0, 7.99902, 1100.0, 7.0, 1900.0, 1.0, 2000.0, 1.0, 2100.0, 2.0, 3900.0, 17.0, 4000.0, 18.0, 4100.0, 17.0, 4900.0, 13.0, 5000.0, 12.0, 5100.0, 13.0, 6900.0, 29.0, 7000.0, 30.0, 7100.0, 29.0, 7900.0, 23.0, 8000.0, 22.0, 8100.00049, 23.0, 8900.0, 29.0, 9000.0, 30.0, 9100.0, 29.0, 10800.0, 15.0, 10900.0, 14.0, 11000.0, 15.0, 13500.0, 15.0, 13600.0, 14.0, 13700.0, 15.0, 14400.0, 20.0, 14500.0, 21.0, 14600.0, 21.0, 15900.0, 2.0, 16000.0, 1.0],
                            "t" : 3,
                            "m" : 8,
                            "p" : 2,
                            "l" : true
                        }
                    ],
                    "dt" : [{
                            "t" : 4,
                            "m" : 8,
                            "p" : 2,
                            "d" : 1
                        }
                    ]
                }
            },
            "l" : 16000.0,
            "ec" : 5,
            "w" : 141.0,
            "h" : 125.0,
            "e" : [{
                    "x" : 70.0,
                    "y" : 62.0,
                    "w" : 141.0,
                    "h" : 125.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_base.png",
                    "f" : 0,
                    "t" : 1
                }, {
                    "x" : 70.0,
                    "y" : 62.0,
                    "w" : 141.0,
                    "h" : 125.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_base_mo.png",
                    "f" : 0,
                    "t" : 1
                }, {
                    "x" : 77.0,
                    "y" : 40.0,
                    "w" : 56.0,
                    "h" : 38.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_anim.png",
                    "f" : 16,
                    "t" : 1
                }, {
                    "x" : 86.0,
                    "y" : 14.0,
                    "w" : 50.0,
                    "h" : 44.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_radar_anim.png",
                    "f" : 30,
                    "t" : 1
                }, {
                    "x" : 86.0,
                    "y" : 14.0,
                    "w" : 50.0,
                    "h" : 44.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_radar_anim_mo.png",
                    "f" : 30,
                    "t" : 1
                }
            ],
            "s" : null,
            "px" : 133.0,
            "py" : 117.0,
            "he" : [1, 4],
            "lo" : {}

        },

That one has 2 entries in "d" and 5 entries in "e" - "52" aka damaged construction yard has 8 and 8? I hope you explain well Smile You're amazing, Topper.
17-06-2013 11:49 AM
 Search   Quote 
Topper42 Offline
Developer
***

Posts: 248
Joined: Dec 2011
Post: #15
RE: API User Wishes
OK Here we go:

Tech entry: "e" is indeed the effectId from the effects array. "sic" contains the different damage state and fallback graphics if there would no effect but all tech should have one Wink .

Buildings: please ignore, don't know why this is still in will remove this asap ^^.

and now the important part:
Code:
"51" : {
            "a" : { // Animations, are basically different storyboard within one effect
                "0" : { // animation driver
                    "l" : 16000.0, // length
                    "r" : 2, // LoopMode
                    "d" : [{ // Animation Driver
                            "x" : [0.0, 1.0, 1000.0, 15.999, 1400.0, 15.999, 2600.0, 1.0, 3000.0, 1.0, 4000.0, 16.0], // XKeyFrames more like interpolation values
                            "t" : 2, // Target (element id from "e")
                            "m" : 8, // Method (1:Position, 2:Opacity, 3:X, 4:Y, 5:Width, 6:Height, 7:rotation: 8:CurrentFrame)
                            "p" : 2, // ProviderType (only 2 is used right now and means interpolation of one value)
                            "l" : true // loop
                        }, {
                            "x" : [0.0, 1.0, 100.0, 2.0, 900.0, 7.0, 1000.0, 7.99902, 1100.0, 7.0, 1900.0, 1.0, 2000.0, 1.0, 2100.0, 2.0, 3900.0, 17.0, 4000.0, 18.0, 4100.0, 17.0, 4900.0, 13.0, 5000.0, 12.0, 5100.0, 13.0, 6900.0, 29.0, 7000.0, 30.0, 7100.0, 29.0, 7900.0, 23.0, 8000.0, 22.0, 8100.00049, 23.0, 8900.0, 29.0, 9000.0, 30.0, 9100.0, 29.0, 10800.0, 15.0, 10900.0, 14.0, 11000.0, 15.0, 13500.0, 15.0, 13600.0, 14.0, 13700.0, 15.0, 14400.0, 20.0, 14500.0, 21.0, 14600.0, 21.0, 15900.0, 2.0, 16000.0, 1.0],
                            "t" : 3,
                            "m" : 8,
                            "p" : 2,
                            "l" : true
                        }
                    ],
                    "dt" : [{ // Additional Animation Driver (normally highlights which use the same values as the driver(DriverId))
                            "t" : 4, // Target
                            "m" : 8, // Method
                            "p" : 2, // ProviderType
                            "d" : 1 // DriverId
                        }
                    ]
                }
            },
            "l" : 16000.0, // length
            "ec" : 5, // Element Count of "e"
            "w" : 141.0, // width
            "h" : 125.0, // height
            "e" : [{ // elements
                    "x" : 70.0, // x
                    "y" : 62.0, // y
                    "w" : 141.0, // width
                    "h" : 125.0, // heihgt
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_base.png", // source
                    "f" : 0, // additional frames
                    "t" : 1 // type (image:1, group:2, text:3)
                }, {
                    "x" : 70.0,
                    "y" : 62.0,
                    "w" : 141.0,
                    "h" : 125.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_base_mo.png",
                    "f" : 0,
                    "t" : 1
                }, {
                    "x" : 77.0,
                    "y" : 40.0,
                    "w" : 56.0,
                    "h" : 38.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_anim.png",
                    "f" : 16,
                    "t" : 1
                }, {
                    "x" : 86.0,
                    "y" : 14.0,
                    "w" : 50.0,
                    "h" : 44.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_radar_anim.png",
                    "f" : 30,
                    "t" : 1
                }, {
                    "x" : 86.0,
                    "y" : 14.0,
                    "w" : 50.0,
                    "h" : 44.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_radar_anim_mo.png",
                    "f" : 30,
                    "t" : 1
                }
            ],
            "s" : null, // start parameters
            "px" : 133.0, // pivot x
            "py" : 117.0, // pivot y
            "he" : [1, 4], // highlight elements (white outline)
            "lo" : {} // locators for rotation of weapons, normally only units

        },
17-06-2013 03:03 PM
 Search   Quote 
Nando28R Offline
Peace Brada
*****

Posts: 1,515
Joined: Mar 2012
Post: #16
RE: API User Wishes
You guys are too smart for me lol

Back to the shadows I go on this Tongue
18-06-2013 06:42 AM
 Search   Quote 
Chiantii Offline
Member
***

Posts: 121
Joined: Feb 2013
Post: #17
RE: API User Wishes
(17-06-2013 03:03 PM)Topper42 Wrote:  OK Here we go:

Tech entry: "e" is indeed the effectId from the effects array. "sic" contains the different damage state and fallback graphics if there would no effect but all tech should have one Wink .

Buildings: please ignore, don't know why this is still in will remove this asap ^^.

and now the important part:
Code:
"51" : {
            "a" : { // Animations, are basically different storyboard within one effect
                "0" : { // animation driver
                    "l" : 16000.0, // length
                    "r" : 2, // LoopMode
                    "d" : [{ // Animation Driver
                            "x" : [0.0, 1.0, 1000.0, 15.999, 1400.0, 15.999, 2600.0, 1.0, 3000.0, 1.0, 4000.0, 16.0], // XKeyFrames more like interpolation values
                            "t" : 2, // Target (element id from "e")
                            "m" : 8, // Method (1:Position, 2:Opacity, 3:X, 4:Y, 5:Width, 6:Height, 7:rotation: 8:CurrentFrame)
                            "p" : 2, // ProviderType (only 2 is used right now and means interpolation of one value)
                            "l" : true // loop
                        }, {
                            "x" : [0.0, 1.0, 100.0, 2.0, 900.0, 7.0, 1000.0, 7.99902, 1100.0, 7.0, 1900.0, 1.0, 2000.0, 1.0, 2100.0, 2.0, 3900.0, 17.0, 4000.0, 18.0, 4100.0, 17.0, 4900.0, 13.0, 5000.0, 12.0, 5100.0, 13.0, 6900.0, 29.0, 7000.0, 30.0, 7100.0, 29.0, 7900.0, 23.0, 8000.0, 22.0, 8100.00049, 23.0, 8900.0, 29.0, 9000.0, 30.0, 9100.0, 29.0, 10800.0, 15.0, 10900.0, 14.0, 11000.0, 15.0, 13500.0, 15.0, 13600.0, 14.0, 13700.0, 15.0, 14400.0, 20.0, 14500.0, 21.0, 14600.0, 21.0, 15900.0, 2.0, 16000.0, 1.0],
                            "t" : 3,
                            "m" : 8,
                            "p" : 2,
                            "l" : true
                        }
                    ],
                    "dt" : [{ // Additional Animation Driver (normally highlights which use the same values as the driver(DriverId))
                            "t" : 4, // Target
                            "m" : 8, // Method
                            "p" : 2, // ProviderType
                            "d" : 1 // DriverId
                        }
                    ]
                }
            },
            "l" : 16000.0, // length
            "ec" : 5, // Element Count of "e"
            "w" : 141.0, // width
            "h" : 125.0, // height
            "e" : [{ // elements
                    "x" : 70.0, // x
                    "y" : 62.0, // y
                    "w" : 141.0, // width
                    "h" : 125.0, // heihgt
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_base.png", // source
                    "f" : 0, // additional frames
                    "t" : 1 // type (image:1, group:2, text:3)
                }, {
                    "x" : 70.0,
                    "y" : 62.0,
                    "w" : 141.0,
                    "h" : 125.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_base_mo.png",
                    "f" : 0,
                    "t" : 1
                }, {
                    "x" : 77.0,
                    "y" : 40.0,
                    "w" : 56.0,
                    "h" : 38.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_anim.png",
                    "f" : 16,
                    "t" : 1
                }, {
                    "x" : 86.0,
                    "y" : 14.0,
                    "w" : 50.0,
                    "h" : 44.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_radar_anim.png",
                    "f" : 30,
                    "t" : 1
                }, {
                    "x" : 86.0,
                    "y" : 14.0,
                    "w" : 50.0,
                    "h" : 44.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_radar_anim_mo.png",
                    "f" : 30,
                    "t" : 1
                }
            ],
            "s" : null, // start parameters
            "px" : 133.0, // pivot x
            "py" : 117.0, // pivot y
            "he" : [1, 4], // highlight elements (white outline)
            "lo" : {} // locators for rotation of weapons, normally only units

        },

Topper - I'm almost done, thanks again for your help. I wish you would have just told me the information is based off .xaml files from the start! I do a LOT of work with xaml and Blend in my existing job!

One last question - what is the difference, if any, between:

https://prodgame05.alliances.commandandc...tryrd.xaml

and

https://prodgame05.alliances.commandandc...dg_fx.xaml

They both seem to be the same??
27-06-2013 07:41 AM
 Search   Quote 
Topper42 Offline
Developer
***

Posts: 248
Joined: Dec 2011
Post: #18
RE: API User Wishes
(27-06-2013 07:41 AM)Chiantii Wrote:  
(17-06-2013 03:03 PM)Topper42 Wrote:  OK Here we go:

Tech entry: "e" is indeed the effectId from the effects array. "sic" contains the different damage state and fallback graphics if there would no effect but all tech should have one Wink .

Buildings: please ignore, don't know why this is still in will remove this asap ^^.

and now the important part:
Code:
"51" : {
            "a" : { // Animations, are basically different storyboard within one effect
                "0" : { // animation driver
                    "l" : 16000.0, // length
                    "r" : 2, // LoopMode
                    "d" : [{ // Animation Driver
                            "x" : [0.0, 1.0, 1000.0, 15.999, 1400.0, 15.999, 2600.0, 1.0, 3000.0, 1.0, 4000.0, 16.0], // XKeyFrames more like interpolation values
                            "t" : 2, // Target (element id from "e")
                            "m" : 8, // Method (1:Position, 2:Opacity, 3:X, 4:Y, 5:Width, 6:Height, 7:rotation: 8:CurrentFrame)
                            "p" : 2, // ProviderType (only 2 is used right now and means interpolation of one value)
                            "l" : true // loop
                        }, {
                            "x" : [0.0, 1.0, 100.0, 2.0, 900.0, 7.0, 1000.0, 7.99902, 1100.0, 7.0, 1900.0, 1.0, 2000.0, 1.0, 2100.0, 2.0, 3900.0, 17.0, 4000.0, 18.0, 4100.0, 17.0, 4900.0, 13.0, 5000.0, 12.0, 5100.0, 13.0, 6900.0, 29.0, 7000.0, 30.0, 7100.0, 29.0, 7900.0, 23.0, 8000.0, 22.0, 8100.00049, 23.0, 8900.0, 29.0, 9000.0, 30.0, 9100.0, 29.0, 10800.0, 15.0, 10900.0, 14.0, 11000.0, 15.0, 13500.0, 15.0, 13600.0, 14.0, 13700.0, 15.0, 14400.0, 20.0, 14500.0, 21.0, 14600.0, 21.0, 15900.0, 2.0, 16000.0, 1.0],
                            "t" : 3,
                            "m" : 8,
                            "p" : 2,
                            "l" : true
                        }
                    ],
                    "dt" : [{ // Additional Animation Driver (normally highlights which use the same values as the driver(DriverId))
                            "t" : 4, // Target
                            "m" : 8, // Method
                            "p" : 2, // ProviderType
                            "d" : 1 // DriverId
                        }
                    ]
                }
            },
            "l" : 16000.0, // length
            "ec" : 5, // Element Count of "e"
            "w" : 141.0, // width
            "h" : 125.0, // height
            "e" : [{ // elements
                    "x" : 70.0, // x
                    "y" : 62.0, // y
                    "w" : 141.0, // width
                    "h" : 125.0, // heihgt
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_base.png", // source
                    "f" : 0, // additional frames
                    "t" : 1 // type (image:1, group:2, text:3)
                }, {
                    "x" : 70.0,
                    "y" : 62.0,
                    "w" : 141.0,
                    "h" : 125.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_base_mo.png",
                    "f" : 0,
                    "t" : 1
                }, {
                    "x" : 77.0,
                    "y" : 40.0,
                    "w" : 56.0,
                    "h" : 38.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_anim.png",
                    "f" : 16,
                    "t" : 1
                }, {
                    "x" : 86.0,
                    "y" : 14.0,
                    "w" : 50.0,
                    "h" : 44.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_radar_anim.png",
                    "f" : 30,
                    "t" : 1
                }, {
                    "x" : 86.0,
                    "y" : 14.0,
                    "w" : 50.0,
                    "h" : 44.0,
                    "s" : "baseview/gdi/buildings/CnstrYrd/CnstrYrd_radar_anim_mo.png",
                    "f" : 30,
                    "t" : 1
                }
            ],
            "s" : null, // start parameters
            "px" : 133.0, // pivot x
            "py" : 117.0, // pivot y
            "he" : [1, 4], // highlight elements (white outline)
            "lo" : {} // locators for rotation of weapons, normally only units

        },

Topper - I'm almost done, thanks again for your help. I wish you would have just told me the information is based off .xaml files from the start! I do a LOT of work with xaml and Blend in my existing job!

One last question - what is the difference, if any, between:

https://prodgame05.alliances.commandandc...tryrd.xaml

and

https://prodgame05.alliances.commandandc...dg_fx.xaml

They both seem to be the same??

Hi,

I think the first one isn't used.

These files shouldn't be on the servers anyway ^^, i will let them remove asap.

Cheers
27-06-2013 09:19 AM
 Search   Quote 
Chiantii Offline
Member
***

Posts: 121
Joined: Feb 2013
Post: #19
RE: API User Wishes
(27-06-2013 09:19 AM)Topper42 Wrote:  Hi,

I think the first one isn't used.

These files shouldn't be on the servers anyway ^^, i will let them remove asap.

Cheers

Ha! So you're going to tell your bosses they should hire me now, right? Smile You're welcome! So far I've exposed this to you, and the fact that GAMEDATA.buildings is still being downloaded when it shouldn't Smile

I've gone over ClientLib.js, webfrontend.js and all of GAMEDATA[] from top to bottom - there is a LOT of redundant data which could significantly improve the loading time of the game. For instance, some files are being downloaded twice, and other developers have been lazy so things like "webfrontend/baseview/neutral/res_tiberium_01_fx - Copy.xaml" are still there.

But the worst performance hit of all is the forums if you're an officer+ in an alliance with a lot of diplomatic relations. You really need to do something about that Smile

So should I sent you my resume? Smile
27-06-2013 08:21 PM
 Search   Quote 
Topper42 Offline
Developer
***

Posts: 248
Joined: Dec 2011
Post: #20
RE: API User Wishes
(27-06-2013 08:21 PM)Chiantii Wrote:  
(27-06-2013 09:19 AM)Topper42 Wrote:  Hi,

I think the first one isn't used.

These files shouldn't be on the servers anyway ^^, i will let them remove asap.

Cheers

Ha! So you're going to tell your bosses they should hire me now, right? Smile You're welcome! So far I've exposed this to you, and the fact that GAMEDATA.buildings is still being downloaded when it shouldn't Smile

I've gone over ClientLib.js, webfrontend.js and all of GAMEDATA[] from top to bottom - there is a LOT of redundant data which could significantly improve the loading time of the game. For instance, some files are being downloaded twice, and other developers have been lazy so things like "webfrontend/baseview/neutral/res_tiberium_01_fx - Copy.xaml" are still there.

But the worst performance hit of all is the forums if you're an officer+ in an alliance with a lot of diplomatic relations. You really need to do something about that Smile

So should I sent you my resume? Smile

It is actually really frustrating that such stuff is still happening ^^, and only comes to day light by the users.

That buildings are still in the gamedata is a relict from Lord of Ultima ^^, i already removed it our dev version.

Of course we can do a lot of improvements but our producer have other stuff that comes first Wink. So it is not always the developers that are lazy Wink.

If you want to sent in your resume feel free: http://www.phenomic.de/jobs.php
28-06-2013 08:29 AM
 Search   Quote 


Forum Jump:


User(s) browsing this thread: