Author Topic: Special thing for Evilzone Christmas, 2013  (Read 3600 times)

0 Members and 1 Guest are viewing this topic.

Offline Kulverstukas

  • Administrator
  • Zeus
  • *
  • Posts: 6627
  • Cookies: 542
  • Fascist dictator
    • View Profile
    • My blog
Special thing for Evilzone Christmas, 2013
« on: December 24, 2013, 10:51:21 am »
Hello,

Christmas is tomorrow, but it's been decided to post it today :)
The staff tries to always do something special for EZ every christmas, this year was a tough one, but all in all it seemed like a good thing, EZ is striving!. The gift was done by Daxda and me.

This year it is something personal. Seeing how bluechill stirred the whole thing about avatars being "personal faces on the web" discussion, and many people agreed.
We thought it would be a very nice gesture to make something out of those personal faces of the web, as a thanks to the whole community of active (and not so active) members. If you had at least few posts AND had an avatar, you should find yourself in there :)

And here it is, the gift!: http://i.imgur.com/jCNY9yK.jpg

Whole project: http://upload.evilzone.org/download.php?id=4556409&type=zip

Scripts used for the project:

Code: (python) [Select]
'''
    Script that extracts nickname and profile link
    from sensitive data cluster that is available to the admins.
    Data file is not included, fuck you.
'''
import re

DATA_FILE   = "data.txt"
OUTPUT_FILE = "output.txt"
CHECK_BY    = "profile"
URL_RE_PATTERN = "http://evilzone.org/profile/\?u=\d+"
NAME_RE_PATTERN = "\">.+?</a>"

inF = open(DATA_FILE, "r")
outF = open(OUTPUT_FILE, "w")

passed = False
finalStr = ""
counter = 0
for line in inF:
    if ((CHECK_BY in line) and passed):
        passed = False
        counter += 1
        nameMatchObj = re.search(NAME_RE_PATTERN, line)
        urlMatchObj = re.search(URL_RE_PATTERN, line)
        if ((urlMatchObj != None) and (nameMatchObj != None)):
            finalStr = "%d;%s;%s" % (counter,
                       nameMatchObj.group(0).replace("\">", "").replace("</a>", ""),
                       urlMatchObj.group(0))
            outF.write(finalStr+"\n")
            print finalStr+"\n"
    else:
        passed = True

inF.close()
outF.close()

Code: (python) [Select]
'''
    Author: Kulverstukas
    Website: http://9v.lt
    Date: 2013.12.08
    Description:
        This script is part of a project for 2013 Evilzone christmas.
        What it does is gathers user's avatars and downloads them.
'''
import os
import re
import urllib
import urllib2

#=== CONSTANTS ===
AVATAR_FOLDER = "EZ_Avatars"
INPUT_FILE    = "output.txt"
AVATAR_RE     = "<img class=\"avatar\".+?/>"
DEFAULT_EXT   = "png"
#=================
def readAndStructure():
    print "========= STRUCTURING THE FILE ========="
    finalArr = []
    with open(INPUT_FILE, "r") as f:
        for line in f:
            dataArr = line.strip().split(";")
            finalArr.append(dataArr)
    return finalArr
#=================
def grabAvatars(dataArr):
    print "========= GRABBING AVATARS ========="
    for item in dataArr:
        print "Retrieving avatar for "+item[1]
        try:
            urllib.urlretrieve(item[2], "%s/%s - %s.%s" % (AVATAR_FOLDER, item[0], item[1], DEFAULT_EXT))
        except:
            print "*** Failed retrieving. Continuing..."
#=================
def extractAvatarUrl(dataArr):
    print "========= EXTRACTING AVATAR URLs ========="
    finalArr = []
    tmpArr = []
    for item in dataArr:
        tmpArr = []
        resp = urllib2.urlopen(item[2])
        html = resp.read()
        avatarUrlMatchObj = re.search(AVATAR_RE, html)
        if (avatarUrlMatchObj != None):
            tmpArr.append(item[0])
            tmpArr.append(item[1])
            tmpArr.append(avatarUrlMatchObj.group(0)
                          .replace("<img class=\"avatar\" src=\"", "")
                          .replace("\" alt=\"\" />", "")
                          .replace("\" width=\"100\" height=\"100", ""))
            finalArr.append(tmpArr)
        else:
            print "No avatar found for "+item[1]
#            break;
           
    return finalArr
#=================
def main():
    if (os.path.exists(AVATAR_FOLDER) == False):
        os.mkdir(AVATAR_FOLDER)
    dataArr = readAndStructure()
    dataArr = extractAvatarUrl(dataArr)
    grabAvatars(dataArr)
#=================

main()

Offline geXXos

  • Royal Highness
  • ****
  • Posts: 646
  • Cookies: 178
    • View Profile
Re: Special thing for Evilzone Christmas, 2013
« Reply #1 on: December 24, 2013, 01:11:04 pm »
This is nice, too bad Axon and me we don't have an avatar.

Cookies for you Kulver and Daxda  +1

And merry Christmas.

Offline bluechill

  • Cybermancer
  • Royal Highness
  • ****
  • Posts: 682
  • Cookies: 344
  • I am the existence in these walls
    • View Profile
Re: Special thing for Evilzone Christmas, 2013
« Reply #2 on: December 24, 2013, 03:31:25 pm »
<3
I have dreamed a dream, but now that dream has gone from me.  In its place now exists my own reality, a reality which I have created for myself by myself.

Offline Matriplex

  • Knight
  • **
  • Posts: 323
  • Cookies: 66
  • Java
    • View Profile
Re: Special thing for Evilzone Christmas, 2013
« Reply #3 on: December 24, 2013, 05:54:17 pm »
Very cool, I like that you made a script for it as well!
Merry Christmas to you guys  :)
\x64\x6F\x75\x65\x76\x65\x6E\x00

Offline uNk

  • Knight
  • **
  • Posts: 197
  • Cookies: 9
    • View Profile
Re: Special thing for Evilzone Christmas, 2013
« Reply #4 on: December 24, 2013, 06:00:00 pm »
<3

Offline Axon

  • VIP
  • King
  • *
  • Posts: 2047
  • Cookies: 319
    • View Profile
Re: Special thing for Evilzone Christmas, 2013
« Reply #5 on: December 24, 2013, 09:58:31 pm »
This is nice, too bad Axon and me we don't have an avatar.

Cookies for you Kulver and Daxda  +1

And merry Christmas.


Yeah I was gonna say the same thing. Anyway, I don't celebrate Christmas and it doesn't interest me at all, but I wish you all happy holidays no matter where you live.
 8)

Offline proxx

  • Avatarception
  • Global Moderator
  • Titan
  • *
  • Posts: 2803
  • Cookies: 256
  • ФФФ
    • View Profile
Re: Special thing for Evilzone Christmas, 2013
« Reply #6 on: December 24, 2013, 10:05:59 pm »
Cute :)
Thanks for that warm present Daxda And Kulverstukas.
I gotta say Daxda you are A true new EZ member, we dont have those alot.
Coz its this time of year we can spread some postive :)

Anyways merry something to you all , good to be here my friends.
Wtf where you thinking with that signature? - Phage.
This was another little experiment *evillaughter - Proxx.
Evilception... - Phage

Offline lucid

  • #Underground
  • Titan
  • **
  • Posts: 2683
  • Cookies: 243
  • psychonaut
    • View Profile
Re: Special thing for Evilzone Christmas, 2013
« Reply #7 on: December 25, 2013, 02:55:43 am »
I'm right next to Faction because we are in love. :P   Awesome idea. This makes me feel special. Merry Christmas mother fuckers!
« Last Edit: December 25, 2013, 02:55:59 am by lucid »
"Hacking is at least as much about ideas as about computers and technology. We use our skills to open doors that should never have been shut. We open these doors not only for our own benefit but for the benefit of others, too." - Brian the Hacker

Quote
15:04  @Phage : I'm bored of Python

Offline Sensei-Shun-Null

  • Serf
  • *
  • Posts: 41
  • Cookies: 5
  • Stay tuned for more
    • View Profile
Re: Special thing for Evilzone Christmas, 2013
« Reply #8 on: December 25, 2013, 08:00:00 am »
D'aww Thanks Lol Merry Christmas and a happy New Years :P

Offline Snayler

  • Baron
  • ****
  • Posts: 812
  • Cookies: 135
    • View Profile
Re: Special thing for Evilzone Christmas, 2013
« Reply #9 on: December 25, 2013, 03:59:47 pm »
Thank you guys, it's set as my wallpaper. Merry Christmas to you all!

Offline Darkvision

  • EZ's Fluffer
  • VIP
  • Royal Highness
  • *
  • Posts: 755
  • Cookies: 149
  • Its not a bug, It's a Chilopodas.
    • View Profile
Re: Special thing for Evilzone Christmas, 2013
« Reply #10 on: December 25, 2013, 11:04:16 pm »
heh nice job guys. cookies all around. hope you got good loot, and good family/friends.
The internet: where men are men, women are men, and children are FBI agents.

Ahh, EvilZone.  Where networking certification meets avian fecal matter & all is explained, for better or worse.

<Phage> I used an entrence I never use

Offline IFailStuff

  • VIP
  • Knight
  • *
  • Posts: 338
  • Cookies: 25
  • Certified fuckup
    • View Profile
Re: Special thing for Evilzone Christmas, 2013
« Reply #11 on: December 26, 2013, 12:10:58 am »
Oh wow, good job! This is cool :)

Offline theellimist

  • Knight
  • **
  • Posts: 371
  • Cookies: 17
    • View Profile
    • TheEllimist's Game
Re: Special thing for Evilzone Christmas, 2013
« Reply #12 on: December 28, 2013, 02:56:55 am »
Whoa that is really awesome!

Offline ande

  • Owner
  • Titan
  • *
  • Posts: 2664
  • Cookies: 256
    • View Profile
Re: Special thing for Evilzone Christmas, 2013
« Reply #13 on: December 28, 2013, 03:28:56 am »
Worlds smallest resolution you got there, and the font kinda stinks. But the idea is great :)
if($statement) { unless(!$statement) { // Very sure } }
https://evilzone.org/?hack=true

Offline Kulverstukas

  • Administrator
  • Zeus
  • *
  • Posts: 6627
  • Cookies: 542
  • Fascist dictator
    • View Profile
    • My blog
Re: Special thing for Evilzone Christmas, 2013
« Reply #14 on: December 28, 2013, 09:54:38 am »
oh come on, it wasn't that bad :P not everyone has million x million resolution with quadruple set of monitors, 4 on each like in some spacecraft :P