~ Forums of Enroth ~

An Enroth diehard fan community
 
HomeHome  ChatChat  FAQFAQ  SearchSearch  RegisterRegister  Log inLog in  
Latest topics
» Experimenting with the Well
by Darmani Yesterday at 09:56

» HoM&M 2 Map suggestions?
by Orzie 2018-02-19, 08:45

» H3SW General Discussion
by Wayshan 2018-02-10, 07:14

» Design of H3SW page on www.moddb.com
by GodRage 2018-01-28, 06:55

» Cyborg: Artifacts
by Daleron 2018-01-25, 08:20

» H3SW: General Graphics discussion
by buffkaz 2018-01-21, 21:32

» Homm2 gog/dosbox balance mod
by Arstahd 2018-01-11, 17:56

Poll
"Wait" in HoMM2?
Yes
82%
 82% [ 53 ]
No
18%
 18% [ 12 ]
Total Votes : 65
Most Viewed Topics
H3SW: General Graphics discussion
Ragoon's Graphics For HoMM3SW
H3SW General Discussion
H3SW: Dwelling Development
H3SW Map List: Work in progress
Enrothian Fan Art
Dervish Faction General Concept
Commanders?
Серия книг "Земли Меча и Магии"
H3SW Recruitment Point - Enroth Needs You!

Share | 
 

 LNK2001 Error

Go down 
AuthorMessage
DraggonFantasy
Guest
avatar


PostSubject: LNK2001 Error   2015-07-21, 04:54

Hello)
I'm trying to modify game method ( army::DoAttack(int) ).
Added this to heroes2_imports.inc:
Code:

IMPORT_?DoAttack@army@@QAEXH@Z = 1
?DoAttack@army@@QAEXH@Z_clone EQU ?DoAttack_orig@army@@QAEXH@Z
And modified combat.h and combat.cpp files:
combat.h - added void DoAttack(int) and void DoAttack_orig(int) declarations to army class.
combat.cpp - added void army::DoAttack(int x) definition.
The problem is when I call DoAttack_orig(x), linker give me an error.
PS, sorry for my english, it isn't my native language Smile


------------

Admin's edit: An additional post by DraggonFantasy was omitted when copying from the old forum, and has been inserted here:

DraggonFantasy' post:

Problem fixed. I deleted heroes2.obj file to perform reassembling and everything works now. Very Happy
Back to top Go down
Darmani_
Guest
avatar


PostSubject: Re: LNK2001 Error   2015-07-21, 04:55

Excellent! May I ask what you're modding?

I've been a bit lax lately about uploading the latest versions of the source code. I need to get on that.
Back to top Go down
DraggonFantasy
Guest
avatar


PostSubject: Re: LNK2001 Error   2015-07-21, 04:55

I'm making a mod, that extends map-making abilities, adds more Lua functions and triggers etc.
Have already added 16 new functions and 3 new triggers Very Happy
Also fixed the bug with Pandora's Box, when it replace your army with peasants after battle)
Back to top Go down
Daeley
Guest
avatar


PostSubject: Re: LNK2001 Error   2015-07-21, 04:56

@DraggonFantasy,

I've been trying to get the game to compile, but seem to be missing a few steps. Could you share what you did/programs you used to make it work? I gave Darmani a ping but he's pretty busy atm so if you could help that would be great. Very Happy

steps I've taken so far (working on a Windows 7 machine):
(1) install Visual studio Express C++ 2010 (I usually develop in Eclipse, and that one was free)
(2) fetch latest from the Mercurial repo and open the VC project (.vcproj file)
(3) compile failed on some include failure
--> fixed by adding (path to to ironfist repo)/ironfist/src/cpp and (...)/ironfist/src/cpp/lib to include path
(4) Compile failed on error "'CString' : undeclared identifier" in file dialog.cpp
--> guess my includes aren't 100% correct yet... quick workaround: comment the code
(5) massive syntax errors on everything in the xerxes folder
--> stuck here... more include issues? Maybe I don't have correct libraries installed?
Back to top Go down
Daeley
Guest
avatar


PostSubject: Re: LNK2001 Error   2015-07-21, 04:56

never mind Smile had some more help and fixed all the issues Smile
Back to top Go down
Sponsored content




PostSubject: Re: LNK2001 Error   

Back to top Go down
 
LNK2001 Error
Back to top 
Page 1 of 1
 Similar topics
-
» browser error occured [Error #230]
» Error Code #230 - it's BACK!!
» Error Code 64: Host not available!
» PSN Error 80710B36?
» PSN DNS Error Fix

Permissions in this forum:You cannot reply to topics in this forum
~ Forums of Enroth ~ :: Modding Guild :: Heroes of Might and Magic II: Project Ironfist :: Modding and Mapmaking-
Jump to: