Changeset View
Changeset View
Standalone View
Standalone View
ps/trunk/binaries/data/mods/public/simulation/components/UnitAI.js
Show First 20 Lines • Show All 2,878 Lines • ▼ Show 20 Lines | |||||
"TRADE": { | "TRADE": { | ||||
"Attacked": function(msg) { | "Attacked": function(msg) { | ||||
// Ignore attack | // Ignore attack | ||||
// TODO: Inform player | // TODO: Inform player | ||||
}, | }, | ||||
"leave": function() { | "leave": function() { | ||||
let cmpTrader = Engine.QueryInterface(this.entity, IID_Trader); | |||||
if (cmpTrader) | |||||
cmpTrader.StopTrading(); | |||||
}, | }, | ||||
"APPROACHINGMARKET": { | "APPROACHINGMARKET": { | ||||
"enter": function() { | "enter": function() { | ||||
if (!this.MoveToMarket(this.order.data.target)) | if (!this.MoveToMarket(this.order.data.target)) | ||||
{ | { | ||||
this.FinishOrder(); | this.FinishOrder(); | ||||
return true; | return true; | ||||
▲ Show 20 Lines • Show All 3,548 Lines • Show Last 20 Lines |
Wildfire Games · Phabricator