Loading...

Top
PFQ Banner

This is PokéFarm Q, a free online Pokémon collectables game.

Already a user? New to PFQ?

Single post in Site Skins: How-To, and Helpful CSS

Forum Index > PokéFarm > Guides > Site Skins: How-To, and Helpful CSS >

Hakano Riku's AvatarHakano Riku
Hakano Riku's Avatar
I figured this code might be found useful to some, so I decided to post it. A user asked me to help make the Score Badges by LycanKai work with my about me type rotation. That resulted in the following:
Score: 0
This score badge automatically updates the type each month using the code above, so the user no longer has to manually update it every month. The code is as follows:
[sc=tr-badge]Score: [inventory=TypeRace][/sc] [style] @import 'skins/user/q/b/R/type-race/__extra'; // These need to be set to match your type rotation manually. // '@tr-0' is January of 2020, 2023, 2026 etc. Adjust accordingly. // These need to be lowercase or the background will not show! @tr-0: 'fighting'; @tr-1: 'water'; @tr-2: 'dragon'; @tr-3: 'ghost'; @tr-4: 'psychic'; @tr-5: 'grass'; @tr-6: 'ice'; @tr-7: 'rock'; @tr-8: 'fairy'; @tr-9: 'dark'; @tr-10: 'bug'; @tr-11: 'electric'; @tr-12: 'poison'; @tr-13: 'flying'; @tr-14: 'steel'; @tr-15: 'ground'; @tr-16: 'normal'; @tr-17: 'fire'; // These values are needed to automatically update to the current month's type // You can manually set them if you want this to be permanent for any month @year: [datetime=y]now[/datetime]; // 1-99 @month: [datetime=n]now[/datetime]; // 1-12 .badge-type(@@type-race); // Sets the background to the type for this month .badge-text(@@type-race); // Lightens text for dark and ghost types [/style]
The '@tr-#' variables need to be adjusted to your type rotation. If you don't know yours, it can be found at the bottom of the type race page HERE. If users know how to import site skin code, all of the '@tr-#' variables as well as the '.badge();' mixins at the bottom can be moved to and imported from a site skin to reduce character count. Useful for signatures. More info on that by Aemilia in their CSS Guide in the '@import' tab. The '@year' and '@month' variables NEED to stay as they rely on BBCode, and BBCode does not work in site skins! I've not thoroughly tested it, so it could look strange if pasted in certain locations. Let me know if it does, and I will update it accordingly! It seems to work for the cases I've tested though. Hopefully some others find this useful at least ^^
Avatar of Dian Rubens from Spice & Wolf
Type Race Score: 0
Type Race Clicklist: HERE
© PokéFarm 2009-2024 (Full details)Contact | Rules | Privacy | Reviews 4.6★Get shortlink for this page