• Welcome to the Kancolle Wiki!
  • If you have any questions regarding site content, account registration, etc., please visit the KanColle Wiki Discord

Changes

Jump to navigation Jump to search
Add constructor for self-invocation
Line 14: Line 14:  
end
 
end
 
   
 
   
function EnemyShipCard:BattleCard(args)
+
function EnemyShipCard:create_ship(args)
 +
return EnemyShip(args.name, args.model)
 +
end
 +
 +
function EnemyShipCard(frame)
 +
local args = getArgs{frame = frame:getParent()}
 
local ship = self:create_ship(args)
 
local ship = self:create_ship(args)
 
return self:battle_card(ship, args)
 
return self:battle_card(ship, args)
end
  −
  −
function EnemyShipCard:create_ship(args)
  −
return EnemyShip(args.name, args.model)
   
end
 
end
 
   
 
   
 
return EnemyShipCard
 
return EnemyShipCard
Anonymous user

Navigation menu