PDA

View Full Version : Merged Headquarters and RPGCP


Chief Corn
03-06-2005, 02:17 AM
i know rpg v3.0 is still in beta, but i figured template calls should relatively stay the same. well i never had any reason to use the RPGCP, and with the rpg options now seperated from the user cp I thought i'd try to merge the two for my site.

i'm sure there's an easier way to do this like how it calls global.php but i don't know php, so i just took all the code in rpgcp.php and inserted into headquarters.php. since my site already has a navigation menu for the rpg, i replaced the location menu in headquarters with the stats from rgpcp into that table. not sure if there's any security problems or exploits doing this though..

here's a demo...

site: http://www.TreeThugs.com /forum/headquarters.php
user: vBorg
pass: test

the html is a bit messy since it was done in notepad. i'm still trying to find a place to put items. but the nice thing is when you update your character you can view your new stats from the same page.

i'll share the template with everyone once rpg 3.0's close to finalizing, since it requires combining rpgcp.php and headquarters.php...and i'm sure those files are still being tweaked.


other attempts: i'm trying to bring the Top 10 Player stats and the Browse Battles page into the main Battles login page for a more integrated feel.

Revan
03-06-2005, 09:56 AM
DeMiNe0 just mentioned this to me here the other day, so it should definetely be possible.
And yes, the template calls and major parts of the coding will stay the same for v3 Final, since all there is left to it is weed out bugs and complete the Monster Arena, which is a seperate file and does not require editing of any other files than admincp/index.php

I just took a look at your file, and it looks cool indeed :)
I think the items should be placed below everything you have so far, because since admins can add more item categories at will, it would be bad if the items were placed somewhere else thus maybe stretching the page.

Chief Corn
03-06-2005, 11:02 AM
thanks glad you like it. i updated the template with items in the bottom. i believe this is the first hack for 3.0? :nervous:

this is made for rpg 3.0 beta 2... so i can't guarantee it will work for future releases. also it was made for a fixed width 800x600 site...not sure how it looks in liquid (aka %).

attached i have my modified rpg_modifyrpg template to use with the combined rpgcp.php/headquarters.php file. not sure if i left anything hardcoded. everything "looks" fine when i view it in firefox...but i know the tables are screwed, and w3c is going to cry. just replace everything in your rpg_modifyrpg template with mine, and upload this headquarters.php into your forum. remember to back up. also change any links that point to rpgcp.php to headquarters.php.

i don't have enough users to have clans so i removed the option for it. and since i'm using a modified postbit i didn't have a need for the option on how to display stats in the postbit. PP isn't used at the moment so i removed it as well. in the 3rd file "removed_bits" is instructions on how to put them back in.

enjoy.

Revan
03-06-2005, 11:28 AM
Yes PP will be coming back, for Summons and Weapon Skills if I get around to doing those.
I'll tes those abit later, right now its KotOR II time :D
Thanks :)

Hm ok now testing it, and I see the table widths are abit off.
First of all let me say Im running 1280x1024
The Character Information and Create Character bits are abit wider than the header saying RPG Information.
Secondly, when first entering headquarters, the Character Battle Type is blank, it won't show itself until I select (not choose) a different class then go back.
I'm gonna attempt to fix both these bugs myself, then go wipe w3c's tears ;)

Weird... the Battle Type thingy seems to work fine on my live forum yet not on my localhost

Cyricx
03-06-2005, 03:44 PM
Ah bugger, nice work, but alot of hardcoded font colors and widths :)

I'll try to find some time this week to change those to $stylevar, unfortunately I have about 7 or 8 skins on my site so having any colors hardcoded always makes one style look like crap :P

Revan
03-06-2005, 04:17 PM
Hey Cyrix, you shouldnt work on that template
I have fixed it all.
Here's the revamped one, attached

Thanks for all your work, both o ye :)


Oh, and general update:
I reduced the query load in the new file by 3, so it is back down to an acceptable level.
I will look it over again later too

Cyricx
03-06-2005, 04:49 PM
Awesome!! Thanks tons!!

Revan
03-06-2005, 07:35 PM
Btw when you are done "vBising" it, you gonna make it XHTML compliant?
Because if you cant be bothered, then I *can* do it lol.

Chief Corn
03-06-2005, 09:50 PM
i won't really be doing much else to the compliancy of this template...using notepad from a 30" widescreen hdtv drives me crazy. wasn't thinking about the query load this template would pull...what was removed from the updated template? feel free to revise it any...i'm pretty much content with the look and feel of it on my site.

Revan
03-07-2005, 06:44 AM
What I fixed: Remember how the Character image and level stats would be pushed down, like there was a <td> with an nbsp in there?
I moved that up, and cleaned the 4 nested tables that were used to provide the first thead class info line.
I'll go make a SS of the new one, then update this post

Erm the new template looks quite fkd up in IE, I redesigned it on Firefox.
In short, bugger...

animedj
03-09-2005, 11:57 AM
here is something that I threw together, maybe not as complete as Chief Corn's new template, but atleast is going to work around with the styles in your board.

Revan
03-09-2005, 02:46 PM
Thanks, that looks sweet :)
I'm gonna XHTML validate this, then add it to the standard release (since the new template isn't released yet until it has been vBised)
I'll credit you for the template in the release thread once I update it :)
I will update the thread at next bugfix.