File size: 2,781 Bytes
b8ca448
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
"""
generate_assets.py — Create 500+ emojis, icons, backgrounds, sounds for Neura-AI v500 Hardcode
Author: CHATGPT + Joshua•Dav
"""

import os
from PIL import Image, ImageDraw, ImageFont
import random
import wave
import struct

# ----------------------------
# Settings
# ----------------------------
root = "./"  # Assets will go in project root
emoji_count = 500
icon_names = ["chat_icon", "game_icon", "crypto_icon", "education_icon"]
background_names = ["neon_gradient", "dark_mode_bg", "pastel_pattern"]

# ----------------------------
# Create folders if not exist (optional)
# ----------------------------
# For your request, files are directly in root, not subfolders

# ----------------------------
# Generate 500 Emojis (simple colored circles)
# ----------------------------
for i in range(1, emoji_count + 1):
    img = Image.new('RGBA', (128,128), color=(255,255,255,0))
    draw = ImageDraw.Draw(img)
    # Random color circle
    color = tuple(random.randint(50,255) for _ in range(3))
    draw.ellipse([10,10,118,118], fill=color)
    # Save file
    img.save(os.path.join(root, f"emoji_{i:03}.png"))

print(f"Generated {emoji_count} emojis!")

# ----------------------------
# Generate Icons (simple shapes)
# ----------------------------
for name in icon_names:
    img = Image.new('RGBA', (64,64), color=(255,255,255,0))
    draw = ImageDraw.Draw(img)
    color = tuple(random.randint(0,255) for _ in range(3))
    draw.rectangle([10,10,54,54], fill=color)
    img.save(os.path.join(root, f"{name}.png"))

print("Generated icons!")

# ----------------------------
# Generate Backgrounds (gradients)
# ----------------------------
for name in background_names:
    img = Image.new('RGB', (800,600), color=(0,0,0))
    for y in range(600):
        r = int(255 * y / 600)
        g = int(128 * y / 600)
        b = int(255 - 255 * y / 600)
        for x in range(800):
            img.putpixel((x,y),(r,g,b))
    img.save(os.path.join(root, f"{name}.png"))

print("Generated backgrounds!")

# ----------------------------
# Generate simple sounds (sine wave placeholders)
# ----------------------------
def create_sound(filename, duration=0.5, freq=440.0):
    framerate = 44100
    amplitude = 32767
    nframes = int(duration * framerate)
    wav_file = wave.open(filename, 'w')
    wav_file.setparams((1, 2, framerate, nframes, 'NONE', 'not compressed'))
    for i in range(nframes):
        value = int(amplitude * random.uniform(-1,1))
        data = struct.pack('<h', value)
        wav_file.writeframesraw(data)
    wav_file.close()

sound_names = ["notification.mp3","game_start.wav","achievement.wav"]
for name in sound_names:
    create_sound(os.path.join(root, name))

print("Generated sounds!")

print("All premium assets are ready in root folder!")