Skip to content

Commit

Permalink
addded wind effects
Browse files Browse the repository at this point in the history
  • Loading branch information
Paytonco committed Jan 29, 2022
1 parent 22a0cf6 commit 6e23ab9
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion util.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,13 @@
from scipy.ndimage import convolve

def findKernel(state,wind,humidity,precip):
kernel = np.ones((3,3))
kernel = np.zeros((3,3))
kernel[0,0] = wind/15
kernel[0,1] = 0.5
kernel[1,0] = 0.5
kernel[1,2] = 0.5
kernel[2,1] = 0.5

return kernel

def maskConvolve(state,kernel,mask):
Expand Down

0 comments on commit 6e23ab9

Please sign in to comment.