Raised This Month: $51 Target: $400
 12% 

[ANY] MechaWare: Custom Achievements 2.0! (0.6)


Post New Thread Reply   
 
Thread Tools Display Modes
DrWagstaff
SourceMod Donor
Join Date: Apr 2010
Location: Livermore
Old 05-15-2010 , 17:27   Re: [ANY] MechaWare: Custom Achievements 2.0! (0.12)
Reply With Quote #21

Ah, watching this thread with bated breath. Can't wait for the editor.
DrWagstaff is offline
Send a message via AIM to DrWagstaff
Thraka
AlliedModders Donor
Join Date: Aug 2005
Old 05-15-2010 , 22:48   Re: [ANY] MechaWare: Custom Achievements 2.0! (0.12)
Reply With Quote #22

Mecha, I did a simple optimization on the requirement.inc file. This will reduce churn in the tons of IF statements. And will benefit when it grows in size.
Attached Files
File Type: inc requirement_optimized.inc (7.0 KB, 220 views)
Thraka is offline
Mecha the Slag
Veteran Member
Join Date: Jun 2009
Location: Denmark
Old 05-16-2010 , 04:41   Re: [ANY] MechaWare: Custom Achievements 2.0! (0.12)
Reply With Quote #23

Quote:
Originally Posted by Thraka View Post
Mecha, I did a simple optimization on the requirement.inc file. This will reduce churn in the tons of IF statements. And will benefit when it grows in size.
thank you!
__________________
Mecha the Slag is offline
Thraka
AlliedModders Donor
Join Date: Aug 2005
Old 05-16-2010 , 11:39   Re: [ANY] MechaWare: Custom Achievements 2.0! (0.12)
Reply With Quote #24

You'll want to make sure it's ok just because I didn't do a compile test and make sure I didn't mess up any logic. So just check it carefully
Thraka is offline
kwski43
Senior Member
Join Date: Mar 2009
Old 05-16-2010 , 11:54   Re: [ANY] MechaWare: Custom Achievements 2.0! (0.12)
Reply With Quote #25

I see the web part is in tf2 theme? Any chance to make it with template system? If you need help, I volunteer to help :-)
__________________
kwski43 is offline
Mecha the Slag
Veteran Member
Join Date: Jun 2009
Location: Denmark
Old 05-16-2010 , 17:39   Re: [ANY] MechaWare: Custom Achievements 2.0! (0.2)
Reply With Quote #26

WEB INTERFACE GUIDE
Preview!

Download Webinterface 0.6

The web interface is in beta. It is missing a delete feature and a lot of events and requirements.
But feel free to test it to your heart's desires so that I can improve it

1) Download the webinterface
2) Make sure you completed these steps
3) Open up connect.php and change it to your settings.
4) Open up admin/.htpasswd and change it to a new username and password. Default is "User" and "Password". If you're completely retarded like me, there's a nifty generator.
5) Upload it all to your host
6) Success! But keep in mind you still need to have your server connect to the same sql

Once the webinterface is out of beta, I'll massively clean up the first post to make it a lot more simplified (since none of the info will be required). So if you're a little lost right now then that's entirely understandable
__________________

Last edited by Mecha the Slag; 06-26-2010 at 05:09.
Mecha the Slag is offline
Mecha the Slag
Veteran Member
Join Date: Jun 2009
Location: Denmark
Old 05-16-2010 , 17:42   Re: [ANY] MechaWare: Custom Achievements 2.0! (0.2)
Reply With Quote #27

0.2
  • Added BETA web interface
  • "x is class y" now works with survivors (zoey, nick, ...)
  • Extended tf2 support
  • Added requirement optimisation by Thraka
  • Added "game" column, which can make achievements specific to a source game.

To update your sql database, simply run the following sql command:
Code:
ALTER TABLE  `mw_achievements_get_ach` ADD  `game` INT NOT NULL DEFAULT  '0'
__________________

Last edited by Mecha the Slag; 05-16-2010 at 17:46.
Mecha the Slag is offline
kwski43
Senior Member
Join Date: Mar 2009
Old 05-17-2010 , 10:13   Re: [ANY] MechaWare: Custom Achievements 2.0! (0.2)
Reply With Quote #28

admin/index.php:
see line 29 and try to do it like:
PHP Code:
    if($d) {
        foreach (
$d as $key => $value) {
            echo 
"<td><b>$key</b></td>\n";
        }
    } 
otherwise an error is shown when no achievements configured
line 126 no opening select tag for image (" echo "<select id=\"image\">"; ")
so seperated images per achievement doesnt work

and
Code:
Warning: opendir(../images/) [function.opendir]: failed to open dir: No such file or directory in /home/www/pages/jacklul.tk/subpages/l4d2/achievements/admin/index.php on line 126

Warning: closedir(): supplied argument is not a valid Directory resource in /home/www/pages/jacklul.tk/subpages/l4d2/achievements/admin/index.php on line 132
forgot to upload images dir?

Also editing an achievement adds a new one and leaves previous in db
__________________

Last edited by kwski43; 05-17-2010 at 10:31.
kwski43 is offline
Joe4evr
Member
Join Date: Apr 2010
Old 05-17-2010 , 12:06   Re: [ANY] MechaWare: Custom Achievements 2.0! (0.2)
Reply With Quote #29

Quote:
Originally Posted by Mecha the Slag View Post
WEB INTERFACE GUIDE
Preview!
Not bad, but how 'bout grouping the achievements per game?
Joe4evr is offline
Mecha the Slag
Veteran Member
Join Date: Jun 2009
Location: Denmark
Old 05-18-2010 , 13:44   Re: [ANY] MechaWare: Custom Achievements 2.0! (0.21)
Reply With Quote #30

0.21
  • Changed expire from int to text. Now supports multiple values (x|y|z...)
  • Fixed requirements being... majorly broken due to the optimisation
  • Fixed some achievements not activating proper

there also seems to be a bug with targets im unable to locate. I'll look further into it later.
__________________
Mecha the Slag is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 07:50.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode