Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
2 registered members (AndrewAMD, TipmyPip), 12,420 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 2 1 2
Why C++ #84807
08/06/06 15:50
08/06/06 15:50
Joined: Oct 2003
Posts: 246
A
Alberto Offline OP
Member
Alberto  Offline OP
Member
A

Joined: Oct 2003
Posts: 246
Hello

What's the main reason to use C++ \ SDK rather than C - script

a) To implement new graphic features
B) for sophisticated A.I.
C) Complex Game play
d) other

Thanks in advance

Re: Why C++ [Re: Alberto] #84808
08/06/06 16:06
08/06/06 16:06
Joined: Jun 2004
Posts: 2,234
Wisconsin USA
FoxHound Offline
Expert
FoxHound  Offline
Expert

Joined: Jun 2004
Posts: 2,234
Wisconsin USA
C++ is faster then C-script.

On top of that there are things that simply can not be done in c-script, like accessing dirextx functions.


---------------------
There is no signature here.


QUIT LOOKING FOR ONE!
Re: Why C++ [Re: FoxHound] #84809
08/06/06 16:40
08/06/06 16:40
Joined: Jan 2003
Posts: 4,305
Damocles Offline
Expert
Damocles  Offline
Expert

Joined: Jan 2003
Posts: 4,305
My main usage would be to be able to use
object oriented programming,
which is crucial in very big AI systems.
And C-script does not support objects/classes.
(class-objects as combination of methods and data)

Re: Why C++ [Re: Damocles] #84810
08/06/06 16:46
08/06/06 16:46
Joined: Aug 2003
Posts: 7,440
Red Dwarf
Michael_Schwarz Offline
Senior Expert
Michael_Schwarz  Offline
Senior Expert

Joined: Aug 2003
Posts: 7,440
Red Dwarf
And C++ is (waaaaaaaay) MUCH more powerful than C-Script


"Sometimes JCL reminds me of Notch, but more competent" ~ Kiyaku
Re: Why C++ [Re: Michael_Schwarz] #84811
08/06/06 16:59
08/06/06 16:59
Joined: Jan 2003
Posts: 4,305
Damocles Offline
Expert
Damocles  Offline
Expert

Joined: Jan 2003
Posts: 4,305
No, it is not better in all cases,
it is just more usefull for certain approaches/solutions
that cant be realized in c-scipt, or grow to complicated.
(Multiplayer, complex object orented systems, grafical calculations..)

There are many tasks that can be realized more efficiently in
c-scipt for the usual 3dGS User.

There was a comment I remember about an old Amiga Assebler Book,
where to author states, that the more proficient one is in assebmler, the
less he uses it. -> It is only used for program parts that need
to be fast (calculations in a loop), or cant be realized in Basic or C.
All other processing, that needs no special speed are done in a higher language.


Re: Why C++ [Re: Damocles] #84812
08/11/06 19:33
08/11/06 19:33
Joined: Aug 2005
Posts: 155
USA San Diego CA
Scramasax Offline
Member
Scramasax  Offline
Member

Joined: Aug 2005
Posts: 155
USA San Diego CA
I've been using c-script less and less over the past couple of years. Moving more and more code into C++ .dll(s).

I can see using c-script as the data driven part of making a game, but I've almost totally abandoned this approach for external ascii and binary files that I read in with a custom tokenizer I've written. If you can't program C++, or are making a small game, then c-script is the answer, but conversely C++ is a powerful tool to make mid to large sized games.


www.moxiefish.com George Lancaster
Re: Why C++ [Re: Scramasax] #84813
08/22/06 21:39
08/22/06 21:39
Joined: Oct 2003
Posts: 246
A
Alberto Offline OP
Member
Alberto  Offline OP
Member
A

Joined: Oct 2003
Posts: 246
Thanks all for your reply
Just a question
Is it possible to mix C++ and 3dgs c script in the same gmeplay code ?
In particular can I keep using the smart(in my opinion) 3dgs entity\action engine structure integrated with c++ code
Same as Daemocle my main target is to develop some rather sophisticated
AI algo's while for the rest of the gane, c script is fine
Thanks again

Re: Why C++ [Re: Alberto] #84814
08/23/06 16:31
08/23/06 16:31
Joined: Jan 2006
Posts: 1,829
Neustadt, Germany
T
TWO Offline

Serious User
TWO  Offline

Serious User
T

Joined: Jan 2006
Posts: 1,829
Neustadt, Germany
Sure it´s possible. You just programm your Dll in any compiler (look at the sdk_plugin) in your 3DGS folder, put the Dll in your plugin folder and write some importing stuff like this:

Func Dll:

DLLFUNC var Add_one_to_var(var variable)
{
variable=1;
}

Import code in a wdl script:

dllfunction Add_one_to_var(variable);


Now you can use the 'Add_one_to_var(variable)' Function in c-script.

Re: Why C++ [Re: TWO] #84815
08/23/06 16:50
08/23/06 16:50
Joined: Aug 2003
Posts: 7,440
Red Dwarf
Michael_Schwarz Offline
Senior Expert
Michael_Schwarz  Offline
Senior Expert

Joined: Aug 2003
Posts: 7,440
Red Dwarf
wouldnt it be

DLLFUNC var Add_one_to_var(var variable)
{
_INT(variable)+=1;
}

?


"Sometimes JCL reminds me of Notch, but more competent" ~ Kiyaku
Re: Why C++ [Re: Michael_Schwarz] #84816
08/23/06 18:22
08/23/06 18:22
Joined: Jan 2006
Posts: 1,829
Neustadt, Germany
T
TWO Offline

Serious User
TWO  Offline

Serious User
T

Joined: Jan 2006
Posts: 1,829
Neustadt, Germany
Since you don´t return the var, both versions are ok. If you would return my version, 1 would be 0.001

Page 1 of 2 1 2

Moderated by  HeelX, Spirit 

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1