Commit graph

781 commits

Author SHA1 Message Date
Nick Winter
f3adc216ed Protecting our replacement of Math.random via Aether. 2014-05-29 12:26:08 -07:00
Scott Erickson
93f7d8c0a4 Made sure sprites are idle and properly positioned when they load. 2014-05-27 16:41:56 -07:00
Nick Winter
c01bd69625 Better recoverability for non-UserCodeProblem errors during world generation. 2014-05-26 18:45:00 -07:00
Nick Winter
3dd362c01e Added support for blaming infinite loops. 2014-05-25 12:15:32 -07:00
Nick Winter
6b554e03ef Merge pull request #1084 from domenukk/feature/step-single-frame
Added shortcut for frame single-stepping
2014-05-25 09:37:13 -07:00
Nick Winter
16e1ef760a Merge branch 'master' of git://github.com/jayant1992/codecombat 2014-05-25 08:51:13 -07:00
Nick Winter
1a6fd75103 Trying to fix some Simulator loading errors. 2014-05-25 08:29:33 -07:00
Dominik Maier
f62cd7f38b + added shortcut for frame single-stepping
+ fixed single stepping for frames
2014-05-24 17:31:59 +02:00
Jayant Jain
a84049cf16 Fixes issues with dragging thangs onto the map 2014-05-24 12:02:26 +05:30
Jayant Jain
94f70ca9f4 Fixes #1079 2014-05-24 12:02:26 +05:30
Nick Winter
35fc5a5197 Fixed infinite loop detection, I hope. 2014-05-23 21:24:50 -07:00
Nick Winter
690fbc6919 Fixed a bug with Tome trying to retranspile transpiled code on clone spells when remagicking. 2014-05-23 12:04:42 -07:00
Nick Winter
ff171588d9 Trying out text shadow coloring based on team for text event labels. 2014-05-23 09:56:39 -07:00
Nick Winter
26d2816071 Fixed some more memory leaks. 2014-05-22 19:05:11 -07:00
Scott Erickson
bd575ad667 Fixed the placement of wall sprites in the level editor to wait until the sprite sheet is finished being built. 2014-05-22 14:16:39 -07:00
Scott Erickson
5a407492db Got rid of a bunch of magic numbers in mark scaling. Now assumed all target marks have a width of 10m by default. 2014-05-22 13:48:48 -07:00
Scott Erickson
681adc1dcd Got rid of a log. 2014-05-22 13:37:08 -07:00
Nick Winter
4c7d7fce03 Fixed some memory leaks. 2014-05-22 12:05:36 -07:00
Scott Erickson
bfa90f671d Fixes #940, merging the signup and login modal into a single modal. Created a couple A/B tests for amount of text in the signup modal. 2014-05-22 11:26:08 -07:00
Scott Erickson
104deb2ab8 Disabled CocoModel noty errors for form submissions that handle these errors. 2014-05-22 11:26:08 -07:00
Nick Winter
48f5347075 Fixed gigantor server scoring bug. Cleaned up a bit of logging and error handling. Finished not resetting scores on resubmitting. 2014-05-21 21:56:11 -07:00
Scott Erickson
037dbe97c6 Some remaining work to get the delayed show guide script set up. 2014-05-21 14:50:27 -07:00
Scott Erickson
4929f81fcc Fixed the level editor preview window not loading on repeated opens. 2014-05-21 14:28:52 -07:00
Scott Erickson
18f694b010 Fixed up the level loader to include session objects as world necessities. 2014-05-21 12:53:28 -07:00
Jayant Jain
c05780de4c Resolves #170, thang can be directly placed by dragging onto the map 2014-05-21 10:27:46 -07:00
Scott Erickson
a7f24ab04f Some work on subscription definitions for the validated Backbone Mediator. Added 'script-manager:tick' channel. 2014-05-20 15:36:15 -07:00
Scott Erickson
70525ec57a Fixed the music starting when you restart the level, even if music is off. 2014-05-20 13:43:52 -07:00
Nick Winter
88a5685c37 Fix for WizardSprite scale thing. 2014-05-20 12:32:26 -07:00
Scott Erickson
86736d8f4a Fixed a bug. 2014-05-20 12:22:24 -07:00
Scott Erickson
2b56dffcb0 Fixed a bug where sometimes scripts setting playback would be overridden by the surface resetting playback after casting is done. 2014-05-20 12:21:43 -07:00
Scott Erickson
3f884e71e5 Fixed the LevelLoader in headless settings. 2014-05-20 11:25:32 -07:00
Scott Erickson
93c6f72f07 Asynchronously building things again. 2014-05-20 10:49:19 -07:00
Nick Winter
022722a19f Fixed cosmetic GoalManager destruction error. 2014-05-20 09:19:31 -07:00
Nick Winter
d058b16283 Fixed some memory leaks. 2014-05-20 08:00:49 -07:00
Scott Erickson
a8abe8c887 Fixed mark sprite scaling some more. 2014-05-19 23:01:48 -07:00
Scott Erickson
f24ee98295 More work on mark sizing. 2014-05-19 22:17:23 -07:00
Scott Erickson
f463966a22 Fixed a bug with thangs not being properly scaled when first created sometimes. 2014-05-19 21:55:41 -07:00
Scott Erickson
6c3ff16bed Fixed setting registration points for thangs that match world dimensions. 2014-05-19 21:55:31 -07:00
Scott Erickson
b816055f9e Fixed goal states to handle teams. 2014-05-19 21:55:30 -07:00
Nick Winter
b2cc3d0692 Fixed bug with preloading the world replacing casting the same world if timing was wrong. 2014-05-19 20:12:16 -07:00
Scott Erickson
9ad4602e0f Fixed a bug with the new goal view. 2014-05-19 20:11:33 -07:00
Michael Schmatz
aba0120e88 Merge branch 'master' of https://github.com/codecombat/codecombat
Conflicts:
	server/queues/scoring.coffee
2014-05-19 19:04:47 -07:00
Michael Schmatz
97cbf55695 Simulator fetch random Greed games when queue empty 2014-05-19 18:58:45 -07:00
Scott Erickson
b410d91203 Cleaned up the LevelView, organizing it so that initialization code roughly runs in order, and set it up so that the ScriptManager is created earlier. 2014-05-19 17:10:41 -07:00
Scott Erickson
62ad8dd26a Added a status message to the goals view. 2014-05-19 16:36:45 -07:00
Scott Erickson
9ace31d391 Fixed the target mark. 2014-05-19 16:36:45 -07:00
Scott Erickson
8ae14e21ae Fixed #1029. Refactored scaling for sprites a bit. 2014-05-19 16:36:44 -07:00
Nick Winter
68a4483e91 Moved views/play/ladder_view to views/play/ladder/ladder_view and made a new views/play/ladder_home_view. 2014-05-19 11:58:53 -07:00
Nick Winter
5dd8bec393 Fixed issues with initial sprite scaling. 2014-05-19 10:39:24 -07:00
Michael Schmatz
6f2fd8e293 Verification simulator changes 2014-05-19 10:11:23 -07:00
Scott Erickson
df222461bf Fixed a bug that was bringing the thang editor down. 2014-05-17 11:38:33 -07:00
Scott Erickson
f99a95768e Set up CocoSprites to have text appear overhead based on events coming from the ShowsText component. 2014-05-17 11:28:57 -07:00
Scott Erickson
4be67113be Thang events now only appear once per whole frame, rather than for each interpolated frame. 2014-05-17 11:28:57 -07:00
Nick Winter
736fc8c12f Remove overeager transpile problem showing for JS again. 2014-05-17 09:58:35 -07:00
Nick Winter
418c2f1a2c Preserve original scripts; don't overwrite with nothing if new world finishes before script initialization. 2014-05-16 17:38:33 -07:00
Nick Winter
a36a7792ec Fixed problem with IndieSprites not loading, breaking scripts. 2014-05-16 17:18:56 -07:00
Nick Winter
f64e50f85b Recording flow only for frame of interest. 2014-05-16 16:52:55 -07:00
Scott Erickson
ae64032739 Refactored the Camera to only listen to events that use the same canvas. Fixed the level editor map selection modals. 2014-05-16 15:34:14 -07:00
Michael Schmatz
e631bae248 Level session playtime logging 2014-05-16 15:27:46 -07:00
Michael Schmatz
5b93414862 Add playtime, opponent name, totalScore to match 2014-05-16 14:52:49 -07:00
Nick Winter
c1052d8d7e Fixed bug with trying to play selection sound for nonexistent sprites. 2014-05-16 10:03:45 -07:00
Nick Winter
fabf607b6a Merge branch 'master' of https://github.com/codecombat/codecombat 2014-05-15 20:49:15 -07:00
Nick Winter
ca6ea474bf Fixed some bugs with sprite sound loading and playback. 2014-05-15 20:49:10 -07:00
Scott Erickson
eebbae9b13 Added a global SPRITE_RESOLUTION_FACTOR property. 2014-05-15 17:09:35 -07:00
Michael Schmatz
65aae86dcc Merge branch 'master' of https://github.com/codecombat/codecombat
Conflicts:
	app/lib/simulator/Simulator.coffee
2014-05-15 16:44:16 -07:00
Michael Schmatz
a21d17a168 Have simulator use transpiledCode 2014-05-15 16:43:16 -07:00
Nick Winter
763e0500b2 Tracking simulator clicks. 2014-05-15 15:10:50 -07:00
Nick Winter
b973b749c0 Merged. 2014-05-15 14:57:24 -07:00
Nick Winter
8909d218bc Moved random seed initialization to Existence System, where it can be configured. 2014-05-15 14:54:31 -07:00
Scott Erickson
2a1d9a3c6c Turned shadow caching back on, with a little buffer. Makes a bigger diff for maps like Greed on Firefox where they're all over the place. 2014-05-15 13:19:10 -07:00
Scott Erickson
3a1afbb7ca Turned shadow caching back on. Makes a bigger diff for maps like Greed on Firefox where they're all over the place. 2014-05-15 13:06:42 -07:00
Nick Winter
c1f9d51b37 Added times to runtime errors. Don't load ThangTypes for Thangs that don't exist on the first frame of the world. 2014-05-15 11:27:51 -07:00
Scott Erickson
f653aa3375 Fixed #1008 2014-05-15 10:51:38 -07:00
Nick Winter
dbcafbb29b Working on level-specific coding languages, with non-writable code in JavaScript. 2014-05-14 21:54:36 -07:00
Scott Erickson
2a17ec5cb9 Refactored out displayObject from CocoSprites. 2014-05-14 17:05:13 -07:00
Nick Winter
d61922ae42 Merge branch 'master' of https://github.com/codecombat/codecombat 2014-05-14 15:31:19 -07:00
Nick Winter
cc7808251f Zoom/scroll, ModelModal, and coordinate grabber fixes. 2014-05-14 15:29:55 -07:00
Scott Erickson
a1474652f6 Merge branch 'feature/thangload' 2014-05-14 14:21:40 -07:00
Scott Erickson
00fdaa1d0f Fixed raster image sprites to update their scales when they load, and to properly place themselves if matching world dimensions. 2014-05-14 12:28:47 -07:00
Nick Winter
698207f533 Merge pull request #996 from gosnat/patch-8
Update world.coffee
2014-05-14 11:55:01 -07:00
Nick Winter
7f3e769cbd Merge pull request #997 from gosnat/patch-6
Update GoalManager.coffee
2014-05-14 11:54:50 -07:00
Nick Winter
57f3846abb Merge pull request #998 from gosnat/patch-7
Update thang.coffee
2014-05-14 11:54:46 -07:00
Scott Erickson
7a381df348 Merge branch 'feature/thangload' 2014-05-14 11:48:19 -07:00
Scott Erickson
09fbfdb360 Fixed a bug with the simulator due to the changes made to the supermodel. 2014-05-14 11:13:36 -07:00
Scott Erickson
0be813e424 Figured out how to get the world to properly get shown if the world is created before the level loader is completely finished. 2014-05-14 10:35:16 -07:00
Michael Schmatz
9f9d651b3b Updates to transpile script and updated aetherOptions 2014-05-14 10:14:18 -07:00
Scott Erickson
54af58baee SuperModel no longer emits progress going backward ever, and added a way to prevent it from getting to high in the middle of a chain of loading. 2014-05-14 09:24:52 -07:00
Scott Erickson
4b404ae124 Finished tuning the supermodel loading and progress. 2014-05-13 14:39:45 -07:00
Scott Erickson
b4ad34eb8f LevelLoader only builds and loads thang types in the world on the first frame, letting everything else happen lazily. 2014-05-13 10:51:55 -07:00
gosnat
12f351197d Update world.coffee
add getGoalState
2014-05-13 12:43:39 -05:00
gosnat
72b2c84705 Update thang.coffee
add getGoalState
2014-05-13 12:42:48 -05:00
gosnat
25287e0298 Update GoalManager.coffee
add getGoalState
2014-05-13 12:41:39 -05:00
Scott Erickson
66af855497 Merge branch 'master' into feature/thangload 2014-05-13 10:27:10 -07:00
Scott Erickson
1d88b6eefe Most of the way there getting it to work with loading thang types dynamically throughout the play view. 2014-05-13 10:26:33 -07:00
Dominik Maier
bb562aba32 + Overly lengtly comment changed. 2014-05-13 04:40:15 +02:00
Nick Winter
09bdc9bad9 Fixed initial team setting. 2014-05-12 19:39:16 -07:00
Dominik Maier
521bc31fa5 + Created function for generating a reproducable seed out of user code - as using JSON.stringify is not garanteed to be the same on every browser for objects. 2014-05-13 04:32:29 +02:00
Dominik Maier
efa39ffcd9 + Created function for generating a reproducable seed out of user code but it fails inside the web-worker 2014-05-13 04:18:56 +02:00
Dominik Maier
2807e83672 + "Real" predictable random. Seed depends on usercode map. 2014-05-13 03:34:11 +02:00
Nick Winter
2eefdef191 Working on matching Surface paused state to the pause screen. 2014-05-12 15:54:07 -07:00
Nick Winter
78a0efac78 Fixed long words in Labels and empty GoldView. 2014-05-12 15:03:53 -07:00
Nick Winter
802889d115 Merge branch 'master' of https://github.com/codecombat/codecombat 2014-05-12 13:28:51 -07:00
Nick Winter
1a5e30d5b5 Dynamic Canvas sizing. 2014-05-12 13:28:46 -07:00
Michael Schmatz
687872a97b Moved debug cache onto main thread
UI responsiveness greatly improved
2014-05-12 11:16:02 -07:00
Nick Winter
1aa72541ff Merged master into feature/thangload. 2014-05-12 09:57:31 -07:00
Nick Winter
e1b35251a3 Fixed bug with playback ending early. 2014-05-12 08:35:46 -07:00
Nick Winter
74ef9bc987 Experimental support for preloading worlds when we would have autocast if manual cast is on. 2014-05-11 17:42:32 -07:00
Nick Winter
8df3b01f9e Merged world/lodash/aether breakup for world workers. 2014-05-10 18:52:55 -07:00
Nick Winter
1e18f0b42f Merged God and Buddha, split out Angels, did a huge refactoring, fixed many bugs, and laid groundwork for preloading Worlds. 2014-05-10 18:24:50 -07:00
Scott Erickson
f1de2ca8d9 Brought the canvas size down again because it halves the FPS in Firefox at least. 2014-05-09 16:35:10 -07:00
Nick Winter
df88be1ab1 Merge branch 'master' of https://github.com/codecombat/codecombat 2014-05-09 15:07:55 -07:00
Nick Winter
6040d3b225 Shouldn't use much CPU when totally paused on Surface. 2014-05-09 15:07:30 -07:00
Michael Schmatz
1bbd4e6c68 Fixed frame-related bug 2014-05-09 15:05:50 -07:00
Michael Schmatz
f05af0fbe7 Merge branch 'master' of https://github.com/codecombat/codecombat
Conflicts:
	app/assets/javascripts/workers/worker_world.js
2014-05-09 14:50:08 -07:00
Michael Schmatz
66cc427417 Forward simulation optimization 2014-05-09 14:48:43 -07:00
Nick Winter
a74d015d18 Fixed a couple minor bugs. 2014-05-09 14:30:33 -07:00
Nick Winter
589410ed8e Merged master into feature/thangload. 2014-05-09 12:56:58 -07:00
Nick Winter
c4819c647c Removed includeeFlow, since we're going to do it lazily with the debug worker. 2014-05-09 09:29:50 -07:00
Nick Winter
3819778bee Updating everything to Aether 0.2.0. 2014-05-08 11:43:00 -07:00
Nick Winter
775a2a87e2 Merge branch 'master' of https://github.com/codecombat/codecombat 2014-05-08 11:36:26 -07:00
Michael Schmatz
9c58aef32b Merged worker_debug and worker_world 2014-05-08 09:47:02 -07:00
Nick Winter
f3c6745b29 Merge branch 'master' of https://github.com/codecombat/codecombat 2014-05-07 15:37:49 -07:00
Scott Erickson
c037ce14f2 Fixed #958. LevelLoader wasn't handling cached session objects passed in with the supermodel. 2014-05-07 13:28:42 -07:00
Michael Schmatz
7432112cba Merge branch 'master' of https://github.com/codecombat/codecombat 2014-05-07 11:37:04 -07:00
Michael Schmatz
7110f023f2 Merge branch 'feature/hover-debugger-performance'
Conflicts:
	app/lib/God.coffee
	app/views/play/level/tome/spell_debug_view.coffee
2014-05-07 11:37:03 -07:00
Scott Erickson
09a47cc5d8 Fixed #951. The parser was removing the shadow shape but not the tween of the shadow. 2014-05-07 11:11:22 -07:00
Nick Winter
0c30ec0c12 Some weird bugs I noticed with {me}. 2014-05-06 16:58:08 -07:00
Michael Schmatz
da575f8945 Refactored hover debugger is functional
Still needs optimizations and a few bug fixes, but it’s better than the
existing code existing to Nick
2014-05-06 15:07:06 -07:00
Nick Winter
1f166406ac Some new names. 2014-05-06 12:47:38 -07:00
Nick Winter
ca8d5c1f3b Stop bobbing and more marks when world ended. 2014-05-06 11:02:53 -07:00
Michael Schmatz
dddd617a08 userCodeMap issues fixed
Now beginning hooking up the UI
2014-05-06 10:06:32 -07:00
Nick Winter
2e6bec5454 Some fixes for my accidental merge of #970. 2014-05-06 09:49:04 -07:00
Nick Winter
1f3cc8a004 Merge branch 'master' of git://github.com/domenukk/codecombat 2014-05-06 08:00:39 -07:00
Nick Winter
09c8a99a9b Merge branch 'patch-5' of git://github.com/gosnat/codecombat into gosnat-patch-5 2014-05-06 07:23:51 -07:00
Nick Winter
acccee33a3 Cleaner conditional init syntax. 2014-05-06 07:22:09 -07:00
Nick Winter
3e7edd8c61 Merge branch 'patch-4' of git://github.com/gosnat/codecombat into gosnat-patch-4 2014-05-06 07:18:26 -07:00
Dominik Maier
6d244e8560 + Merged Simulators 2014-05-06 05:07:34 +02:00
Dominik Maier
ad85bf5b77 Merge remote-tracking branch 'upstream/master' 2014-05-06 03:12:24 +02:00
Dominik Maier
c9bb488794 Created headless-client and an alternative implementation of god 2014-05-06 02:37:14 +02:00
Scott Erickson
056f081cdb Merge branch 'anonNameCollide' of https://github.com/adi2412/codecombat into adi2412-anonNameCollide
Conflicts:
	app/views/modal/signup_modal.coffee
2014-05-05 16:48:35 -07:00
Scott Erickson
684e61532a Fixed a bug with the deltas library identifying conflicts between patches. 2014-05-05 16:35:26 -07:00
Michael Schmatz
97f3694dbf Basic backend functionality is there 2014-05-05 13:26:37 -07:00
gosnat
939509849c Update GoalManager.coffee
Justification:

For a negative goal like saveThangs, let's say you have 5 thangs on the save list.  As things stand, if you don't have a HowMany defined, then the number of needed deaths to fail is 

numNeeded = _.size(stateThangs) - Math.min((goal.howMany ? 1), _.size stateThangs) + 1
numNeeded = 5 - Math.min(1, 5) + 1
numNeeded = 5

So you would only fail the goal if all 5 thangs you were supposed to save died.  This is contrary to the comment right above this line:

# saveThangs: by default we would want to save all the Thangs, which means that we would want none of them to be "done"

Therefore, I think it should be Math.max rather than Math.min.

numNeeded = _.size(stateThangs) - Math.max((goal.howMany ? 1), _.size stateThangs) + 1
numNeeded = 5 - Math.max(1, 5) + 1
numNeeded = 1

So any of the Thangs on the save list dying is enough to fail the goal.

As a double check, what if the level designer designated a HowMany of 5?

numNeeded = _.size(stateThangs) - Math.max((goal.howMany ? 1), _.size stateThangs) + 1
numNeeded = 5 - Math.max(5, 5) + 1
numNeeded = 1

So this is consistent.
2014-05-05 14:08:41 -05:00
gosnat
93d117100a Update GoalManager.coffee
For compound goals like GetAllToLocation, you should continue adding to the existing list of thang states.
2014-05-05 13:22:57 -05:00
gosnat
39b21da035 Update GoalManager.coffee
I'd like to temporarily turn on console logging (lines 240 and 245) to take a peek at why numNeeded doesn't seem to be correct if howMany isn't defined.
2014-05-03 21:36:24 -05:00
Scott Erickson
db9a82d58a Merge branch 'feature/thangload' of https://github.com/codecombat/codecombat into feature/thangload 2014-05-02 17:03:53 -07:00
Scott Erickson
aee90c72bb Most of the way there with the raster images. Just need to figure out loading with PreloadJS and the SuperModel. 2014-05-02 17:03:30 -07:00
Nick Winter
d54149d0f3 Reworked LevelView loading priorities to try to get world simulating earlier. 2014-05-02 12:32:41 -07:00
Scott Erickson
06bc96d7d0 Set up the level loader to get thangtype names first, then load the thang types themselves so the world can be generated in parallel with thang type loading and rendering. 2014-05-02 10:31:20 -07:00
Scott Erickson
2952d7702c Merge branch 'master' into feature/thangload
Conflicts:
	app/lib/LevelLoader.coffee
	app/views/play/level_view.coffee
2014-05-02 08:20:03 -07:00