Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Conquer Online 2 > CO2 Private Server
You last visited: Today at 15:43

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



help me to pick up 2 sources

Discussion on help me to pick up 2 sources within the CO2 Private Server forum part of the Conquer Online 2 category.

Reply
 
Old 12/28/2011, 21:36   #16
 
elite*gold: 21
Join Date: Jul 2005
Posts: 9,193
Received Thanks: 5,376
Quote:
Originally Posted by Mr_PoP View Post
NOT TRUE! mine does not use pointers at all , and all i can say it's decent enough ;P
Yours is not public...

Using pointers will (generally) provide increased performance or make the code easier to write/understand. It's a learning curve but there's no reason to completely avoid pointers like they are the anti christ. They exist for a reason and should be used where applicable.
pro4never is offline  
Old 12/28/2011, 21:54   #17
 
Mr_PoP's Avatar
 
elite*gold: 0
Join Date: Apr 2008
Posts: 759
Received Thanks: 285
Quote:
Originally Posted by pro4never View Post
Yours is not public...

Using pointers will (generally) provide increased performance or make the code easier to write/understand. It's a learning curve but there's no reason to completely avoid pointers like they are the anti christ. They exist for a reason and should be used where applicable.
you didn't say public sources u said "Most decent C# sources still use pointers..." :P

and am completely avoiding pointers so i can run my source on any machine
Mr_PoP is offline  
Thanks
1 User
Old 12/28/2011, 21:58   #18
 
elite*gold: 0
Join Date: Dec 2011
Posts: 1,537
Received Thanks: 785
Quote:
Originally Posted by Mr_PoP View Post
you didn't say public sources u said "Most decent C# sources still use pointers..." :P

and am completely avoiding pointers so i can run my source on any machine
Pointers are not machine based. A pointer is pointing to a location in the memory. Pointers are usually faster, because they write/read directly from memory. They aren't safe to use tho, because you can throw anything in them or whatever how you say it, that's why you use them in unsafe context in C#, but in C/C++ etc. you don't have to declare unsafe, because it's not safe anyways.
I don't have a username is offline  
Old 12/29/2011, 00:19   #19
 
Mr_PoP's Avatar
 
elite*gold: 0
Join Date: Apr 2008
Posts: 759
Received Thanks: 285
Quote:
Originally Posted by I don't have a username View Post
Pointers are not machine based. A pointer is pointing to a location in the memory. Pointers are usually faster, because they write/read directly from memory. They aren't safe to use tho, because you can throw anything in them or whatever how you say it, that's why you use them in unsafe context in C#, but in C/C++ etc. you don't have to declare unsafe, because it's not safe anyways.
what i meant is if i used pointers, for instance i wont be able to run the source on Linux or so...!
Mr_PoP is offline  
Old 12/29/2011, 00:40   #20
 
elite*gold: 0
Join Date: Jun 2009
Posts: 787
Received Thanks: 314
Quote:
Originally Posted by Mr_PoP View Post
what i meant is if i used pointers, for instance i wont be able to run the source on Linux or so...!
Mono supports pointers as well.
_tao4229_ is offline  
Old 12/29/2011, 00:55   #21
 
Mr_PoP's Avatar
 
elite*gold: 0
Join Date: Apr 2008
Posts: 759
Received Thanks: 285
Quote:
Originally Posted by _tao4229_ View Post
Mono supports pointers as well.
as unknownone mentioned earlier....
Quote:
Originally Posted by unknownone View Post
You can run a C# server on mac/Linux via mono if you remove all the P/invokes, unsafe code and other platform specific code (specifically, BinaryReader/Writer, or other logic which does non-endian-aware conversion - assuming Mac on PPC).
Mr_PoP is offline  
Old 12/29/2011, 01:34   #22
 
elite*gold: 0
Join Date: Dec 2011
Posts: 1,537
Received Thanks: 785
Quote:
Originally Posted by Mr_PoP View Post
as unknownone mentioned earlier....
But are you using Mono? If yes, then you got a valid point, if no, then you have no reasons to not use pointers.
I don't have a username is offline  
Old 12/29/2011, 01:50   #23
 
Mr_PoP's Avatar
 
elite*gold: 0
Join Date: Apr 2008
Posts: 759
Received Thanks: 285
Quote:
Originally Posted by I don't have a username View Post
But are you using Mono? If yes, then you got a valid point, if no, then you have no reasons to not use pointers.
atm of course am not, am using win7 lol , but what if i wanted to in the future!? then i will end up editing allot of stuff etc
Mr_PoP is offline  
Old 12/29/2011, 03:40   #24
 
elite*gold: 0
Join Date: Jun 2009
Posts: 787
Received Thanks: 314
Quote:
Originally Posted by Mr_PoP View Post
as unknownone mentioned earlier....


Search for "unsafe" or "pointers."

They are supported. (Edit) As he said though, endian-ness is still a problem if you're running on a different architecture. And if you're doing packets the bitshift way, you've already screwed that one up.
_tao4229_ is offline  
Reply


Similar Threads Similar Threads
(B)Youtube Bot Sources Acc Creator Sources (S) E*GOLD
06/19/2011 - elite*gold Trading - 5 Replies
Thread sagt alles, ! Pn or Skype wenn interesse!



All times are GMT +2. The time now is 15:43.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.