~ Forums of Enroth ~

An Enroth diehard fan community
 
HomeHome  ChatChat  FAQFAQ  SearchSearch  RegisterRegister  Log inLog in  
Latest topics
» Cyborg: Graphics
by Ragoon 2017-12-11, 15:10

» Ragoon's Graphics For HoMM3SW
by Orzie 2017-12-11, 07:29

» H3SW: Adventure Map Objects
by Orzie 2017-12-11, 00:52

» Cyborg: Faction Lineup
by Morglin 2017-12-10, 13:10

» H3SW: Dwelling Development
by Orzie 2017-12-09, 05:49

» H3SW: General Graphics discussion
by Loom 2017-12-05, 07:26

» H3SW: Fonts and palettes
by Orzie 2017-12-03, 08:32

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

Share | 
 

 LNK2001 Error

View previous topic View next topic 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
View previous topic View next topic 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: