This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** The function should be invoke when the thread exit. The execution only continues if all child threads have invoked their `JoinFunction`. */ | |
typedef JoinFunction = (Void->Void)->Void; | |
/** | |
Fork threads for every element in <code>threadIdentifiers</code>. | |
@param handler The callback function invoked for each element in <code>threadIdentifiers</code>. | |
The <code>handler</code> can receive two parameters: | |
the element in <code>threadIdentifiers</code> and the <code>JoinFunction</code>. | |
**/ | |
public static function fork<Identifier>( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ModelEntity.init = function(completion) { | |
var componentError = null; | |
var postFork = function() { | |
if ( componentError != null ) Log.error(componentError); | |
completion(componentError); | |
} | |
ForkJoin.fork(entity.m_components,function(component,join) { | |
component.onInit(function(error) { | |
if(error != null) componentError = error; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
com.dongxiguo.continuation.utils.ForkJoin.fork = function(threadIdentifiers,handler) { | |
if(Lambda.empty(threadIdentifiers)) throw "threadIdentifiers must not be empty!"; | |
var counter = 1; | |
var quickJoinHandler = null; | |
var $it0 = $iterator(threadIdentifiers)(); | |
while( $it0.hasNext() ) { | |
var id = $it0.next(); | |
counter++; | |
var isJoined = [false]; | |
handler(id,(function(isJoined) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This file determines which asset bundles will be created for the game. | |
# | |
# Bundles are first created by specifying rules and paths. There are 5 available rules: | |
# bundle_all: Create a SINGLE asset bundle for all files found in the specified paths. This operates recursively on directories. | |
# bundle_each_file: Create an asset bundle for EACH file found in the specified paths. This operates recursively on directories. | |
# bundle_each_folder: Create an asset bundle for EACH subfolder found in the specified paths. | |
# bundle_all_folders: Create a SINGLE asset bundle for all subfolders found in the specified paths. | |
# exclude_all: Exclude all specified files/folders from being bundled by rules specified after this rule. | |
# exclude_folders: Exclude files in subfolders of the specified folders from being being bundled by rules specified after this rule. | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Shader "Hidden/FastBlur" { | |
Properties { | |
_MainTex ("Base (RGB)", 2D) = "white" {} | |
_Bloom ("Bloom (RGB)", 2D) = "black" {} | |
} | |
CGINCLUDE | |
#include "UnityCG.cginc" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#pragma strict | |
@script ExecuteInEditMode | |
@script RequireComponent (Camera) | |
@script AddComponentMenu ("Image Effects/Blur/Blur (Optimized)") | |
class Blur extends PostEffectsBase { | |
@Range(0, 2) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using haxe.root; | |
#pragma warning disable 109, 114, 219, 429, 168, 162 | |
namespace view{ | |
public class PzBlur : Blur, haxe.lang.IHxObject { | |
public PzBlur(haxe.lang.EmptyObject empty) : base(){ | |
unchecked { | |
} | |
} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package hugs; | |
import haxe.macro.Expr; | |
import haxe.macro.Context; | |
/** Utility to generate C# preprocessor macros */ | |
class Preprocessor | |
{ | |
public macro static function IF(name:ExprOf<String>) : Expr { | |
var ns = switch(name.expr) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- UIPanel-old.cs 2014-12-17 09:36:13.000000000 -0500 | |
+++ UIPanel-new.cs 2014-12-12 13:10:36.000000000 -0500 | |
@@ -1157,19 +1157,19 @@ | |
{ | |
p.startingRenderQueue = rq; | |
p.UpdateDrawCalls(); | |
- rq += p.drawCalls.size; | |
+ rq += p.drawCalls.size*2; | |
} | |
else if (p.renderQueue == RenderQueue.StartAt) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if ( !m_allUnitsPlaced ){ | |
if ( m_combatGameMode.hud.unitBeingDragged == null && !m_combatGameMode.hordeSpawned ) { | |
m_combatGameMode.hud.hideSkillSlots(); | |
m_combatGameMode.hud.showSlot(0, false); | |
m_combatGameMode.hud.showSlot(1, false); | |
m_combatGameMode.hud.showSlot(2, false); | |
m_combatGameMode.hud.showSlot(3, false); | |
m_combatGameMode.hud.setActiveTopHUD(false); | |
m_combatGameMode.hud.showSlotArrows(true); | |
NGUITools.SetActive(m_combatGameMode.hud.gameObject, true); |
OlderNewer