Page 1 of 1

find location of fields and units in editor

Posted: Sat Jan 13, 2024 1:18 pm
by spotlight2001
Hi,

in editor for "operationblue" I have checked "triggers" and found references to .lua file:

Code: Select all

units1 = {64,54,63,56,62,58,61,55,59,57,60}

function AttackCondition1()
	flag1 = world:GetHex({17,3})
	return flag1.owner == 0 
end

function AttackEffect1()
	for _, unit_id in ipairs(units1) do
		local unit = world:GetUnit(unit_id) 
		if (unit ~= nil) then
			local orders = Copy(unit.orders) 
			table.remove(orders, 1) 
			unit.orders = orders 
		end
	end
end
In editor how can I find unit 64?
In editor how can I find hex{17,3}?

Re: find location of fields and units in editor

Posted: Sat Jan 13, 2024 1:28 pm
by VirgilInTheSKY
Hover over a hex to get its number at bottom left corner. Select a unit (switch to Unit Configuration or whatever it is called precisely) to see its number in the configuration panel.

Re: find location of fields and units in editor

Posted: Sat Jan 13, 2024 4:35 pm
by Grondel
spotlight2001 wrote: Sat Jan 13, 2024 1:18 pm In editor how can I find unit 64?
The units number is displayed at the bottom of the screen as well, next to the hex cords.
sadly there is no way to reverse search for unit 64, u have to mouse over each unit until u find it.
Image

sers,
Thomas