Czy ktos zna Delphi i C++

0

Mam pewien problem mam fragmenty kodu źródłowego w C++ i chciałbym by 'Ktos' (znający C++ i Delphi of course ) mi pomógł w jego przekładzie.
CZyli z C++ => Delphi

0

Zajebiscie, majac dzialy Delphi, C++ zadajesz pytanie o nie w offtopic, w sumie idiotyczny post bo nic nie wnosi, zamiast dac fragment kodu z ktorym masz problem i tyle, wg mnie bylo by wiecej odpowiedzi wtedy

/ ja to tu przeniosłem, chociaż może Inne byłoby lepszym rozwiązaniem?? - mV /

0

no prawda zajebiście mam jescze 198 plików
// --------------------------------------------------------------------------
// File Name: actual_non_player.cpp
// Purpose: actual non player class functions
//
// Championship Manager 4
// (c) Sports Interactive Ltd 2001
// --------------------------------------------------------------------------

// --------------------------------------------------------------------------
// Function: load
// Purpose: loads a non player record from a file
// Inputs: file, the file stream pointer
// call_base_class_functions, should upper class functions be called ?
// database, the database pointer
// type, the table type
// index, the index of the table to put this record
// Outputs: CBOOL, success value
// --------------------------------------------------------------------------
CBOOL ACTUAL_NON_PLAYER::load( FILE_STREAM *file, CBOOL call_base_class_functions,
DATABASE *database, DATABASE_TABLE_TYPE type, LONG index, CBOOL server_save_format )
{
assert( file );

// save server info ?
if( server_save_format )
{
	// read the class variables
	file->read( home_reputation );
	file->read( current_reputation );
	file->read( world_reputation );
	file->read( current_ability );
	file->read( potential_ability );
	file->read( preferred_formation );
	file->read( (LONG&) non_playing_data );
}

// call base class functions ?
if( call_base_class_functions )
{
	NON_PLAYER::load( file, FALSE, database, type, index, server_save_format );
	ACTUAL_PERSON::load( file, FALSE, database, type, index, server_save_format );
	PERSON::load( file, FALSE, database, type, index, server_save_format );
}

// return TRUE
return( TRUE );

} // load

// --------------------------------------------------------------------------
// Function: save
// Purpose: saves a non player record to a file
// Inputs: file, the file stream pointer
// call_base_class_functions, should upper class functions be called ?
// Outputs: CBOOL, success value
// --------------------------------------------------------------------------
CBOOL ACTUAL_NON_PLAYER::save( FILE_STREAM *file, CBOOL call_base_class_functions, CBOOL server_save_format )
{
assert( file );

// if this is the lowest class then save a marker to show what class it is
if( call_base_class_functions )
	file->write( DBC_ACTUAL_NON_PLAYER );

// save server info ?
if( server_save_format )
{
	// save the class variables
	file->write( home_reputation );
	file->write( current_reputation );
	file->write( world_reputation );
	file->write( current_ability );
	file->write( potential_ability );
	file->write( preferred_formation );
	file->write( (LONG)( non_playing_data ? non_playing_data->get_shadow_index() : -1 ) );
}

// KEVIN - preferred formation
// KEVIN - preferred player positions

// call base class functions ?
if( call_base_class_functions )
{
	NON_PLAYER::save( file, FALSE, server_save_format );
	ACTUAL_PERSON::save( file, FALSE, server_save_format );
	PERSON::save( file, FALSE, server_save_format );
}

// return TRUE
return( TRUE );

} // save

#endif // SERVER

0

.....podobnej długości

0

Sprawa jest prosta... są programy, które zrobią to za ciebie... i o WIELE szybciej niż człowiek. Gdzie? na pewno na google.pl :)
P.S. Edycja postów !!
[dopisane]
Czyżby server jakiegoś MUDa? Bo coś tak mi na oko przypomina...
[dopisane po raz kolejny, do postu poniżej]
Przykro mi, ale nie pamiętam... Gdzieś jak szukałem czegoś innego, to mi takie coś wyskoczyło... Albo na google.pl, albo na gnu.org... dwie możliwości...
P.S. Gdybym nazwę pamiętał, to bym podał wcześniej...

0

podaj nazwe programu(ów)
ja jestem fanem CM4(Championship Manager 4) i jego producent opublikował kody w C++ http://www.sigames.com/download/official/CM%204/cm4_editors_code.zip a ja chce sie sprawdzic i zrobic do niego edytor a programuje tylko w delphi a nie w c++

1 użytkowników online, w tym zalogowanych: 0, gości: 1