View twitter-images-rename.sh
for img in `ls *-large`; do newimg=`echo $img | rev | cut -d'-' -f2- | rev`; echo $newimg; mv $img $newimg; done
View skills_sentences.md

Perfect Lock

notes

For every N notes, there is a N% chance of turning all goods and greats in the next N seconds into perfects. (Level 1)

seconds

Every N seconds, there is a N% chance of turning all goods and greats in the next N seconds into perfects. (Level 1)

View generate_magicircles_translations.py
#!/bin/bash
cd ~/Documents/python/MagiCircles/ &&\
source env/bin/activate &&\
rm -f web/locale/ja/LC_MESSAGES/django.po &&\
python manage.py makemessages -l ja --ignore=env/* --ignore=./settings.py --ignore=sample_project/sample_project/settings.py --ignore=web/templates/password/* --ignore=web/django_translated.py &&\
deactivate &&\
cd ~/Documents/python/StardustRun/ &&\
source env/bin/activate &&\
rm -f stardustrun/locale/ja/LC_MESSAGES/django.po &&\
python manage.py makemessages -l ja --ignore=env/* --ignore=stardustrun_project/settings.py &&\
View tinypng.py
from __future__ import division
import tinify, cStringIO, os
from PIL import Image
from django.conf import settings as django_settings
from django.core.files.temp import NamedTemporaryFile
from django.core.files.images import ImageFile
def shrinkImageFromData(data, filename):
_, extension = os.path.splitext(filename)
extension = extension.lower()
View pattern.sh
#!/bin/bash
convert "$1" -flop tmp
convert "$1" tmp +append tmp
convert "$1" -flop tmp.png
convert "$1" tmp.png +append tmp.png
convert tmp.png -flip "$1"
convert tmp.png "$1" -append "$1"
rm tmp.png
View MagiCirclesExamples.js
function updateCards() {
$('.card').unbind('click');
$('.card').click(function(e) {
e.preventDefault();
alert('Yay~');
return false;
});
reloadDisqus();
}
View MagiCirclesExamples.py
def filterCards(queryset, parameters, request):
if 'promo_only' in parameters:
queryset = queryset.filter(is_promo=True) if 'promo_only'
return queryset
############################################################
def FilterCardsForm(FormWithRequest):
def __init__(self, *args, **kwargs):
super(FilterCardsForm, self).__init__(*args, **kwargs)
View gist:60848ac343aa096db815814315847bb7
Internal Server Error: /editteam/8512/
Traceback (most recent call last):
File "/home/ubuntu/SchoolIdolAPI/env/local/lib/python2.7/site-packages/django/core/handlers/base.py", line 111, in get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "./web/views.py", line 732, in editteam
'ownedcard': findOwnedCard(form.cleaned_data['card' + str(i)], account.deck),
File "/home/ubuntu/SchoolIdolAPI/env/local/lib/python2.7/site-packages/django/db/models/manager.py", line 92, in manager_method
return getattr(self.get_queryset(), name)(*args, **kwargs)
File "/home/ubuntu/SchoolIdolAPI/env/local/lib/python2.7/site-packages/django/db/models/query.py", line 446, in update_or_create
obj.save(using=self.db)
View gist:d0d3b4b2d01b86b356914bfa0aee5ffc
How it would work
People will still use facebook to organize trades: the only difference is that to verify the accounts and have middlemen, they need to follow this procedure:
- People have to create their account on School Idol Tomodachi and add their cards (at least URs + SRs)
- When they click on "Give away your account" or "Trade your account", they get a form:
- They have to upload a screenshot of their transfer code or write down their transfer code
- They can select whether they want to organize the giveaway on School Idol Tomodachi or somewhere else
View gist:1a61c8eaf642b206653459650bd6bd6b
{
'max_stats':{
'Smile':5380,
'Pure':5340,
'Cool':5350
},
'total_cards':857,
'years':[
u'Second',
u'First',