[chuck-users] help needed
gewang at CS.Princeton.EDU
Sun Nov 27 21:41:51 EST 2005
> 1) In sine.ck: listen() never recieves any messages. What am I doing
> wrong? Is my definition of the InstrMsg class screwed?
I think the problem was that the event that broadcast in Zone.listen()
is not the same one that InstrSine.listen() is waiting on. I have
attached a slightly revised version which seems to work here. Most of
the changes is in Zone. For clarity, I also capitalized the class
names and prepend some member variables with 'm_'.
> 2) I would like to spork a member objects function (in zone.ck) but I
> get a [chuck](VM): NullPointerException: shred[id=5:spork~exp:(2)],
> PC= if I try to. Isn't that possible or am I getting
> something wrong?
I think this is a bug in chuck: sporking a member function from inside
another function. Sorry about that! The work around is to spork a
non-member function and pass it the appropriate data. We plan to have
it fixed soon.
Hope this helps!
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 1157 bytes
Desc: not available
Url : http://lists.cs.princeton.edu/pipermail/chuck-users/attachments/20051127/aa6e8096/midi_input_06a.bin
More information about the chuck-users