Question: How can i make my code flow better on earsketch, also change the sounds if needed to make it sound better. # Import earsketch from
How can i make my code flow better on earsketch, also change the sounds if needed to make it sound better. # Import earsketch
from earsketch import
# Function to make my intro
def intro:
# Add instruments to track
hiHat AKUNDOGCLAPSSNAPS
fitMediahiHat
fitMediaAKUNDOG
fitMediaAKUNDOGSTOMP
# Make track and track slowly loss volume then regain the volume as verse approaches
setEffect VOLUME, GAIN,
setEffect VOLUME, GAIN,
# Instruments for the beat
closedHat AKUNDOG
lowTom AKUNDOG
openHat OSOPENHAT
# Patterns for each instrument
makePattern
makePattern
makePattern
# For loop to repeat the same beat from measures to
for measure in range:
makeBeatclosedHat measure, makePattern
makeBeatlowTom measure, makePattern
makeBeatopenHat measure, makePattern
# Instruments and effects to transition into verse
setEffect VOLUME, GAIN,
fitMediaAKUNDOGLEADVOCALSCHORUS,
# Effects to transition into verse
setEffect VOLUME, GAIN,
setEffect VOLUME, GAIN,
setEffect VOLUME, GAIN,
# Function for verses
def verse:
# Fit new instruments onto track
fitMediaAKUNDOGPAD
fitMediaAKUNDOGLEADVOCALSCHORUS,
fitMediaYGNEWHIPHOPCLAP
fitMediaAKUNDOGLEADVOCALSBRIDGE
# Clap to transition into the chorus
clapBeat OSCLAP
transition
makeBeatclapBeat transition
# Function for chorus
def chorus:
# Fit instruments into chorus
fitMediaENTREPTHEMEBRASS,
fitMediaENTREPPERCHIHAT,
fitMediaAKUNDOGLEADVOCALSBRIDGE
setEffect VOLUME, GAIN,
setEffect VOLUME, GAIN,
# For loop to repeat the same instruments over unique measures
for measure in range:
# Repeat only in measures that are even
if measure :
fitMediaAKUNDOGLEADVOCALSBRIDGE measure, measure
# Instruments for beat
kick ENTREPPERCKICK
orchCrash ENTREPPERCORCHCRASH
# Pattern for the first beat of chorus measures
pattern
pattern
# Create the beat from measure to
for measure in range:
if measure :
makeBeatkick measure, pattern
makeBeatorchCrash measure, pattern
# Pattern for nd beat of chorus measures
pattern
pattern
# Create and repeat beat starting from measure until
for measure in range:
makeBeatkick measure, pattern
makeBeatorchCrash measure, pattern
# Initialize song and set temp to bpm
init
setTempo
# Main song. Invoke each part of song
intro
verse
chorus
# End of song
finish
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
