SRL Archive - General

How's my standards?


Jason2gs

2007-06-14 12:53:30

So, I asked my friend this, and he said that my standards would probably be considered bad.

I'd like to ask you guys this :)

If me, and someone else had to standardize a script, this is what mine would turn out to look something like:

program New;

procedure Example;
begin
Writeln('This is am example');
end;

begin
Example;
end.

This is what someone else's would look like:

program New;

procedure Example;
begin
Writeln('This is am example');
end;

begin
Example;
end.

So, are my standards bad?

I also tend to make any variable I need a global variable. I am trying to get out of that habit, but I do tend to do that. Is that also considered using bad standards?

Hugolord

2007-06-14 12:55:41

From: Jason2gs
So, I asked my friend this, and he said that my standards would probably be considered bad.

I'd like to ask you guys this :)

If me, and someone else had to standardize a script, this is what mine would turn out to look something like:

program New;

procedure Example;
begin
Writeln('This is am example');
end;

begin
Example;
end.

This is what someone else's would look like:

program New;

procedure Example;
begin
Writeln('This is am example');
end;

begin
Example;
end.

So, are my standards bad?

I also tend to make any variable I need a global variable. I am trying to get out of that habit, but I do tend to do that. Is that also considered using bad standards?


i think (in my opinion) second is more accurate but not sure

bullzeye95

2007-06-14 12:58:27

Second is correct, and I like it better because I'm used to it. But eh, I don't really care. You're a good scripter, and it's not hard to read.

Jason2gs

2007-06-14 13:17:51

Hmm, well this is how the Pascal Formatter made it out:

program New;

procedure Example;
begin
Writeln('This is am example');
end;

begin
Example;
end.

That looks almost identical to the second example, so I guess that's the right way.

Alrighty, thanks guys. I guess I'm gonna have to start doing it that way :)

Bobarkinator

2007-06-14 13:36:34

Where is the pascal formatter you are talking about.

Also, standards are personnel, we have the "Scripting Standards" but when you script you should just try to make your own that slightly border the standards. If you look at one of Wizzup's scripts he has his variables way spaced out and all of his bold words capitalized :p

Smartzkid

2007-06-14 13:52:15

It's on mopar's site….somewhere

Jason2gs

2007-06-14 13:53:27

*Attachments*

So there isn't a set of standards you're supposed to stick to? Hmm, cool :)

Fearlesssss

2007-06-14 14:05:26

I like the second one best. The first is a bit weird:p

nielsie95

2007-06-14 14:21:07

Kaitniek's standards are the second..

PwNZoRNooB

2007-06-14 16:29:28

I use the second, It looks more clearer.
I hate it when people script like this
Procedure AAAGH;
begin
x:=5;
if(X=5)then
begin
y:=3
x:=2
if(X=2)and(Y=3)then
begin
y:=4
x:=5
if(X=5)and(Y=4)then
begin
y:=777
x:=666
if(X=666)and(Y=777)then
begin
writeln('Annoying to read this code')
end
end
end
end;
end;

It's very hard to see what begin is to what end quickly.