All pastes #390068 Raw Edit

Mine

public text v1 · immutable
·published 2007-03-11 03:22 UTC
rendered paste body
function TEST_Threat_AI.DoCastRandomChance(LuaAI, target, chance, spellID)
	local letsDoSpell = rand_range(1,100)

	if (letsDoSpell >= (100 - chance) ) then
		if( spellID > 0 ) then
			LuaAI:DoCast(target, spellID);
		end
	end

end