SA-MP Forums

Go Back   SA-MP Forums > Other > Everything and Nothing

Reply
 
Thread Tools Display Modes
Old 14/03/2017, 12:18 PM   #11
Cypress
Gangsta
 
Cypress's Avatar
 
Join Date: Dec 2009
Location: Germany
Posts: 937
Reputation: 127
Default Re: Why do people do this?

If you don't like it don't do it. It's just personal preferences, you might not like it but some people do. There isn't any mystery hidden behind it.
__________________

Welcome stranger. I like your attitude.
Cypress is offline   Reply With Quote
Old 14/03/2017, 12:24 PM   #12
Toroi
Gangsta
 
Toroi's Avatar
 
Join Date: Feb 2017
Location: Venezuela
Posts: 697
Reputation: 146
Default Re: Why do people do this?

Quote:
Originally Posted by Cypress View Post
If you don't like it don't do it. It's just personal preferences, you might not like it but some people do. There isn't any mystery hidden behind it.
Oh well, thank you. I was about to start reporting everyone doing it. But as you pointed out that it is a personal preference thing, I wont. You sherlock.

Of course it's personal preference. Drinking your own urine is a personal preference as well, yet I always get criticized. I am in my right to do the same.
Toroi is offline   Reply With Quote
Old 14/03/2017, 12:27 PM   #13
ISmokezU
Gangsta
 
Join Date: Aug 2016
Posts: 542
Reputation: 75
Default Re: Why do people do this?

What's wrong with you? You retarded or something?
ISmokezU is offline   Reply With Quote
Old 14/03/2017, 12:54 PM   #14
XBrianX
Huge Clucker
 
Join Date: May 2015
Location: Dubai
Posts: 456
Reputation: 75
Default Re: Why do people do this?

Yo why does everyone turn any discussion thread to a fucking war zone lmao
__________________

XBrianX is offline   Reply With Quote
Old 14/03/2017, 01:04 PM   #15
Variable™
Gangsta
 
Variable™'s Avatar
 
Join Date: Jul 2015
Posts: 823
Reputation: 200
Default Re: Why do people do this?

Reporting everyone for using their style of coding? Sad life.
__________________
Need a game server? Contact me for information.
Variable™ is offline   Reply With Quote
Old 14/03/2017, 01:06 PM   #16
]Kurence[
Banned
 
Join Date: Aug 2010
Location: Slovakia⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣
Posts: 257
Reputation: 215
Default Re: Why do people do this?

That was just ironic pls
]Kurence[ is offline   Reply With Quote
Old 14/03/2017, 03:45 PM   #17
Gammix
High-roller
 
Gammix's Avatar
 
Join Date: Jan 2015
Location: Canada
Posts: 1,773
Reputation: 858
Default Re: Why do people do this?

Freedom of code, you know.
__________________

Follow me on Github: Donate on Paypal:

Gammix is online now   Reply With Quote
Old 15/03/2017, 12:42 AM   #18
admantis
High-roller
 
Join Date: Sep 2009
Posts: 2,524
Reputation: 449
Default Re: Why do people do this?

Quote:
Originally Posted by Troydere View Post
Oh well, thank you. I was about to start reporting everyone doing it. But as you pointed out that it is a personal preference thing, I wont. You sherlock.

Of course it's personal preference. Drinking your own urine is a personal preference as well, yet I always get criticized. I am in my right to do the same.
Who the fuck do you think you are? The code police? There's people who code however the fuck they want. The only scenario where you'd be entitled to start bashing people for using totally normal and conventional coding standards is the one where you're paying them. Get a life.
admantis is offline   Reply With Quote
Old 15/03/2017, 01:23 AM   #19
AndySedeyn
High-roller
 
AndySedeyn's Avatar
 
Join Date: Feb 2014
Location: Belgium
Posts: 1,207
Reputation: 681
Default Re: Why do people do this?

I have tried out many styles of programming and I have adapted to a lot of them. If I were to display various scripts from different time periods in my career, the least you'd find is consistency. I like to switch up my style and my naming conventions—consider it a bad habit. It's all about finding your best setting. This is the style I've been practicing for the last two years:
PHP Code:
// Example: Player_NameOfFunction(args)
ScriptRelatedTo_NameOfFunction(args) {

    new
        
variable_used_one,
        
variable_used_two
    
;

    
Function_AssignsValuesToVars(variable_used_onevariable_used_two);

    new
        const 
localArr_SomeValues[] = {

            
51020305081,
            
84218432220
        
};

    
Function_ALotOfArguments(
        
args,
        
local_ArrSomeValues[0],
        
local_ArrSomeValues[5],
        
local_ArrSomeValues[10],
        
variable_used_one,
        
variable_used_two
    
);
    return;

There's not much I can say that hasn't been said already to answer your why-question. Try out different styles, it will only benefit you in team projects. In fact, you'll have to deal with switching up styles sooner or later if you are to pursue a career in any programming branch. A lot of companies have their own programming conventions.
AndySedeyn is offline   Reply With Quote
Old 15/03/2017, 03:06 AM   #20
Isolated
Gangsta
 
Isolated's Avatar
 
Join Date: Mar 2013
Location: United Kingdom
Posts: 801
Reputation: 155
Default Re: Why do people do this?

Every developer has a different style, although I usually try to adapt, and in the past have followed (or tried to) AndySedeyn's style of coding, I usually go for what I find the most readable, however what's considered good practice I find varies across the different languages.

When I develop, baring in mind I mainly develop websites, I tend to use camalCase for function names, and snake_case for variables.

Breaking things down into lists:

pawn Code:
new
    some_var,
    another_var[3],
    Float: and_another
;

I find the above a lot more readable, especially when you have a lot of declarations at the start of a function. You can easily see / add / remove variables from this list, apposed to having the same line for multiple variables.

Go with what you think is best as there really isn't any right or wrong style.
Isolated is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
for all you people who -rep pepper Everything and Nothing 13 05/02/2013 01:53 AM
Why some people lost all their things when login and some people not? CTCCoco Help Archive 1 07/07/2011 10:05 AM
SA-MP people plz help me! KILLER190 Client Support 5 29/10/2010 09:35 PM
People Scaming People's Severs coutanche7 General 19 28/12/2008 04:06 PM


All times are GMT. The time now is 12:57 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.