Does the GameEngine you plan to use need to be written in the same language you are programming the game in? [closed] - language-agnostic

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 9 years ago.
Improve this question
While my common sense says "Yeah. Duh.", I thought I read something somewhere long long ago that referenced the ability to use different programming languages in harmony and wondered if something like that applied here.
IE, if a game engine is written in C++, but the game I'm developing has been written in C#/XNA, can that game engine be utilized for this game?

Usually the language you use to write game engines aims for efficiency and speed. The language you use to write games aims for simplicity and expressiveness. So, it totally makes sense to use a different language for each purpose.
How they will work together is a different story. Usually, the engine's API will be given a convenient interface to be used in the game "scripting" language, so the latter will interact with the engine through successive API calls. The "heavy lifting" will be all done by the engine though...

Related

Difference between structured programming and structured approach to development? [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 6 years ago.
Improve this question
I'm looking for clarification -
The terms 'structured programming' and 'structured development approach' refer to different things. Is this correct?
My understanding is that 'structured programming' is programming which is clear and well set out, using subroutines and modules etc. to keep 'structure' in software. This is different to the 'structured software development approach' which refers to the methodology of completing the stages of development (defining the problem, planning, creating, testing and maintenance) sequentially and not starting one until the previous is finished.
I'm a student and need to have these terms clear. Am I on the right track? Are there any important details I'm missing?
Yes, you are on the right track, these are different things.
Both of these terms are very broad. All programming paradigms that have been in use during the last 50 years (procedural, object oriented, functional etc.) are structured. And I would also say that every development methodology (waterfall, v model, agile etc.) is also structured in some way. Of course there are different grades.

What is "overkill"? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 9 years ago.
Improve this question
Programmers often wonder if the use of a certain library or programming style is overkill. They also often claim that this is the case (and they are often believed).
What does "overkill" mean in the context of programming?
"overkill" is typically used to mean deploying overly flexible and/or over-engineered solutions to solve what is ostensibly a simple and highly localized problem. The canonical example is FizzBuzz Enterprise Edition.
The term "Overkill" literarilly (if there was ever a literal use of it) refers to the action of killing something or someone, with more resources than necessary. Something like shooting a deer 50 times to make sure it dies.
In programming it applies for the same principle: making use of more resources than necessary or to find an overly complex solution to a simple problem.
Some simple examples are
for i=1 to 100
x[i]=2^z[i];
y=x;
end
Where copying the entire array x in every iteration step achieves the desired result but you could also copy it elementwise y[i]=x[i] saving you some 900 operations and is thus an overkill.
Using the OpenCV library to threshold an image is definetley possible but uses many more resources than strictly necessary and is an exagerated example of an overkill.

How to choose a Clojure JSON library [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 6 years ago.
Improve this question
There are multiple JSON parser/writer libraries available for Clojure, including:
clojure/data.json
cheshire
clj-json
What are the pros and cons of each, especially regarding speed, memory footprint, and programming convenience? Are there any other important factors to consider?
I decided to run a little shootout (the link is to results and the code used to test).
In terms of speed, clj-json is the fastest, 1.7x cheshire, and 5.6x clojure.data.json for a simple parse/generate task.
clojure.data.json has the smallest footprint, and clj-json and cheshire follow. cheshire has some superb features, though, and is my preferred library for dealing with JSON. You get support for SMILE, as well as a lovely interface for interpreting JSON (adding types, special rules on keys, etc) and custom encoders (the last also found in clojure.data.json).

Disadvantages of First-class functions [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 4 years ago.
Improve this question
Are there any disadvantages to having first class functions in a language?
Joel in this entry says
Object-oriented programming languages aren't completely convinced that
you should be allowed to do anything with functions.
I might be naïve here, but why don’t all languages support first class functions if there aren’t much issues
In an ideal world where there was never a cost associated with developing new features, the only downside I can see to including functional programming techniques would be confusion to developers who are not familiar with functional techniques (and I don't really see that as much of a downside).
In reality, treating functions as first-class typically requires significant rewrites to the compiler itself. The cost of doing this has to be weighed against the long-term gain.
Adding this feature might be a disadvantage if introducing the change requires a costly re-write of language compilers, interpreters, and other tools. It might also be a disadvantage if the language's culture is not familiar enough with the advantages provided by this feature in which case adding the feature is a waste of effort.
Additionally, first class functions require runtime interpretation of code and some form of garbage collection. Both of these add overhead that might not be suitable for certain problems and languages.

Story generation [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 8 years ago.
Improve this question
Upon reading a blog post about a minimalist story-generating python program, I was asking myself - and you - which are the most successful attempts at such programs. I remember seeing something using generating grammars, for instance. And which are the best attempts that, like this one, are extremely compact, either self-contained or able to read, say, the Web or an independent textual corpus (but not simply a file with a large number of story chunks)?
Search for Talespin for some famous ground breaking work. (Example: Micro-Talespin in Common Lisp by Warren Sack.)
I actually like Turner's "Minstrel: A Computer Model of Creativity and Storytelling" better :
ftp://ftp.cs.ucla.edu/tech-report/1992-reports/920057.pdf
Talespin is, in my opinion, blind in it's algorithm to everything but planning. So the author goals are given very little consideration (if at all). Minstrel is better that way.