tweaks to guide pages

Website issues & feedback. Constructive criticism is welcome.
(Guest posting is allowed under certain circumstances)
If you have a problem with certain individuals, then PM the Staff account.
kringled
Trained
Trained
Posts: 137
Joined: 16 Jan 2010, 16:53

tweaks to guide pages

Post by kringled »

While browsing the guide, I noticed a few things that could stand to be fixed up a bit:

For most of the base structures, upgraded HP's are listed the same as their original HPs. Based on the page for the Command Center, the HP/armor upgrade %s may be switched around (or alternatively, the upgraded calculations may be switched around).
For cyborgs, there's some duplication of entries right now, and I think the speeds are all listed as propulsion max speed, rather than actual. (For actual, some attempts I made at measuring them by "racing" cyborgs against other units suggests that regular cyborgs (or at least the types I tried) are close to full wheels speed of 175, and Super Cyborgs are a bit slower than full tracks speed of 125, but I made no attempt to try every cyborg type) - Figuring out the calculation might be useful here.
For VTOLs, the ROF field is a bit muddled/redudant between salvos and # of attack runs (and I think this reflects the underlying text weapons stats data) but I think this could be made clearer.
I understand that most of the data reflects 2.2.4, so probably some of this is waiting to be fixed once there's a non-beta of 2.3, but in the meantime, if there's any straightforward way for me to help out with editing of this stuff, I'd be happy to lend a hand.

Keith
User avatar
Zarel
Elite
Elite
Posts: 5770
Joined: 03 Jan 2008, 23:35
Location: Minnesota, USA

Re: tweaks to guide pages

Post by Zarel »

HP calculation is worth a look; I'll get to that in around a month.

For cyborgs, I already know that the speed calculation is wrong. It's not just propulsion max speed - it's just statistics that it ends up that way a lot (assuming the max speed is 400, any calculation between 400-100000 will make the displayed speed 400, so it makes sense you'd see "400" a lot.) I'll get around to fixing it maybe... later this year?

For VTOLs, the ROF field just holds the number of shots that can be fired per reload. First number is shots per salvo, second number is salvoes per reload.

Feel free to help out; the source code is in /trunk/tools/guidecode/.
kringled
Trained
Trained
Posts: 137
Joined: 16 Jan 2010, 16:53

Re: tweaks to guide pages

Post by kringled »

For the guidecode, is there a way to get a copy of the cache/*.inc.php files? I think they may be generated in the course of building and aren't there now. I've got a feeling I know how to fix the structure HP calculation. Cyborg speed will take a lot more digging for me to figure out how the calculation is done in the internals so that I can figure out how to change the guidecode to match.
As far as the VTOL ROF field goes, I'm more trying to figure out if there's a meaningful difference between having 2 shots in a salvo and 1 salvo per reload or having 1 shot in a salvo and 2 salvo's/reload - it seems more like a distinction without a real difference, and it might be clearer if that were collapsed into a single #.
Finally, is this the best way to communicate with you about this, or is there a different/preferred way (I ask specifically you because it seems like you are more responsible for this section of code than someone else).

Keith
User avatar
Zarel
Elite
Elite
Posts: 5770
Joined: 03 Jan 2008, 23:35
Location: Minnesota, USA

Re: tweaks to guide pages

Post by Zarel »

The cache files are generated by running generate. Make sure PHP has write access to everything. Did you read the readme? I know how to fix the structure HP calculation; I'll go do that soon.
kringled
Trained
Trained
Posts: 137
Joined: 16 Jan 2010, 16:53

Re: tweaks to guide pages

Post by kringled »

I did read the readme, but as I don't have PHP or a web server running on my computer, I've got a bit of a hurdle to cross before I can generate files myself. My thoughts on the structure HP is that the function as is only does upgrade calculations for structures with turrets, and the Command Center is the only structure on that page with a turret of a kind. (I'm just writing this to illustrate my thoughts on the problem, not because I didn't think you knew how to fix it).
As far as Cyborg speeds go: I found the raw calculations in droid.c, and they seem simple enough. Using the in game data for cyborg weights and powers, the calculated speeds for standard and super cyborgs seem to be in keeping with the speeds I measured in game. Since the r.inc.php calculations work for most unit speeds but not cyborgs, and it's essentially the same calculation for both in game, my current guess is that something about how the data for cyborgs is formatted/arrayed/labeled is causing the problem. Hence why I was asking about the cache data.

No idea yet why the cyborg page currently is kind of messed up (with many but not all units listed twice).
Keith
User avatar
Zarel
Elite
Elite
Posts: 5770
Joined: 03 Jan 2008, 23:35
Location: Minnesota, USA

Re: tweaks to guide pages

Post by Zarel »

http://www.apachefriends.org/en/xampp.html

You can download web servers for free off the internet, you know. ;)

This one streamlines the process; you just click through an installer and you have everything you need.

http://guide.wz2100.net/cache/templates.inc.txt
http://guide.wz2100.net/cache/weapons.inc.txt
http://guide.wz2100.net/cache/bodies.inc.txt
http://guide.wz2100.net/cache/propulsions.inc.txt

Here are visible copies.
kringled
Trained
Trained
Posts: 137
Joined: 16 Jan 2010, 16:53

Re: tweaks to guide pages

Post by kringled »

Thanks for the data. I actually realized (eventually) that I have apache and php already on my computer (OS X 10.5), but I had to figure out how to turn them on. They seem to be on, but I am still a bit mystified about actually generating the guide pages. I'm either missing some files (stuff generated in the course of a build?) or some concepts or something.
However, ignoring all that, I have a strong feeling that the cyborg speed calculation is wrong because the templates.inc.txt file lists the weapon weight rather than the total weight. My guess (because I haven't been able to figure out how all of this works together yet) is that normal bodies (i.e. the user entered ones under guide/u/heavycannon-python-tracks, etc) all go through the mktemplate routine, which adds those things up properly. Cyborgs (and the cyborg transport?) seem to all get loaded in as a complete template (which makes sense,since in-game you can't design them). However, that then means that the weight is not correct for the speed calculations. Cyborg transport, btw, also lists with purely maximum speed before/after upgrades. The current templates file also has some cyborgs duplicated, which is consistent with the duplicated entries in the web page table

I'll try to figure out a bit more so that I can put together a bit of a solution. I think there are two potential ways to go: one is tweaking the code that generates templates.inc.php from the data templates.txt file (so that those weights are loaded in correctly) and the other is changing the other parts of the code to do the calculation for the cyborgs. My gut instinct is that the first way is easier, if the relevant section of code has all the data at hand. In either case, my next step is to try to figure out where the relevant bits of code are.

Keith
kringled
Trained
Trained
Posts: 137
Joined: 16 Jan 2010, 16:53

Re: tweaks to guide pages

Post by kringled »

I added a ticket #1804 which has a revised version of r.inc.php that should fix these two problems.
(Structure HP calculation and cyborg speed). I've tested it as well as I can, which isn't as much as I would like.

I think that it may also be in order to change the text in a couple of guide pages to account for behavior that is different in 2.3.0 than 2.2.4 - I'm thinking that the behavior of sensor tanks (can automatically target enemy units) and the updates to keeping recycled unit experience across savegames are two topics that could be updated.

Keith