Dragon kite · celworld
seed

Dragon kite

dragon_kite v1Hand-writtenc6
Open in PlaygroundExplain this script

How v1 was made

Hand-written

Written by hand in .cel.

Script
36 lines

Budget

c6 · 36 lines
Shapes100 / 140
Triangles8,630 / 10,000
Draw calls4 / 5
States
None: it rests
Used in
No scene yet
Made
1asset dragon_kite "Dragon kite" complexity=6
2// an original festival kite: a round dragon head with the house face, horns, whiskers and a
3// scalloped frill, a tail of paper discs with little feet that streams sideways and ripples in
4// the wind, and a string down to a spool on the ground
5let H = 2.6..3.3
6let N = int(8..12)
7let hide = cherry:3|tangerine:2|teal|cobalt|grape
8let trim = sunflower:3|white|lime|mint
9let paper = cream:2|white|peach
10
11// the head
12ball head at=(0, H, 0) r=(.36, .32, .26) color=hide joint
13face look on=head eyes=round:2|happy mouth=grin:2|open size=.2 spacing=30 eyeY=12 mouthY=-26 mouthW=.5 iris=#2a2a3a brows=hide*.6 detail=.6
14ball snout on=head surf=(0, -18) lift=-.08 r=(.2, .11, .13) color=hide*1.06
15ball nostril on=snout surf=(18, 30) decal mirror lift=-.01 r=(.025, .02, .015) color=hide*.55 ink=none segs=6 rings=4
16cone horn on=head surf=(26, 52) mirror rot=(-14, 0, 8) h=.24 r=.055 color=trim segs=8
17tube whisker on=snout surf=(70, -10) mirror pts=[0,0,0 .1,-.03,.06 .22,-.12,.04 .3,-.2,-.04] r=(.016, .006) smooth color=trim sides=5
18slab frill on=head at=(0, .02, -.14) pts=[0,.66 -.12,.42 -.36,.56 -.33,.29 -.6,.27 -.44,.06 -.65,-.09 -.4,-.18 -.5,-.43 -.24,-.37 -.19,-.63 0,-.44 .19,-.63 .24,-.37 .5,-.43 .4,-.18 .65,-.09 .44,.06 .6,.27 .33,.29 .36,.56 .12,.42] t=.04 color=trim edge=hide
19
20// the tail: a cord of links that ride each other, shrinking as they go, each with a paper disc
21rod seg x=N on=head at=(.3, -.04, -.16) chain=(.3, -.015, 0) rot=(0, 3, -4) scale=.95 to=(.3, -.015, 0) r=.012 sides=5 color=hide*.7 ink=thin joint
22cyl disc on=seg at=(0, 0, -.025) rot=(90, 0, 0) h=.05 r=.25 round=.012 color=hide cap=sel(parent.i - 2*floor(parent.i/2), paper, trim) segs=12
23puff tuft on=seg at=(0, .27, 0) r=(.05, .07, .09) color=trim noise=.04 segs=7 rings=4
24rod foot x2 on=seg row=(0, 0, .26) at=(0, -.2, 0) to=(-.04, -.16, 0) r=(.014, .01) sides=5 color=trim
25ball toe on=foot at=end r=.03 color=trim segs=5 rings=3
26cone tassel on=seg at=(.3, -.015, 0) rot=(0, 0, -90) h=.12 r=.05 color=trim if=chance(.2)
27
28// the string and the spool
29tube string on=head at=(0, -.26, .05) pts=[0,0,0 -.25,-(H-.3)*.5,.35 -.5,-(H-.3)*.92,.62 -.52,-(H-.3)+.02,.66] r=.006 smooth sides=4 color=paper ink=thin
30cyl spool at=(-.52, 0, .7) h=.08 r=.1 round=.02 color=oak segs=12
31cyl reel on=spool at=(0, .08, 0) h=.06 r=.06 color=paper segs=10
32
33anim seg ry sin amp=7 hz=.45 stagger=.11
34anim seg rz sin amp=4 hz=.3 stagger=.08
35anim head py sin amp=.06 hz=.3
36anim head rz sin amp=3 hz=.3 phase=.25
37