• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

Dev C++ problem z przebudowaniem projektu

Status
Not open for further replies.

mrozek8

Member
Joined
Apr 2, 2011
Messages
376
Reaction score
9
Gdy daje Kompiluj po chwili wyrzuca mi błędy:
Code:
Kompilator: Default compiler
Building Makefile: "C:\Documents and Settings\mrozek\Pulpit\trunk.r3884\dev-cpp\Makefile.win"
Wykonywanie  make...
make.exe -f "C:\Documents and Settings\mrozek\Pulpit\trunk.r3884\dev-cpp\Makefile.win" all
g++.exe -c ../actions.cpp -o obj//actions.o -I"include"  -D__USE_MYSQL__ -D__USE_SQLITE__ -D__ENABLE_SERVER_DIAGNOSTIC__ -O2 -D__WAR_SYSTEM__   -fexpensive-optimizations -O1

In file included from ../player.h:34,
                 from ../actions.cpp:23:
../ioguild.h: In member function `bool IOGuild::updateWar(War_t&)':
../ioguild.h:120: error: `Scheduler' has not been declared
../ioguild.h:120: error: request for member `addEvent' in `IOGuild::getInstance()', which is of non-class type `IOGuild*'

../ioguild.h:121: error: `createSchedulerTask' was not declared in this scope

../ioguild.h: In member function `void IOGuild::finishWar(War_t, bool)':
../ioguild.h:151: error: incomplete type `Player' used in nested name specifier
../ioguild.h:151: error: incomplete type `Player' used in nested name specifier
../ioguild.h:153: error: invalid use of undefined type `struct Player'
../luascript.h:74: error: forward declaration of `struct Player'
../ioguild.h:157: error: invalid use of undefined type `struct Player'
../luascript.h:74: error: forward declaration of `struct Player'

../ioguild.h:159: error: invalid use of undefined type `struct Player'
../luascript.h:74: error: forward declaration of `struct Player'
../ioguild.h:162: error: invalid use of undefined type `struct Player'
../luascript.h:74: error: forward declaration of `struct Player'
../ioguild.h:164: error: invalid use of undefined type `struct Player'
../luascript.h:74: error: forward declaration of `struct Player'
../ioguild.h:169: error: `g_game' was not declared in this scope

../ioguild.h:176: error: `g_game' was not declared in this scope

../ioguild.h: In member function `void IOGuild::frag(Player*, uint64_t, const DeathList&, bool)':
../ioguild.h:212: error: `ChatChannel' was not declared in this scope
../ioguild.h:212: error: `channel' was not declared in this scope
../ioguild.h:213: error: `g_chat' was not declared in this scope

../ioguild.h:215: error: invalid use of undefined type `struct Player'
../luascript.h:74: error: forward declaration of `struct Player'

../ioguild.h:224: error: `g_chat' was not declared in this scope

../ioguild.h:226: error: invalid use of undefined type `struct Player'
../luascript.h:74: error: forward declaration of `struct Player'

make.exe: *** [obj//actions.o] Error 1

Wykonanie zakończone

Biblioteki Open SSL mam zaktualizowane do nowszych.


PS
W ioguild.cpp i ioguild.h mam dodany skrypt na guild war system
 
../ioguild.h:120: error: `Scheduler' has not been declared ../ioguild.h:120: error: request for member `addEvent' in `IOGuild::getInstance()', which is of non-class type `IOGuild*'
Chyba trza do tego błędu dorzucić
PHP:
#include "scheduler.h"

 
Wiesz skopiowałem całość z kompilatora.
Około 3-4 godzin temu wszystko było dobrze.
Wtedy usunąłem folder obj z dev cpp+ przywróciłem go po około 5 minutach i ten błąd, mimo iż ściągam nowyd ev c++ z internetu i aktualizuje Open SSLe.
 
Last edited:
Dobra ruszyło.

Parametr
Code:
-D__WAR_SYSTEM__
gryzł się z parametrem w configure.ac

Takie pyt jeszcze jedno.
Jak akceptować wara?
Bo daje:
/war accept, Kurczak

( Kurczak - nazwa gildii )
I nie działa, natomiast wara wyśle normalnie, ale zaakceptować nie mogę.
W konsoli wyrzuca mi błąd:
Code:
[19:47:39.875] [Error - TalkAction Interface] 
[19:47:39.875] data/talkactions/scripts/war.lua<wow>nSay
[19:47:39.875] Description: 
[19:47:39.875] data/talkactions/scripts/war.lua:70: attempt to call global 'doGuildAddEnemy' (a nil value)
[19:47:39.875] stack traceback:
[19:47:39.875]  data/talkactions/scripts/war.lua:70: in function <data/talkactions/scripts/war.lua:1>

Wyczytałem, że trzeba usunąć folder obj z silnika z dev c++ ( u mnie jest to: C:\Documents and Settings\mrozek\Pulpit\trunk.r3884\dev-cpp ).
Ten folder tworzy się dopiero po kompilacji silnika.
Natomaist mam go w fodlerze z kompilatorem dev c++ jednak nie mogę go usunąc, bo nie przechodzi kompilacja ( chyba, że się mylę ).

W tej chwili nie dodaję parametru
Code:
-D__WAR_SYSTEM__
Ponieważ zastąpiłem go tym parametrem w wcześniej wspomnianym pliku configure.ac
 
Last edited:
Miałem dokładnie taki sam problem i się głowiłem, wejdź na otsoft i wpisz w szukaj elf war system i tam będziesz miał napisane fixy.
 
@up
Tylko, że mnie nie zrozumiałeś:)
Jak dodam
Code:
-D__WAR_SYSTEM__
w configure.ac i dam kompiluj, to mi działa wszystko pięknie, brak jakiegokolwiek błędu.

Natomiast jeśli dam ten
Code:
configure.ac
w configure.ac i w parametrach projektu i dam kompiluj, to wyrzuca mi błędy z pierwszego posta.
 
Cytat:
Pierwszym Krokiem będzie dodanie parametru do configure.ac
Code:
OPTIONAL_FLAGS=""
zamieniamy na:
Code:
OPTIONAL_FLAGS="-D__WAR_SYSTEM__"
I zrobiłem to, dalej robię skrypty, wpisy w bazie danych etc i wywala mi błędy w silniku
Code:
[19:47:39.875] [Error - TalkAction Interface] 
[19:47:39.875] data/talkactions/scripts/war.lua<wow>nSay
[19:47:39.875] Description: 
[19:47:39.875] data/talkactions/scripts/war.lua:70: attempt to call global 'doGuildAddEnemy' (a nil value)
[19:47:39.875] stack traceback:
[19:47:39.875]  data/talkactions/scripts/war.lua:70: in function <data/talkactions/scripts/war.lua:1>

Wyczytałem tutaj na otlandzie, że przed kompilacją należy dodać parametr
Code:
-D__WAR_SYSTEM__
No i dodałem go, zaczynam kompilować i wywala błędy:
Code:
Kompilator: Default compiler
Building Makefile: "C:\Documents and Settings\mrozek\Pulpit\trunk.r3884\dev-cpp\Makefile.win"
Wykonywanie  make...
make.exe -f "C:\Documents and Settings\mrozek\Pulpit\trunk.r3884\dev-cpp\Makefile.win" all
g++.exe -c ../actions.cpp -o obj//actions.o -I"include"  -D__USE_MYSQL__ -D__USE_SQLITE__ -D__ENABLE_SERVER_DIAGNOSTIC__ -O2 -D__WAR_SYSTEM__   -fexpensive-optimizations -O1

In file included from ../player.h:34,
                 from ../actions.cpp:23:
../ioguild.h: In member function `bool IOGuild::updateWar(War_t&)':
../ioguild.h:120: error: `Scheduler' has not been declared
../ioguild.h:120: error: request for member `addEvent' in `IOGuild::getInstance()', which is of non-class type `IOGuild*'

../ioguild.h:121: error: `createSchedulerTask' was not declared in this scope

../ioguild.h: In member function `void IOGuild::finishWar(War_t, bool)':
../ioguild.h:151: error: incomplete type `Player' used in nested name specifier
../ioguild.h:151: error: incomplete type `Player' used in nested name specifier
../ioguild.h:153: error: invalid use of undefined type `struct Player'
../luascript.h:74: error: forward declaration of `struct Player'
../ioguild.h:157: error: invalid use of undefined type `struct Player'
../luascript.h:74: error: forward declaration of `struct Player'

../ioguild.h:159: error: invalid use of undefined type `struct Player'
../luascript.h:74: error: forward declaration of `struct Player'
../ioguild.h:162: error: invalid use of undefined type `struct Player'
../luascript.h:74: error: forward declaration of `struct Player'
../ioguild.h:164: error: invalid use of undefined type `struct Player'
../luascript.h:74: error: forward declaration of `struct Player'
../ioguild.h:169: error: `g_game' was not declared in this scope

../ioguild.h:176: error: `g_game' was not declared in this scope

../ioguild.h: In member function `void IOGuild::frag(Player*, uint64_t, const DeathList&, bool)':
../ioguild.h:212: error: `ChatChannel' was not declared in this scope
../ioguild.h:212: error: `channel' was not declared in this scope
../ioguild.h:213: error: `g_chat' was not declared in this scope

../ioguild.h:215: error: invalid use of undefined type `struct Player'
../luascript.h:74: error: forward declaration of `struct Player'

../ioguild.h:224: error: `g_chat' was not declared in this scope

../ioguild.h:226: error: invalid use of undefined type `struct Player'
../luascript.h:74: error: forward declaration of `struct Player'

make.exe: *** [obj//actions.o] Error 1

Wykonanie zakończone
Natomiast jak dodam tylko
Code:
OPTIONAL_FLAGS="-D__WAR_SYSTEM__"
w configure.ac, a nie dodam parametru
Code:
-D__WAR_SYSTEM__
W kompilatorze, to wszystko działa idealnie.

Krótko mówiąc, jak dodaje w configure.ac i parametr w opcjach projektu, to nie idzie skompilować, bo wywala błędy.
Natomiast jeśli dodam linijkę tylko w configure.ac, to skompiluje się bez najmniejszego błędu.

Sorry, ale jaśniej napisać raczej nie potrafię:D
 
To zmień na jakiś inny i zobacz czy działa


:ninja:
 
Wiesz zbytnio, to nie mam tam wyboru pod tibie 8.60, bo jest ten 3884, a poinformowali mnie tutaj na forum, że 3777 jest pod linuxa, nie pod windowsa
 
Wiesz zbytnio, to nie mam tam wyboru pod tibie 8.60, bo jest ten 3884, a poinformowali mnie tutaj na forum, że 3777 jest pod linuxa, nie pod windowsa
Dobry, geniuszu, dobry (tak mawiaja na forum).
Kazdy rev jest multiplatformowy.
 
Ty mnie dalej nie rozumiesz.
Ludzie na forum mowia, ze rev 3884 jest dobry pod winde, a 3777 jest dobry pod linuxa.
KAZDY REV JEST MULTIPLATFORMOWY, NO KURWA.
Chodzi o czas uptimu na poszczegolnych OS'ach.

Pozatym mowiles cos, ze chciales kupic donatora, czy cos?
 
Status
Not open for further replies.
Back
Top