vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   My First "Hack" (https://vborg.vbsupport.ru/showthread.php?t=69007)

gfxhavenowner 09-02-2004 03:11 PM

My First "Hack"
 
This is my first "hack" that I have ever made. It's only template modifications, but I'm still proud of it, because I've never seen it before.

http://www.thegaminghaven.com/forums...hread.php?p=60

That's a link to any random post. Click and check out the RPG Info link :)

I know it's not very hard, but I'm still proud :)

Beermonster 09-02-2004 03:20 PM

Cool looking hack, does it automatically update it's self?

gfxhavenowner 09-02-2004 03:23 PM

Yeap.

Revan 09-02-2004 06:00 PM

Quote:

Originally Posted by gfxhavenowner
This is my first "hack" that I have ever made. It's only template modifications, but I'm still proud of it, because I've never seen it before.

http://www.thegaminghaven.com/forums...hread.php?p=60

That's a link to any random post. Click and check out the RPG Info link :)

I know it's not very hard, but I'm still proud :)

Nice, that looks tons better than the "official" user select postbit mod.
Do you mind sharing how you got it looking that way and letting me use it in the mod in my thread?
You would get credit of course :)

gfxhavenowner 09-02-2004 06:21 PM

First, I added a link in my postbit. Pick someplace that looks good, and insert this:

Code:

<div id="postmenu_rpg_$post[postid]">
                                        <script type="text/javascript"> vbmenu_register("postmenu_rpg_$post[postid]", true); </script>
<u>RPG Info</u></div>

Then, the standard postbit code looks like this:

Code:

<!-- START LEFT RPG POSTBIT BAR -->
      <br />
      <table width="100%" align="right" border="0" cellspacing="1" cellpadding="0">
        <tr>
          <td>
        </td>
        </tr>
        <tr>
          <td>&nbsp;<b> RPG stats</b></td>
        </tr>
        <tr>
          <td> $rpgclass3 RPG name: $rpname<br />
            Clan: $showuserclan<br />
            Level: $showlevel<br />
            Alignment: $rpgalign<br />
            Race: $rpgrace<br />
            <br />
            HP: $post[uhp]/$post[maxhp] <br />
            <table width="100" border="1" cellspacing="0" cellpadding="0" bordercolor="#000000">
              <tr>
                <td><img src="images/style/bar/bhg.gif" width="$hpbar%" height="9" alt="HP" /></td>
              </tr>
            </table>
            MA: $post[uma]/$post[maxma] <br />
            <table width="100" border="1" cellspacing="0" cellpadding="0" bordercolor="#000000">
              <tr>
                <td><img src="images/style/bar/bxg.gif" width="$mabar%" height="9" alt="MP" /></td>
              </tr>
            </table>
            PP: $post[upp]/$post[maxpp] <br />
            <table width="100" border="1" cellspacing="0" cellpadding="0" bordercolor="#000000">
              <tr>
                <td><img src="images/style/bar/bhb.gif" width="$ppbar%" height="9" alt="PP" /></td>
              </tr>
            </table>
            Limit: $post[uap]%<br />
            <table width="100" border="1" cellspacing="0" cellpadding="0" bordercolor="#000000">
              <tr>
                <td><img src="images/style/bar/bmb.gif" width="$apbar%" height="9" alt="Limit" /></td>
              </tr>
            </table>
            Exp: $ep% Total: $post[xp]
            <table width="100" border="1" cellspacing="0" cellpadding="0" bordercolor="#000000">
              <tr>
                <td><img src="images/style/bar/bmg.gif" width="$ep%" height="9" alt="EXP" /><img src="images/bar/bxb.gif" width="1" height="9" alt="EXP" /></td>
              </tr>
            </table>
            $rpgstatus<br />
            $inbattle<br />
$post[battles]:$post[wins]-$post[losses]-$post[draws]-$post[retreats]<br />
                  </td>
        </tr>
        <tr>
          <td><b>&nbsp; Stock Items</b></td>
                </tr>
                <tr>
                        <td>&nbsp;$post[items]</td>
                </tr>
      </table>
         
      <!-- END LEFT RPG POSTBIT BAR -->

I deleted that. Then scrolled down to the end of the postbit, right above

Code:

<if condition="$show['spacer']"><if condition="!$post['islastshown']"></div></if>$spacer_close</if>
<!-- / post #$post[postid] -->

And added this large chunk of code:

Code:

<div class="vbmenu_popup" id="postmenu_rpg_$post[postid]_menu" style="display:none">
<table cellpadding="4" cellspacing="1" border="0">

        <tr>
          <td class="thead"><b>RPG Character Stats</b></td>
        </tr>
        <tr>
          <td class="alt2"> $rpgclass3 <b>Name</b>: $rpname<br />
            <b>Clan</b>: $showuserclan<br />
            <b>Level</b>: $showlevel<br />
            <b>Alignment</b>: $rpgalign<br />
            <b>Race</b>: $rpgrace<br />
            <br />
            HP: $post[uhp]/$post[maxhp] <br />
            <table width="100" border="1" cellspacing="0" cellpadding="0" bordercolor="#000000">
              <tr>
                <td><img src="images/bar/bhg.gif" width="$hpbar%" height="9" alt="HP" /></td>
              </tr>
            </table>
            MA: $post[uma]/$post[maxma] <br />
            <table width="100" border="1" cellspacing="0" cellpadding="0" bordercolor="#000000">
              <tr>
                <td><img src="images/bar/bxg.gif" width="$mabar%" height="9" alt="MP" /></td>
              </tr>
            </table>
            PP: $post[upp]/$post[maxpp] <br />
            <table width="100" border="1" cellspacing="0" cellpadding="0" bordercolor="#000000">
              <tr>
                <td><img src="images/bar/bhb.gif" width="$ppbar%" height="9" alt="PP" /></td>
              </tr>
            </table>
            Limit: $post[uap]%<br />
            <table width="100" border="1" cellspacing="0" cellpadding="0" bordercolor="#000000">
              <tr>
                <td><img src="images/bar/bmb.gif" width="$apbar%" height="9" alt="Limit" /></td>
              </tr>
            </table>
            Exp: $ep% Total: $post[xp]
            <table width="100" border="1" cellspacing="0" cellpadding="0" bordercolor="#000000">
              <tr>
                <td><img src="images/bar/bmg.gif" width="$ep%" height="9" alt="EXP" /><img src="images/bar/bxb.gif" width="1" height="9" alt="EXP" /></td>
              </tr>
            </table>
            $rpgstatus<br />
            $inbattle<br />
$post[battles]:$post[wins]-$post[losses]-$post[draws]-$post[retreats]<br />
                  </td>
        </tr>
        <tr>
          <td class="thead"><b>Stock Items</b></td>
                </tr>
                <tr>
                        <td class="alt2">$post[items]</td>
                </tr>
</table>
</div>

I added classes into some of the td's and made some stuff that I wanted to stand out bold.

Edit : I just realized, now you can use the "new" horizontal postbit and the RPG hack :).

Revan 09-02-2004 06:45 PM

Okay, cheers :D
Tomorrow Ill fix my mod and add credits to ye ;)
And by the gods your right, it never occurred to me that this dropdown stuff = "new" postbit + rpg XD


All times are GMT. The time now is 09:01 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01005 seconds
  • Memory Usage 1,755KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (4)bbcode_code_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (6)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete