Changeset View
Changeset View
Standalone View
Standalone View
source/simulation2/components/ICmpIdentity.cpp
/* Copyright (C) 2011 Wildfire Games. | /* Copyright (C) 2019 Wildfire Games. | ||||
* This file is part of 0 A.D. | * This file is part of 0 A.D. | ||||
* | * | ||||
* 0 A.D. is free software: you can redistribute it and/or modify | * 0 A.D. is free software: you can redistribute it and/or modify | ||||
* it under the terms of the GNU General Public License as published by | * it under the terms of the GNU General Public License as published by | ||||
* the Free Software Foundation, either version 2 of the License, or | * the Free Software Foundation, either version 2 of the License, or | ||||
* (at your option) any later version. | * (at your option) any later version. | ||||
* | * | ||||
* 0 A.D. is distributed in the hope that it will be useful, | * 0 A.D. is distributed in the hope that it will be useful, | ||||
Show All 20 Lines | |||||
{ | { | ||||
public: | public: | ||||
DEFAULT_SCRIPT_WRAPPER(IdentityScripted) | DEFAULT_SCRIPT_WRAPPER(IdentityScripted) | ||||
virtual std::string GetSelectionGroupName() | virtual std::string GetSelectionGroupName() | ||||
{ | { | ||||
return m_Script.Call<std::string>("GetSelectionGroupName"); | return m_Script.Call<std::string>("GetSelectionGroupName"); | ||||
} | } | ||||
virtual std::wstring GetPhenotype() | |||||
Stan: std::wstring here, below, and in the h file :) Will save you some troubles down the road. | |||||
Done Inline ActionsWhat does that do? Freagarach: What does that do? | |||||
Done Inline ActionsThis link should answer your question https://stackoverflow.com/questions/402283/stdwstring-vs-stdstring Stan: This link should answer your question https://stackoverflow.com/questions/402283/stdwstring-vs… | |||||
{ | |||||
return m_Script.Call<std::wstring>("GetPhenotype"); | |||||
} | |||||
}; | }; | ||||
REGISTER_COMPONENT_SCRIPT_WRAPPER(IdentityScripted) | REGISTER_COMPONENT_SCRIPT_WRAPPER(IdentityScripted) |
Wildfire Games · Phabricator
std::wstring here, below, and in the h file :) Will save you some troubles down the road.