| View previous topic :: View next topic |
| Author |
Message |
Slugsnack Grandmaster Cheater Supreme
Reputation: 71
Joined: 24 Jan 2007 Posts: 1857
|
Posted: Sun Jun 03, 2012 11:17 am Post subject: |
|
|
| I like real K&R. But then I spent a lot of time reading Linux kernel so I might have just got used to it
|
|
| Back to top |
|
 |
AverageAzn247 Grandmaster Cheater
Reputation: 34
Joined: 01 Oct 2007 Posts: 909 Location: Austin,TX with 72 virgins
|
Posted: Sun Jun 03, 2012 11:28 am Post subject: |
|
|
| Slugsnack wrote: | | OP. wrote: | | does everybody here know a lot about scripting and all this c++ stuff? |
it's not c++. it's c99 or above. +rep to anyone who can tell me how i know that
@aviar: i think you misunderstood (or at least didn't understand past line-by-line analysis) the whole sub-block starting with strstr | print statment gives it away. not cout also lack of built in support for the string data type
_________________
| Waxxup wrote: | What are Night Elves?
A girl group? |
|
|
| Back to top |
|
 |
Aniblaze Grandmaster Cheater Supreme
Reputation: 138
Joined: 23 Apr 2006 Posts: 1757 Location: The Netherlands
|
Posted: Sun Jun 03, 2012 11:35 am Post subject: |
|
|
| Slugsnack wrote: | | I like real K&R. But then I spent a lot of time reading Linux kernel so I might have just got used to it |
Looked up K&R (because I'm unfamiliar with the abbreviation), and it says that the Linux (and Unix) Kernel was written in 1TBS, not in K&R. This is Wikipedia information, and there is no mention of 'real K&R'. Are you perhaps referring to '1TBS' when you say 'real K&R'?
|
|
| Back to top |
|
 |
Slugsnack Grandmaster Cheater Supreme
Reputation: 71
Joined: 24 Jan 2007 Posts: 1857
|
Posted: Sun Jun 03, 2012 11:35 am Post subject: |
|
|
| AverageAzn247 wrote: | | Slugsnack wrote: | | OP. wrote: | | does everybody here know a lot about scripting and all this c++ stuff? |
it's not c++. it's c99 or above. +rep to anyone who can tell me how i know that
@aviar: i think you misunderstood (or at least didn't understand past line-by-line analysis) the whole sub-block starting with strstr | print statment gives it away. not cout also lack of built in support for the string data type |
wrong. the program does not use idiomatic c++ practices but is valid c++0x. try compiling with:
| Code: | | g++ -std=c++0x -pedantic -Wall lala.c -o lala |
if my question was unclear i was actually asking why i said c99 and not c89/90. but i answered this earlier already
| Aniblaze wrote: | | Slugsnack wrote: | | I like real K&R. But then I spent a lot of time reading Linux kernel so I might have just got used to it |
Looked up K&R (because I'm unfamiliar with the abbreviation), and it says that the Linux (and Unix) Kernel was written in 1TBS, not in K&R. This is Wikipedia information, and there is no mention of 'real K&R'. Are you perhaps referring to '1TBS' when you say 'real K&R'? |
see Linux kernel coding style (chapter 2)
Last edited by Slugsnack on Sun Jun 03, 2012 11:38 am; edited 1 time in total |
|
| Back to top |
|
 |
AverageAzn247 Grandmaster Cheater
Reputation: 34
Joined: 01 Oct 2007 Posts: 909 Location: Austin,TX with 72 virgins
|
Posted: Sun Jun 03, 2012 11:37 am Post subject: |
|
|
| Slugsnack wrote: | | AverageAzn247 wrote: | | Slugsnack wrote: | | OP. wrote: | | does everybody here know a lot about scripting and all this c++ stuff? |
it's not c++. it's c99 or above. +rep to anyone who can tell me how i know that
@aviar: i think you misunderstood (or at least didn't understand past line-by-line analysis) the whole sub-block starting with strstr | print statment gives it away. not cout also lack of built in support for the string data type |
wrong. the program does not use idiomatic c++ practices but is valid c++0x. try compiling with:
| Code: | | g++ -std=c++0x -pedantic -Wall lala.c -o lala |
if my question was unclear i was actually asking why i said c99 and not c89/90. but i answered this earlier already | I just assumed it was c because of #include <stdio.h>
#include <string.h>
_________________
| Waxxup wrote: | What are Night Elves?
A girl group? |
|
|
| Back to top |
|
 |
Aviar³ Grandmaster Cheater
Reputation: 50
Joined: 03 Jan 2008 Posts: 655 Location: Canada
|
Posted: Sun Jun 03, 2012 2:56 pm Post subject: |
|
|
| Slugsnack wrote: | | OP. wrote: | | does everybody here know a lot about scripting and all this c++ stuff? |
it's not c++. it's c99 or above. +rep to anyone who can tell me how i know that
@aviar: i think you misunderstood (or at least didn't understand past line-by-line analysis) the whole sub-block starting with strstr |
Actually I didn't much look at the block, I sort of skipped it over. I'd have had to have taken the time to look up strchr, but even without that, I can guess he is building a null terminated string manually sets /0 at end.
Also, I didn't like the fact that theres no way to preserve whitespace and use BBCode at the same time on this forum.
_________________
This is the inception of deception, checking the depth of your perception.
 |
|
| Back to top |
|
 |
gogodr I post too much
Reputation: 125
Joined: 19 Dec 2006 Posts: 2041
|
Posted: Sun Jun 03, 2012 4:32 pm Post subject: |
|
|
that feel when I wake up and I realise all the C coding I researched and did yesterday was useless and there is a simpler way to do it and it is faster for the tablet...
I'm not going to make the tablet parse the 3D model file, I'm going to do it in C# and generate an easy to read special file to use instead.
making the app parse the 3D model data was a bad idea, it was going to take resources when I can do it externally and use already processed data.
(( this is for a 3D engine I'm making using OpenGL ES 2.0 for the blackberry tablet btw ))
|
|
| Back to top |
|
 |
Cheat Engine User Something epic
Reputation: 61
Joined: 22 Jun 2007 Posts: 2071
|
Posted: Sun Jun 03, 2012 4:41 pm Post subject: |
|
|
| Aniblaze wrote: | | Holland wrote: | I hate it when people do brackets like that.
Netbeans does it too. Automatically. It makes me cringe. |
Readability doesn't suffer, so I actually prefer it. A class with 20 methods would have 20 extra lines that do absolutely nothing. It makes me cringe. | I like seeing where segments start and end.
I don't know, I just don't like it.
I hate documenting, you know, those 5 lines of fucking comments that tell what the fuck SetName does. Seriously.
|
|
| Back to top |
|
 |
Slugsnack Grandmaster Cheater Supreme
Reputation: 71
Joined: 24 Jan 2007 Posts: 1857
|
|
| Back to top |
|
 |
Cheat Engine User Something epic
Reputation: 61
Joined: 22 Jun 2007 Posts: 2071
|
Posted: Sun Jun 03, 2012 4:42 pm Post subject: |
|
|
lol don't you think i know this already
edit: Also, I dont recall it saying anything about templates. Basically I start off with a base in which I can easily start off a new game project, and then when that game project is done, and I created something nice, I leave it in the template. Doing this with every game I make I create a nice 'engine', while actually I am just 'making games'.
Also calling shit c99x023 instead of C++ is like calling japanese-style drawn comic porn with little girls 'futa hentai'
Last edited by Cheat Engine User on Sun Jun 03, 2012 4:45 pm; edited 1 time in total |
|
| Back to top |
|
 |
Slugsnack Grandmaster Cheater Supreme
Reputation: 71
Joined: 24 Jan 2007 Posts: 1857
|
Posted: Sun Jun 03, 2012 4:45 pm Post subject: |
|
|
that was a reply to gogodr's post. but okay
|
|
| Back to top |
|
 |
Cheat Engine User Something epic
Reputation: 61
Joined: 22 Jun 2007 Posts: 2071
|
Posted: Sun Jun 03, 2012 4:46 pm Post subject: |
|
|
| Slugsnack wrote: | | that was a reply to gogodr's post. but okay ;) | i love you and your englishness
edit: yeah it makes more sense when you look at it like that
|
|
| Back to top |
|
 |
gogodr I post too much
Reputation: 125
Joined: 19 Dec 2006 Posts: 2041
|
Posted: Sun Jun 03, 2012 4:50 pm Post subject: |
|
|
yeah, I'm making this part of the engine because there is no engine out that does what I'm trying to do.
I'm participating on a contest with a team to make a game for the blackberry tablet. we need this done first xP
Last edited by gogodr on Sun Jun 03, 2012 4:50 pm; edited 1 time in total |
|
| Back to top |
|
 |
Aniblaze Grandmaster Cheater Supreme
Reputation: 138
Joined: 23 Apr 2006 Posts: 1757 Location: The Netherlands
|
Posted: Sun Jun 03, 2012 4:50 pm Post subject: |
|
|
| Holland wrote: | | Aniblaze wrote: | | Holland wrote: | I hate it when people do brackets like that.
Netbeans does it too. Automatically. It makes me cringe. |
Readability doesn't suffer, so I actually prefer it. A class with 20 methods would have 20 extra lines that do absolutely nothing. It makes me cringe. | I like seeing where segments start and end.
I don't know, I just don't like it.
I hate documenting, you know, those 5 lines of fucking comments that tell what the fuck SetName does. Seriously. |
Lol, I know that feeling. But on the other hand, you love reading what a method does instead of assuming or having to test if it does what you want.
|
|
| Back to top |
|
 |
Slugsnack Grandmaster Cheater Supreme
Reputation: 71
Joined: 24 Jan 2007 Posts: 1857
|
Posted: Sun Jun 03, 2012 4:54 pm Post subject: |
|
|
| Holland wrote: | lol don't you think i know this already
edit: Also, I dont recall it saying anything about templates. Basically I start off with a base in which I can easily start off a new game project, and then when that game project is done, and I created something nice, I leave it in the template. Doing this with every game I make I create a nice 'engine', while actually I am just 'making games'.
Also calling shit c99x023 instead of C++ is like calling japanese-style drawn comic porn with little girls 'futa hentai' |
c99 is a c standard... c++ is a different programming language that has its own standards. the latest c++ standard is c++0x
|
|
| Back to top |
|
 |
|