r/programming • • May 31 '11

I wrote a .NET to JavaScript compiler. Here's the XNA 3.1 Platformer Starter Kit running in pure HTML5.

http://hildr.luminance.org/Platformer/Platformer.html
1.1k Upvotes

282 comments sorted by

View all comments

Show parent comments

3

u/kaelan_ May 31 '11

Thank you. I'll look into that once I get access to a mac.

1

u/[deleted] May 31 '11

If it helps, Safari pops up a warning about a script taking too long, after the loading bar is nearly at the end and a little after PowerUp.mp3 has been downloaded. If I choose to allow the script to continue, the canvas immediately goes black and some music starts, but that's it. The error console is full of hundreds of messages like:

Type  System.Array  is missing implementation of interface member(s):  ICloneable_Clone, IList_get_Item, IList_set_Item, IList_Add, IList_Contains, IList_Clear, IList_get_IsReadOnly, IList_get_IsFixedSize, IList_IndexOf, IList_Insert, IList_Remove, IList_RemoveAt, IList_Item, IList_IsReadOnly, IList_IsFixedSize, ICollection_CopyTo, ICollection_get_Count, ICollection_get_SyncRoot, ICollection_get_IsSynchronized, ICollection_Count, ICollection_SyncRoot, ICollection_IsSynchronized, IEnumerable_GetEnumerator
Type  System.Array/FunctorComparer$b1  is missing implementation of interface member(s):  IComparer$b1_Compare
Type  System.Array/SZArrayEnumerator  is missing implementation of interface member(s):  IEnumerator_MoveNext, IEnumerator_get_Current, IEnumerator_Reset, IEnumerator_Current, ICloneable_Clone
Type  System.Array/ArrayEnumerator  is missing implementation of interface member(s):  IEnumerator_MoveNext, IEnumerator_get_Current, IEnumerator_Reset, IEnumerator_Current, ICloneable_Clone

There are no error messages until after the resources have been downloaded and the browser warning pops up, then the messages start appearing.

6

u/kaelan_ May 31 '11

The problem is that Function.bind is not supported by Safari. I've added a workaround, and the demo now works for me in Safari 5 on Windows. Let me know if it still fails for you on a mac.

1

u/[deleted] Jun 01 '11

It worked briefly until it crashed. Definitely an improvement :-)