If you understand EUDs, then it's simple.
Memory to read = 4* player number + 48* unit ID number + Player 1 terran marine deaths offset.
The memory condition simplifies this down to:
Memory to read = 4* number 1 + 48*0 + offset
All you need to do is either solve this equation, or multiply the UnitID by 48, then add it to the player number. Using player deaths is MUCH more efficient than unit IDs.
The memory condition is fully compatible in text and classic trigedit, but it does mess up the death condition constantly. Classic trigedit still supports classic EUDs (ID:xxxx), but text trigedit does not.
Here's an example trigger. Both these triggers will function exactly the same.
Trigger("Player 1"){
Conditions:
Deaths("Player 8", "ID:12288", At least, 256);
Deaths("Player 8", "ID:12288", At most, 511);
Deaths("Current Player", "Kyadarin Crystal Formation", Exactly, 1);
Actions:
Preserve Trigger();
Set Deaths("Current Player", "Cantina", Set To, 1);
}
//-----------------------------------------------------------------//
Trigger("Player 1"){
Conditions:
Memory(147463, At least, 256);
Memory(147463, At most, 511);
Deaths("Current Player", "Kyadarin Crystal Formation", Exactly, 1);
Actions:
Preserve Trigger();
Set Deaths("Current Player", "Cantina", Set To, 1);
}
//-----------------------------------------------------------------//
Memory = 7*4 + 12288*48 + offset
Memory = 147463*4 + 0*48 + offset
if it's still not clear, take a look at
http://www.staredit.net/topic/6416/
"Parliamentary inquiry, Mr. Chairman - do we have to call the Gentleman a gentleman if he's not one?"