SRL Archive - Senior News and General

Turning SRL to Python


Wizzup?

2010-03-26 06:38:14

Since the developers forum is not very active, I'll post here.
Last night I took the liberty to throw the entire Simba Library in a library. (.dll / .so)
This way, we can very easily access all of Simba's functions. (Which pretty much equal SCARs looking at scripting purposes)

Since there would be no way to test the library but load it, I chose my favourite language - python - to test the library. It proofed ridiculously easy to use.

(Yeah, the syntax highlight messed up up a bit)

#!/usr/bin/env python
from ctypes import *

dll = CDLL('./libmml.so')
dll.test.restype = c_char_p
a = dll.test()
print a

dll.init.restype = None
dll.init()

class POINT(Structure):
_fields_ = [('x', c_int),
('y', c_int)]

dll.getmousepos.restype = POINT
b = dll.getmousepos()

print b.x, b.y

PPOINT = POINTER(POINT)

dll.returnpoints.restype = PPOINT
c = dll.returnpoints()

print c[0].x

dll.printpoints.restype = c_int
dll.printpoints.argtypes = [PPOINT, c_int]

d = dll.printpoints(c, 2)

dll.hoi.restype = None
dll.hoi.argtypes = [POINTER(c_int)]

e = c_int(5)
dll.hoi(byref(e))

print e


./test.py
hello world
1682 847
5
X, Y: (5, 10)
X, Y: (20, 30)
c_int(6)

Ehm… So this doesn't at all illustrate python's power, but it does illustrate that Simba can be used in any language, granted it is a bit flexible. The code you are seeing right now is a mere proof of concept, and before I expand it further I want to toss up the following idea… Suddenly I realized how DARN simple it was to import all of Simba's fuctions in python! Given python's extreme flexibility, I got the idea that it would perhaps be an idea to write SRL 5 in python. It is this idea that I would like you criticize.

For those who do not know python - it is an extremely dynamic, cross platform and fast language. It supports OOP, and has lots of other great features. (Think of it as PHP done right)
It is also worth noting this particular piece of code you are seeing would be hidden to the user - he would of course not have to implement the actual python <-> dll communication. Writing a few classes is easy, and all methods would just be wrappers for the dll calls, so the user can't really mess (and f*ck) with the dll either.

The use of the functions would be more or less the same. (We could make it OOP…)

Pos = ClientA.FindColor(MyColourObject, [0,0,500,400])

Given Python's awesome dictionaries, we can make SRL a lot more easy to use as well.

# Load some path
Paths = {'Varrock' : [(20,2),(40,4)], 'Falador' : [(20,10)]}
walkTo(Paths['Falador'])

It would also solve any problems we have with different standards - since Python does not allow but one standard. The entire begin…end constructs are actually replaced by indenting.

if 1 < 2:
print '1 is smaller than two. Woohoo!'
print 'This parrot is no more.'
mystr = 'wat'
# Prints:
1 is smaller than two. Woohoo!
This parrot is no more.

print mystr

#Prints :
wat

We could add tons of nice objects and classes.

Uhm… so I can go on ages why python is my favourite language, but it would be better to take a good look at the facts. Will it be accepted by the rest of the community? Would it be too hard to learn?

I'm probably biased, I've worked with Simba (and SCARs) interpreter for too long, and it's a mess. And if I may really honest, the pascal language isn't that brilliant either…

Maintaining both a Python and Pascal base would probably be a bit harder.

The Claw

2010-03-26 06:50:31

Yes, lets change to python. I'm learning it in uni atm, it's pretty powerful and easy. Pascal is old news now. Also, it would give me a good excuse to work on SRL again, combining it with RL :p

Dan Cardin

2010-03-26 06:54:47

if you are able to take Simba and put it in a dll then run it in python, could you not write srl in python, put it in a dll, and use the pascal interpreter and have the user code in pascal?

Wizzup?

2010-03-26 06:58:30

From: Dan Cardin
if you are able to take Simba and put it in a dll then run it in python, could you not write srl in python, put it in a dll, and use the pascal interpreter and have the user code in pascal?


Well - python is interpreted. Think of it like Pascalscript - it does not provide assembly code for your specific system. So this wouldn't be easy to do. The ``best'' solution would be to code SRL in Free Pascal and add it to (a/the) library. But this would have a serious impact on SRL; since everyone who doesn't have a Free Pascal compiler cannot modify SRL any more. So I think we don't want to go that way.

NCDS

2010-03-26 07:21:38

I would fully support switching to Python. I'm no master but I know a few thing's with it.

Though it seems we would have a much more effective macroing system, I don't know as to how many people would take the time to learn python. It's kind of overwhelming at first, or was for me at least.

The walking also reminds me somewhat of a reflection style, which I'm not too hot on, but I've come to terms with the fact that we may need to focus more on effectiveness now rather than having fun with color finding algorithms in pascal.

Boreas

2010-03-26 09:14:42

This is a very interesting idea. Actually, going to another bot to learn python with crossed my mind, this would be even better. Since we are somewhat of a programming community, using a language that is more useful in real life than pascal would be great. Of course the only problem is converting people that do not already know python. SRL and scripts are a great platform to learn on, but there still would need to be an equal or greater amount of tuts etc for new people. Upon arriving here, many people, including myself, did not know any language, or at least not pascal, so for new people it's no biggy. Some of the people that have been using pascal SRL for years and are interested in programming and expanding their horizons etc will also take the time to learn (many only through a scripts/SRL platform, and not just 'go read a python book/site'). However some people are resistant to change and just care about getting runescape scripts done the fastest, so pascal would have to remain fully supported, for quite a while.

TLDR Yes if full support and tutorials for both

The Claw

2010-03-26 09:46:04

SRL 4 could be kept updated for a while, until decent tuts are written, and more scripts are converted/coded. Even then it could still be kept updated by other members, or maybe have two dev teams?

HyperSecret

2010-03-26 10:39:51

I like the idea. I am up for this community to get a better language to program with.

Drunkenoldma

2010-03-26 10:49:10

I support this idea, I was planning to teach myself Python, because it seems an interesting language (and you can make web-applications with it! \o/); Now, if Python would become the primary SRL language, I'd be able to make scripts and help the community myself! (After that many years, I still lack the ability to even make an auto-talker *grins*)

TL;DR: Yes!

Home

2010-03-26 11:19:08

Yes i'm up to this challenge, i just need some tuts :) And here we go :D

~Home

Nava2

2010-03-26 12:46:20

Yes, under the assumption that pascal is supported, and tutorials are created as such.

Narcle

2010-03-26 12:51:00

I concur. Lets get a better coding language. And I've been really wanting to learn a new language that's actually useful unlike pascal (bla). So this will be a huge motivator to learn.

Nava2

2010-03-26 13:13:27

Kind of on topic, but if you want to use Eclipse to work with python: http://pydev.org/manual_101_install.html

Wizzup?

2010-03-26 14:57:35

From: Nava2
Kind of on topic, but if you want to use Eclipse to work with python: http://pydev.org/manual_101_install.html


You'll probably want to use vim.

——-

It is important to note however that some things may (especially at the start), less trivial. The one thing that pascal (IMO) is good at, is forms. Python is OK with forms too, but it's still a bit less convenient afaik.

NCDS

2010-03-26 15:49:38

I agree that Pascal would still need to be supported. SRL has been using it for far too long to just suddenly change.

I believe a lot of "true" members who are here to actually learn will really like this idea.

mixster

2010-03-26 16:03:58

I concur with the general consensus here - viva la revolution!

senrath

2010-03-26 16:14:32

I like the idea. Also, it would help a lot with standards.

Nava2

2010-03-26 16:22:32

I don't like vim. :>

Its too plain. I like eclipse.

Iron Man

2010-03-26 19:00:27

I support, as with what most people said that both to be supported somehow.

Wizzup?

2010-03-26 19:19:43

From: Iron Man
I support, as with what most people said that both to be supported somehow.


Ok, but how should both be supported. Pascal for SRL 4 and Python for SRL 5?
Writing two SRL 5's is a damn pain. :)

Iron Man

2010-03-26 19:44:47

From: Wizzup?
Pascal for SRL 4 and Python for SRL 5?


Yeah, I would imagine that would be the best way to go about it.

Nava2

2010-03-26 20:33:52

I would agree, SRL 5 could almost drop the 5 haha… Seems like its going to be *completely* different..

What advantage is there of using python over FPC though?

Especially when the MML is written in FPC.

Wizzup?

2010-03-26 20:53:19

From: Nava2
I would agree, SRL 5 could almost drop the 5 haha… Seems like its going to be *completely* different..

What advantage is there of using python over FPC though?

Especially when the MML is written in FPC.


Because everyone would need FPC is you were to use FPC…? Python is only a dll (a bit more if you want a lot of stdlibs)
Plus pascal as a language is inferior to python. Python has a super std. lib and documentation. ( http://docs.python.org/tutorial/ && http://docs.python.org/ )

Method

2010-03-26 22:10:49

It would be pretty convenient if Simba was written in Python as well, though I doubt you guys want to rewrite everything. Either way, this sounds like a good idea to me.

Nava2

2010-03-27 00:20:45

I do think this is a good idea.

I love the idea of OOP in SRL, I think its a great move forward.

I wouldn't know where to start though…

Wizzup?

2010-03-27 06:47:57

From: Method
It would be pretty convenient if Simba was written in Python as well, though I doubt you guys want to rewrite everything. Either way, this sounds like a good idea to me.


Python is fast, but not as fast as native code. Writing Simba in Python will cause considerable slowdowns. CDLL is a pretty good solution.

mastaraymond

2010-03-27 07:25:00

Yo be serious!?

Wizzup?

2010-03-27 18:48:12

From: mastaraymond
Yo be serious!?


It does seem like something worth trying. But I won't work on it too much just yet, first a Simba release for SRL 4. :)

Hobbit

2010-03-27 20:57:11

From: mixster
viva la revolution!


<3

From: Wizzup?
Pascal for SRL 4 and Python for SRL 5?


I also think this would be best

From: Nava2
I love the idea of OOP in SRL, I think its a great move forward.


I also think it will bring in more people. Aswell since in most highschools they teach java, which is OOP obviously.. Learning to script with simba would be easier to pick up on.

Nava2

2010-03-27 22:08:05

From: Hobbit
I also think it will bring in more people. Aswell since in most highschools they teach java, which is OOP obviously.. Learning to script with simba would be easier to pick up on.


Didn't even think of that, not to mention our community counter-parts all run oop bots which might make things slightly easier. Although, they only allow one object unless you induce subclasses.

Anyways, still more pluses :p

Smartzkid

2010-03-27 22:25:27

Do it! We'll finally be able to stand beside our scripts with pride, and the Java crowd won't have a damn thing to say!

Would it be possible to implement a separate dll to handle forms?

Are there any real CPU hogs left that are implemented in SRL? We might see a nice performance benefit if they were coded in a compiled language and called from python.

Coh3n

2010-03-27 23:14:04

Well, I know absolutely nothing about Python, but I'm all for learning a new language. To be quite honest, pascal isn't as exciting as it used to be, especially now that I'm learning Java.

I remember when I first came to SRL. Had absolutely no interest in programming. Hell, I barely knew what it was. :p But now, it's what I want to do as a career. I honestly don't think you're going to have many people argue about switching over. I mean, we're already turning a new leaf as it is with Simba and SRL 5. May as well take it to the next level. :)

E: I think I read someone else say this, but the majority of new people that come to SRL have no previous programming knowledge. I've heard that python is an easy language to learn, but would it be as easy for someone learning it as their first language?

The Claw

2010-03-27 23:36:55

Yup it is, its very simple. As I said earlier I'm learning it in uni right now, and it's taught from the very basics up. Maybe it would be worth downloading the lecture slides and uploading somewhere for this community? Would anyone in here be interested in reading at least? Probably breaking copyright laws and would get kicked out of uni if found out…but I dont give a fuck

Coh3n

2010-03-27 23:38:37

From: The Claw
Yup it is, its very simple. As I said earlier I'm learning it in uni right now, and it's taught from the very basics up. Maybe it would be worth downloading the lecture slides and uploading somewhere for this community? Would anyone in here be interested in reading at least? Probably breaking copyright laws and would get kicked out of uni if found out…but I dont give a fuck

And I would read them.

Brain

2010-03-27 23:42:20

From: The Claw
snip

Just ask your prof? I bet he wouldn't mind too much, maybe…you know him better than I do :p

Nava2

2010-03-27 23:42:44

do want…

The Claw

2010-03-28 00:00:14

Ok sure. Here are the lectures we've done so far, the next lecture becomes available online after we've done it in class (mondays, wednesdays, fridays) so if you guys find this helpful I can update it then. Please don't share these pdf's around, but feel free to summarise them to make tutorials out of them.

4a is the first, b and c are next.

Here's a resource the lecturer gave as well - http://docs.google.com/Doc?docid=ah72ftmddhqx_167tsgj8rft&hl=en

Wanted

2010-03-28 01:29:43

Simba
Git
Python

One headache after the other. :(

Coh3n

2010-03-28 11:02:06

From: IceFire908
Simba
Git
Python

One headache after the other. :(

Sure it seems like a lot, but since we're already making huge changes, why not go one step further if it's better for SRL?

nielsie95

2010-03-28 11:23:41

I agree with IceFire. I think it's too much..

Naum

2010-03-28 11:31:49

From: nielsie95
I agree with IceFire. I think it's too much..


I agree with Niels and IceFire, I think we should firstly establish some ground, then make changes later.

Coh3n

2010-03-28 11:39:06

From: Naum
I agree with Niels and IceFire, I think we should firstly establish some ground, then make changes later.

That's something I really don't like. Why would we make all the changes, get everything up and running, then all of the sudden make a huge change like switching programming languages? That would just cause more problems in my honest opinion.

Dan Cardin

2010-03-28 12:18:56

Ideally switching from SCAR to Simba would be a relatively small change in terms of procedure and scripting and such. It would make much more sense to get everything established, so that the devs aren't working on many things at once, then starting out small with python to see how it would work, get information ready for consumption by the masses rather than just saying "hey here are the python docs, learn 'em and start scripting!", etc.

Coh3n

2010-03-28 12:25:16

From: Dan Cardin
"hey here are the python docs, learn 'em and start scripting!", etc.

What's so hard about that? :p

I'm assuming that SRL isn't going to be finished for a while, and if it were to be written in Python, it would probably make more sense to switch then, rather than right away. There's no point in having Simba scriptable in python when SRL 4 is in pascal. :p

Nava2

2010-03-28 12:45:26

I think a good plan would be:

  1. SCAR -> Simba
  2. Maintain SRL 4 for Simba
  3. Code SRL 5 in Python (Create tutorials along the way)
  4. Release the tutorials, SRL 5, Simba w/ Python support etc.
  5. See how people react for scripts.
  6. Upon finding everyone loves SRL 5 (..hope..) stop working on SRL4, allow others to work on it.

I don't think it would *ever* be a good idea to drop the Pascal Script support, but I do think that its a good idea to move to a higher level and better language. Not to mention it allows us to use the MML to its full extent as it is OOP itself.

nielsie95

2010-03-28 12:49:22

If you want to use MML to its full extent you might just as well use FPC, which is relatively close to Pascal Script.

Nava2

2010-03-28 12:52:28

But, that means that its an absolute pain to get people to install FPC/Lazarus to the correct versions etc. Plus, the source for each is also massive.

Wizzup?

2010-03-28 12:52:51

From: Dan Cardin
Ideally switching from SCAR to Simba would be a relatively small change in terms of procedure and scripting and such. It would make much more sense to get everything established, so that the devs aren't working on many things at once, then starting out small with python to see how it would work, get information ready for consumption by the masses rather than just saying "hey here are the python docs, learn 'em and start scripting!", etc.


I agree, there is a lot of change. I did not suggest to switch to python right away either - first I want Simba to pull off. Git is least of my worries… If you all turn out to be unable to use a proper revision control system, we can always switch back to that horrible SVN. I'll just use the git wrappers around it.
The reason I'm suggesting Python is simply because it is a better language, and MUCH easier to provide on other platforms next to Windows.

So I think you summed my thought up well - first establish Simba for SRL 4.

At the moment, the SRL Developers aren't working on anything at all. Certainly not SRL 5. Only Nielsie did some stuff for it, which I committed. The only people who are actually working on multiple things for SRL and Niels, Ray and me. I think IceFire's still doing stuff for SRL a bit. The rest, I hardly hear of.

Nevertheless - this was only an idea. I still think it can be viable alternative to SRL 5, since hardly any work on it is being done. (Partially because Simba isn't released yet, I guess…)
But like I said, it was only an idea which I really have to dive into more to actually pull something off. By the time I'm done, we can always see what's a better alternative - I'm sure as hell not going to stop working on it. :)

So, if you want to work on SRL 5, do so. No one will stop you - I will probably hop in too. (Yes, I'm not just talking to SRL Developers.)

As to the ``Documentation'' note - I did not write any other code apart from the code that you see in my first post. How would I document non existing code? :)

Nava2

2010-03-28 13:10:41

I wrote stuff for SRL 5, but you guys said it was better to be put into PS !

Try not to discredit everyone, especially when we don't have the same amount of time available to use.

Town

2010-03-28 13:39:28

From: Boreas
This is a very interesting idea. Actually, going to another bot to learn python with crossed my mind, this would be even better. Since we are somewhat of a programming community, using a language that is more useful in real life than pascal would be great. Of course the only problem is converting people that do not already know python. SRL and scripts are a great platform to learn on, but there still would need to be an equal or greater amount of tuts etc for new people. Upon arriving here, many people, including myself, did not know any language, or at least not pascal, so for new people it's no biggy. Some of the people that have been using pascal SRL for years and are interested in programming and expanding their horizons etc will also take the time to learn (many only through a scripts/SRL platform, and not just 'go read a python book/site'). However some people are resistant to change and just care about getting runescape scripts done the fastest, so pascal would have to remain fully supported, for quite a while.

TLDR Yes if full support and tutorials for both



From: Coh3n
Well, I know absolutely nothing about Python, but I'm all for learning a new language. To be quite honest, pascal isn't as exciting as it used to be, especially now that I'm learning Java.

I remember when I first came to SRL. Had absolutely no interest in programming. Hell, I barely knew what it was. :p But now, it's what I want to do as a career. I honestly don't think you're going to have many people argue about switching over. I mean, we're already turning a new leaf as it is with Simba and SRL 5. May as well take it to the next level. :)

E: I think I read someone else say this, but the majority of new people that come to SRL have no previous programming knowledge. I've heard that python is an easy language to learn, but would it be as easy for someone learning it as their first language?


Agreed. I've long wondered why a learning-based community is based on a language that is 10 years out of use.

Home

2010-03-28 14:59:53


:)

I Truly hope that many other members will put thumbs up for this =)


~Home

Wizzup?

2010-03-28 15:50:41

From: Nava2
I wrote stuff for SRL 5, but you guys said it was better to be put into PS !

Try not to discredit everyone, especially when we don't have the same amount of time available to use.


I don't think the code you wrote had anything to do with SRL 5, if you are referring to the stack trace code…

Nava2

2010-03-28 16:09:49

I am, Nielsie wanted stuff for debugging, but its not something to talk about here, as its not really relevant.

Anyways, I love the picture Home! :)

mixster

2010-03-28 17:37:57

Oh, just as a somewhat side note and maybe not perfectly on topic but instead slightly down a side alleyway, if done, it should be made widely known that python.com is not the python language site and instead python.org is, because python.com is a porn site for those unaware (should make things fun, especially if people do links like this: http://www.python.org where the text says .org but the actual url is .com - so don't click it if you dislike nude people).

Boreas

2010-03-28 23:51:26

From: Nava2
I think a good plan would be:

  1. SCAR -> Simba
  2. Maintain SRL 4 for Simba
  3. Code SRL 5 in Python (Create tutorials along the way)
  4. Release the tutorials, SRL 5, Simba w/ Python support etc.
  5. See how people react for scripts.
  6. Upon finding everyone loves SRL 5 (..hope..) stop working on SRL4, allow others to work on it.

I don't think it would *ever* be a good idea to drop the Pascal Script support, but I do think that its a good idea to move to a higher level and better language. Not to mention it allows us to use the MML to its full extent as it is OOP itself.


I think that's a very sensible way to do it.

The Claw

2010-03-30 09:20:26

It was also be the killing blow to SCAR, lol.

nielsie95

2010-03-30 11:11:30

It might also turn out to be the quite opposite ;)

Wizzup?

2010-03-30 12:17:31

From: nielsie95
It might also turn out to be the quite opposite ;)


I guess that's only if Pascalscript support is to be dropped? Which won't happen.

Nava2

2010-03-30 12:22:16

From: The Claw
It was also be the killing blow to SCAR, lol.

wat?

Hobbit

2010-03-30 12:32:50

From: Nava2
wat?


I think he means simba w/ dual Pascal Script and Python support would kill the last of SCAR.

Nava2

2010-03-30 13:02:37

Oh, in that case I understand. I would have to agree as well.

Dan Cardin

2010-03-30 15:31:31

i don't understand the hate of SCAR? You're essentially making the same exact thing as SCAR not including the python support. Freddy is making Luna which is supposed to get rid of the errors/crashes which is really the only legitimate complaint i see from people. Personally, I would rather see them both in use, because one would encourage the other to better itself and create something similar to the "browser war" where they become better by using the competition. Otherwise I can easily see the same problem that people have with SCAR, happening with Simba because of developers that haven't much reason to better the program.

Coh3n

2010-03-30 15:34:00

But wouldn't Simba always be ahead because it has many developers as compared to SCAR which only have one? Also, I think one of the main reasons of this is because Simba is open source, am I right?

Dan Cardin

2010-03-30 15:43:52

you think? How many people do you think will care about the source? Im sure many people said "yay open sourced" when it was announced, but lets looks at Firefox, how large a percentage of their users do you think looks at the source and how many actually contribute to it? I'd be willing to bet that number is fairly small. And Many developers. As far as i know, right at the moment, all the developers are doing relatively different things and each doing their own parts of Simba. So lets say there is an error in a piece that mastaraymond and he is off betting that he can not use the computer for a month, what to do? Maybe the other developers could but maybe they couldn't. I'm not saying that its a bad thing to have a lot of developers, but i would definitely not say that its always good or always bad to only have one.

Coh3n

2010-03-30 15:51:32

From: Dan Cardin
you think? How many people do you think will care about the source? Im sure many people said "yay open sourced" when it was announced, but lets looks at Firefox, how large a percentage of their users do you think looks at the source and how many actually contribute to it? I'd be willing to bet that number is fairly small. And Many developers. As far as i know, right at the moment, all the developers are doing relatively different things and each doing their own parts of Simba. So lets say there is an error in a piece that mastaraymond and he is off betting that he can not use the computer for a month, what to do? Maybe the other developers could but maybe they couldn't. I'm not saying that its a bad thing to have a lot of developers, but i would definitely not say that its always good or always bad to only have one.

Lol'd.

I wasn't saying it's a bad thing to only have one dev, but having many certainly has it's advantages to the point where one dev probably couldn't keep up. That may not happen every time, but logically that's the case.

Wizzup?

2010-03-30 16:01:55

From: Dan Cardin
you think? How many people do you think will care about the source? Im sure many people said "yay open sourced" when it was announced, but lets looks at Firefox, how large a percentage of their users do you think looks at the source and how many actually contribute to it? I'd be willing to bet that number is fairly small. And Many developers. As far as i know, right at the moment, all the developers are doing relatively different things and each doing their own parts of Simba. So lets say there is an error in a piece that mastaraymond and he is off betting that he can not use the computer for a month, what to do? Maybe the other developers could but maybe they couldn't. I'm not saying that its a bad thing to have a lot of developers, but i would definitely not say that its always good or always bad to only have one.


I couldn't help laughing out loud a bit. One developer is never good.
One developer:
  • Has less time than two or more developers.
  • Has ``Ultimate'' power over his project. This may look like a good thing, but it usually isn't. Very often the developers are blind to certain changes, because they thing it's not a good thing. Having several developers helps heaps when trying to maintain reason. I think SCAR is perfect example of this.
  • Only can do so much. I have seen bugs in Raymond's code, and he seen bugs in my code. This has saved us both a lot of time, two pairs of eyes DO see a lot more than one pair. Often, a problem is so simple but often overlooked.
  • Has very limited access and knowledge about all platforms. Taking Simba for example again: I'm more or less the ``Linux'' guy. Raymond did most of the Windows stuff.
  • Look at this blog post by Freddy: http://freddy1990.com/devblog/?p=71 He is simply waiting on something that will never happen. He's waiting for FPC to fully implement the Windows API on other platforms. This is technically simply not possible. If he worked with other people, they could probably help him realize. However, as we all know, this is not case.
  • Has very few knowledgeable testers. As the one developer is the only one with access to the source code, only he can have the slightest idea about bugs. I have found a problems in Niels' Completion Code on the Linux platform, and committed the fixes. These are again fixes that Niels would have not easily found.

And I think the problems with SCAR a well known. It's simply buggy. This can actually raise a lot of annoyance at the users.
I don't have any personal ``hatred'' against SCAR. But I do slightly dislike the way it's developers does his business.

Dan Cardin

2010-03-30 16:10:25

My point with mentioning Luna was to say that Luna is supposed to be bug free before release because it is being completely rewritten. Not you nor I knows it to be true that it will or won't be bug free, but likely as not, he will have intentioned his efforts towards the current "big" bugs that annoy people in SCAR. Other smallisher bugs can be dealt with. I'm sure Simba is not bug free either, so I don't see that as a way to say that Simba is better.

One developer can be better than more than one. Its pretty much true, however much you don't think it is. I'm not saying that its true in this case, I'm just saying that until Simba is at a releasing state and Luna is out, then you can't really say which it is in this case.

senrath

2010-03-30 16:24:20

I'd like to point out that there is essentially no such thing as a bug free, complex program.

The Claw

2010-03-30 19:38:09

Nothing is bug free upon release, on average theres a logic error in code every 1000 lines (according to my IT professor at uni). Windows XP, which has ~5 million lines of code, was released with 50, 000 bugs or so. Hence all the patches and upgrades. Also, a single developer is more likely to not notice them, so there would probably be more.

Killing blow as in once we move to python completely (and drop SRL 4, thats the plan yea? after a while) unless Freddy wants to convert SCAR to python as well, I highly doubt he would get many users

Smartzkid

2010-03-30 22:09:54

Is there any way to allow mixing of pascal and python in a userfriendly way? Would it be possible to code SRL 5 in python and call routines from pascal?

If it could be done, it would greatly lessen the learning curve for all existing scripters, and would nullify the possibility that Simba would flop should the community not want to switch from* pascal.


Just a thought that popped into my head - competition drives innovation.

Perhaps SCAR will catch up. This community is what drives SCAR to evolve; maybe the move to python will be followed. The ball is in Freddy's court now!

Whatever the future, non-java RS cheating is starting to look far brighter!

Dan Cardin

2010-03-30 22:10:42

My point was errorless code. The point was the crap that people complain about with SCAR now will more than likely be very fixed because otherwise it would defeat the purpose of rewriting and i doubt he'd release it.

And my other point was to not competition is good. Yea, you should be thinking about getting new users, but destroying SCAR and freddy shouldn't be the goal since competition is good for both of you. Whether or not moving to python is a good move, i cannot say, but i think if its haphazardly done, then it could be bad, confusing and raise a lot more of that annoyance to users that Wizzup mentioned than having bugs would.

EDIT: yay. smartzkid understands what im talking about. :)

Wizzup?

2010-03-31 03:16:43

From: Smartzkid
Is there any way to allow mixing of pascal and python in a userfriendly way? Would it be possible to code SRL 5 in python and call routines from pascal?

If it could be done, it would greatly lessen the learning curve for all existing scripters, and would nullify the possibility that Simba would flop should the community not want to switch to pascal.


Just a thought that popped into my head - competition drives innovation.

Perhaps SCAR will catch up. This community is what drives SCAR to evolve; maybe the move to python will be followed. The ball is in Freddy's court now!

Whatever the future, non-java RS cheating is starting to look far brighter!


Meh, any PascalScript <-> Python bindings will be a true pain. FPC bindings alone are already a pain:


function getmousepos(var t: tpoint): integer; cdecl;

begin
try
C.IOManager.GetMousePos(t.x,t.y);
result := RESULT_OK;
except on e : Exception do
begin
result := RESULT_ERROR;
last_error := PChar(e.Message);
end;
end;
end;

That is a libmml binding for get mouse pos. There is no easy way to handle Pascal exceptions from outside Pascal. At least, none that I know. Writing wrappers for all the MML functions alone will already be a lot of work. Imagine having to do this for every SRL function as well.

From: Dan Cardin
My point was errorless code. The point was the crap that people complain about with SCAR now will more than likely be very fixed because otherwise it would defeat the purpose of rewriting and i doubt he'd release it.


What makes you believe it will be more stable though? One of the main problems was always that he doesn't really test his stuff… He never runs a script or anything. This goes for pretty much all of the additions he made.

Dan Cardin

2010-03-31 06:54:46

Yes, he's going to go through the trouble of releasing a complete rewrite just so he can release the same thing with the same errors. Have you run the preview yet?

Wizzup?

2010-03-31 18:56:39

From: Dan Cardin
Yes, he's going to go through the trouble of releasing a complete rewrite just so he can release the same thing with the same errors. Have you run the preview yet?


I don't see how that matter, to be honest. It lacks a great amount of features and wasn't really capable of doing much.
<Off topic?>

Dan Cardin

2010-04-01 06:59:45

Indeed it was, but that was a very early prerelease and i didn't see anybody posting all sorts of errors for it. Being silly about it makes no difference to the fact that when people completely redo things, they usually focus on making the parts that were bad better. In this case it would amount to getting rid of the common SCAR errors and therefore my point made (though all these semantics must have muddled it). Its pointless to argue anyway since its not released.

Wizzup?

2010-04-01 08:30:09

From: Dan Cardin
Indeed it was, but that was a very early prerelease and i didn't see anybody posting all sorts of errors for it.


My guess would be that no one could test it more than make a small script to move the mouse and find a (3.x) colour. After that they went to the more feature-full SCAR.

From: Dan Cardin

Being silly about it makes no difference to the fact that when people completely redo things, they usually focus on making the parts that were bad better. In this case it would amount to getting rid of the common SCAR errors and therefore my point made (though all these semantics must have muddled it). Its pointless to argue anyway since its not released.


Exactly, so why bring it up? :)

Yakman

2010-04-01 09:56:06

At first I was sceptical, but after reading some of the points raised in this thread I think I'm convinced.
As long as you keep backwards comparability with pascal on Windows, so that the common folk who up till now use SCAR to auto can easily switch all their scripts to Simba.

Ejjman

2010-04-01 14:54:16

How often is python used in the 'real world'? Will kids be able to take the knowledge and maybe use it later in a field?

I mean, pascal is good because it's easy and you get the basics, but I don't think it's useful in the 'real world'.


For change!

Coh3n

2010-04-01 14:56:27

From: Ejjman1
How often is python used in the 'real world'? Will kids be able to take the knowledge and maybe use it later in a field?

I mean, pascal is good because it's easy and you get the basics, but I don't think it's useful in the 'real world'.


For change!

I can't say for sure that Python is because I don't know much about it, but I'm sure the OOP concepts are. :)

Boreas

2010-04-01 15:40:55

Maybe between 16 and 166 times as much according to github.
http://github.com/search?q=python&x=0&y=0
http://github.com/search?q=pascal&x=0&y=0

I've only been reading about python a little, but it does seem like the syntax and readability is good for multi-person projects like SRL. Also a good balance between being easy to learn for new people, while having the power for the big boy stuff.

lordsaturn

2010-04-01 19:30:41

weee :D

Smartzkid

2010-04-01 19:39:56

Autodesk Maya is python scriptable.

What else could you want!

Wanted

2010-04-02 00:18:49

Why not just do Java?

Wouldn't it suit our purposes better if we are going to spend all this time learning a new language.

Ohwait, the people that suggested this already know python.:closedeyes:

The Claw

2010-04-02 00:34:05

From: Ejjman1
How often is python used in the 'real world'? Will kids be able to take the knowledge and maybe use it later in a field?

I mean, pascal is good because it's easy and you get the basics, but I don't think it's useful in the 'real world'.


For change!


Google and youtube both run on python

Nava2

2010-04-02 00:37:44

From: IceFire908
Why not just do Java?

Wouldn't it suit our purposes better if we are going to spend all this time learning a new language.

Ohwait, the people that suggested this already know python.:closedeyes:


Seriously, read before you post. It was already stated that java and the MML cannot be integrated. Not to mention, in my opinion, python is a better fit for what we want for scripting. Much faster development language etc.

Wanted

2010-04-02 00:52:18

You missed the point. <.<

Wizzup?

2010-04-02 03:35:41

From: IceFire908
Why not just do Java?

Wouldn't it suit our purposes better if we are going to spend all this time learning a new language.

Ohwait, the people that suggested this already know python.:closedeyes:


You seem to forget something… How come they already know it? It's not like you get born with knowledge about the python language. I guess they must have… learned it???
And as stated by the rest, most don't know Python but seem willing to learn it.

Suggesting java is pretty silly seeing it is a horrible language…

mastaraymond

2010-04-02 05:21:00

From: Wizzup?
You seem to forget something… How come they already know it? It's not like you get born with knowledge about the python language. I guess they must have… learned it???
And as stated by the rest, most don't know Python but seem willing to learn it.

Suggesting java is pretty silly seeing it is a horrible language…

Yet it's native with Runescape :p

Wizzup?

2010-04-02 07:47:55

Small example of the mouse class:


# Initialize mouse
m = Mouse(DLL)

# Print mouse pos + button states
print m.getPos()
print m.getButtonStates()

# Print mouse pos + button states
print m[(Mouse.Pos, Mouse.Left, Mouse.Right, Mouse.Middle)]

# Move mouse
m.setPos((500, 300))

# Move mouse
m[Mouse.Pos] = (250,250)

# Move mouse and then hold left button down
m[(Mouse.Pos, Mouse.Left)] = ((200, 500), True)

# Release left mouse button:
m.setButtonState(Mouse.Left, False)

# Release all mouse buttons
m[(Mouse.Left, Mouse.Right, Mouse.Middle)] = [False for x in range(3)]

# Free mouse object
del m

Smartzkid

2010-04-02 19:41:51

Using java would be stereotypical. 'Oh, it's a RuneScape bot? It must be Java!'

Python would give us something different than the 'competition', a language that can be shown as vastly superior.

Wanted

2010-04-02 22:44:35

From: Smartzkid
Using java would be stereotypical. 'Oh, it's a RuneScape bot? It must be Java!'

Python would give us something different than the 'competition', a language that can be shown as vastly superior.


Java is the native language of runescape. How can you get 'vastly superior' than that?

senrath

2010-04-02 23:06:08

I like Java, and programming in it, but I'd have to say that python is probably easier to use.

Boreas

2010-04-03 00:09:44

There are few python vs java pages out there, but one of the most interesting things from a RS-uses-java standpoint is jython.

Wizzup?

2010-04-03 09:27:58

From: Smartzkid
Using java would be stereotypical. 'Oh, it's a RuneScape bot? It must be Java!'

Python would give us something different than the 'competition', a language that can be shown as vastly superior.


It isn't really about stereotypes. Java as a language - with all due respect - is simply not something I'd want to use. It's forced OOP combined with the massive installation package (at least on windows) and the JNI (ew!) makes it not at all a suitable language to use. Python, on the other hand, is one DLL, although arguably, you may need additional modules for it.

Java == Bloat

Narcle

2010-04-03 22:36:48

Its possible to just have both right? I'd like to learn other languanges as stated before so would be nice to have python in something I know well. (scripting for runescape)

I'm all for it but it'll end up as a side project in the end no matter how we throw it in. People will stick with what they known and the programmers/higher end scripters will try out python.

Town

2010-04-04 10:27:18

From: IceFire908
Java is the native language of runescape. How can you get 'vastly superior' than that?


The only interaction we have with Runescape is on the surface. I don't see matching languages as an advantage. I'm familiar with both Python and Java, Java moreso, and I would rather see a a move to Python.

Wanted

2010-04-04 14:23:13

From: Town
The only interaction we have with Runescape is on the surface. I don't see matching languages as an advantage.


I was merely pointing out that it may be useful for more people in the SRL community to learn Java than python for obvious reasons.

Nava2

2010-04-04 20:13:15

From: IceFire908
I was merely pointing out that it may be useful for more people in the SRL community to learn Java than python for obvious reasons.


Like?

http://pythonconquerstheuniverse.wordpress.com/category/java-and-python/

Wanted

2010-04-04 22:28:09

From: Nava2
Like?

http://pythonconquerstheuniverse.wordpress.com/category/java-and-python/


< Reflection.

Wizzup?

2010-04-05 04:34:38

From: IceFire908
< Reflection.


You're not making much sense.
Reflection has no use in common day programming tasks, for companies, as you preferred to put the focus on.

Smartzkid

2010-04-05 06:41:28

From: IceFire908
< Reflection.


But we already have reflection, and will continue to…?

Wanted

2010-04-05 14:15:17

From: Wizzup?
You're not making much sense.
Reflection has no use in common day programming tasks, for companies, as you preferred to put the focus on.


But we are not trying to create SRL for common day companies, rather the targeted age of runescape players/ online gamers… usually between the ages of 11-20. The real reason SRL works so well is because it is easy to learn pascal. I can understand giving simba some sort of capability to interpret and use python, the part I don't understand is where SRL is coming into this picture. I could understand if it was something that required work that absolutely could not be done in pascal, like in the instance where you would need a plugin ect… for something very specific that needs optimizing. But FFS I see people talking about writing SRL 5 core in python, which is simply, just a bad idea.

From: Smartzkid
But we already have reflection, and will continue to…?


Not really, reflection remains and continues to be a unstable garbage pile because it is not well maintained. Mainly because not a lot of people know Java /know it well enough to maintain it. If we are going to pour manpower and time into learning python, why not just redirect it toward learning Java? That way we can actually do something constructive like have a large group of Java programmers who spend time on reflection.

___________________________________________________

I think the real problem with this thread is that is vague on its intentions and drastic on its potential implications.. .which is becoming rather annoying to discuss.

Wizzup?

2010-04-05 16:29:08

From: IceFire908
But we are not trying to create SRL for common day companies, rather the targeted age of runescape players/ online gamers… usually between the ages of 11-20. The real reason SRL works so well is because it is easy to learn pascal. I can understand giving simba some sort of capability to interpret and use python, the part I don't understand is where SRL is coming into this picture. I could understand if it was something that required work that absolutely could not be done in pascal, like in the instance where you would need a plugin ect… for something very specific that needs optimizing. But FFS I see people talking about writing SRL 5 core in python, which is simply, just a bad idea.


I think you were the one to bring Java up because it reflect real world skills more…?

Anyway, Python is just as easy to learn as Pascal. At the moment I am only writing python bindings for the Simba library, MML. This means that the people who want to play with python and use MML have an easy and nice (OOP) library to do so.
Making SRL itself in Python would also be an significant advantage, since it would permit us to go beyond those basic functions that SCAR and Simba offer. Readfile / Writefile, stuff like that. You want SQL bindings for your SRL Script stats? You want SRL to locally keep track of all your players? No problem, just import sqlite.

With Simba, we would have to either write an OOP wrapper around the C library, or find some other bindings. Then export it (non-oop) to PascalScript, where people will use it. This is an tremendous effort for a small feature. Aside from being a lot of work, it will also be less developer-friendly than the Python bindings. In the end it get's the job done, but it is extremely inefficient. SQL is just one example, but I think it demonstrates quite nicely why using Python for SRL (and scripts) would be a huge advantage.

But as stated in my previous posts; SRL 5 will be initially be written in Pascal. So get to it! :D


From: IceFire908
Not really, reflection remains and continues to be a unstable garbage pile because it is not well maintained. Mainly because not a lot of people know Java /know it well enough to maintain it. If we are going to pour manpower and time into learning python, why not just redirect it toward learning Java? That way we can actually do something constructive like have a large group of Java programmers who spend time on reflection.


Because Java is not a cool language?
Seriously though, let's face it. If Reflection really was that good for SRL, it would have gotten the better hand of pure colour finding. This has not happened. Partially you complete knowledge over the client; but is that really what we are after?

I think it's rather strange to assume that learning Python is NOT something constructive. Spending a lot of time in Reflection? You'd be done and get bored in weeks.

I don't see how Python does not lead to doing something constructive.

Method

2010-04-05 17:53:33

I was under the impression that IceFire was claiming Java to be more useful for RuneScape cheating than Python because of its ability to interface directly with the RuneScape client. You guys seem to have brought up this argument about real world applications and ended up talking about two different things. Am I wrong??

Wanted

2010-04-05 22:10:39

From: Wizzup?
I think you were the one to bring Java up because it reflect real world skills more…?


Nope.

From: Wizzup?
Anyway, Python is just as easy to learn as Pascal.

Lol not even close.
From: Wizzup?

At the moment I am only writing python bindings for the Simba library, MML. This means that the people who want to play with python and use MML have an easy and nice (OOP) library to do so.

Yea that's great, but in SRL would be a complete mess.

From: Wizzup?
Making SRL itself in Python would also be an significant advantage, since it would permit us to go beyond those basic functions that SCAR and Simba offer. Readfile / Writefile, stuff like that. You want SQL bindings for your SRL Script stats? You want SRL to locally keep track of all your players? No problem, just import sqlite.


Significant advantage for whom? Can a simple plugin not be written… rather than the entire source code based in it? I have no doubt python has less limitations than pascal… but what are these limitations, I do not even know… therefor it is not a problem tbh.

From: Wizzup?
With Simba, we would have to either write an OOP wrapper around the C library, or find some other bindings. Then export it (non-oop) to PascalScript, where people will use it. This is an tremendous effort for a small feature. Aside from being a lot of work, it will also be less developer-friendly than the Python bindings. In the end it get's the job done, but it is extremely inefficient. SQL is just one example, but I think it demonstrates quite nicely why using Python for SRL (and scripts) would be a huge advantage.


Wut?

From: Wizzup?
But as stated in my previous posts; SRL 5 will be initially be written in Pascal. So get to it! :D


:norris:




From: Wizzup?
Because Java is not a cool language?
Seriously though, let's face it. If Reflection really was that good for SRL, it would have gotten the better hand of pure colour finding. This has not happened. Partially you complete knowledge over the client; but is that really what we are after?


Java is gay as hell tbh, bunch of foreign shit. Lol.

Reflection it self is BAD for SRL (the include that is) but GOOD for the community. The only reason it hasn't gotten the better hand of it (well it has just not for long xD) is because Jagex comes out with an update and everyone is all going to team
MethodAndBenLandAreKindaInAcitveButStillHelpingWithItSomeSoYeaGoodLuckEveryoneLOL

I would like to understand the client, yes. I think a lot of people would find having the ability to work on reflection/SMART ect.. to be a much more useful talent than Python if they are trying to write a Runescape Bot/type thingy.

From: Wizzup?
I think it's rather strange to assume that learning Python is NOT something constructive. Spending a lot of time in Reflection? You'd be done and get bored in weeks.

I don't see how Python does not lead to doing something constructive.


Constructive, yes. Constructive for SRL? Who knows?

I mean really we can sit here all day long and have these discussions but we wouldn't even worry about this kinda stuff if all this effort was put towards the Include.. lately it's been all about anything BUT the include. Simba/stats/MML/Python/Forums registration/Restructure… maybe that's just from my prospective though.

From: Method
I was under the impression that IceFire was claiming Java to be more useful for RuneScape cheating than Python because of its ability to interface directly with the RuneScape client. You guys seem to have brought up this argument about real world applications and ended up talking about two different things. Am I wrong??


That is correct.

Boreas

2010-04-06 00:03:32

@Easy to learn
Executable pseudocode


@Method, what percentage would you estimate is the amount of knowledge required to write a script for ibot/etc out of the amount of knowledge required to maintain reflection?

Method

2010-04-06 01:45:39

From: Boreas
@Method, what percentage would you estimate is the amount of knowledge required to write a script for ibot/etc out of the amount of knowledge required to maintain reflection?


Well, you'd need some basic knowledge of Java involving methods, fields, variables, the API, etc. to make a script for iBot or one of the other Java bots, but that is nothing close to the amount required to build an updater and look through the client for fields you're interested in (and then to build patterns to locate those fields across client revisions).

edit: That's one of the reasons why botting (and private server) communties are so poor. People learn just enough to get by and don't take the time to really learn the language to investigate further applications of it.

HyperSecret

2010-04-06 01:46:11

From: Boreas
@Easy to learn
Executable pseudocode


@Method, what percentage would you estimate is the amount of knowledge required to write a script for ibot/etc out of the amount of knowledge required to maintain reflection?



I was able to write a script for iBot, RSBot, etc… before taking any java classes and was not able to make an updater or anything to really help with reflection (on the java side).

I really want to try again since I took a Java class.

Wizzup?

2010-04-06 04:07:23

From: IceFire908
Lol not even close.


Have you tried it? No. Have others tried it? Yes.


From: IceFire908
Yea that's great, but in SRL would be a complete mess.


What SRL are you talking about?


From: IceFire908

Significant advantage for whom? Can a simple plugin not be written… rather than the entire source code based in it? I have no doubt python has less limitations than pascal… but what are these limitations, I do not even know… therefor it is not a problem tbh.



Wow… This is extremely short sighted. :-/
If you don't know the limitations then it is not worth it?

Pascal on itself is not limited, but Pascal Script is VERY limited.
But if you want to write all the plugins, go right ahead.

From: IceFire908

Java is gay as hell tbh, bunch of foreign shit. Lol.

Reflection it self is BAD for SRL (the include that is) but GOOD for the community. The only reason it hasn't gotten the better hand of it (well it has just not for long xD) is because Jagex comes out with an update and everyone is all going to team
MethodAndBenLandAreKindaInAcitveButStillHelpingWithItSomeSoYeaGoodLuckEveryoneLOL

I would like to understand the client, yes. I think a lot of people would find having the ability to work on reflection/SMART ect.. to be a much more useful talent than Python if they are trying to write a Runescape Bot/type thingy.


Is this only because you believe that SRL should turn into a Java botting community?


From: IceFire908
Constructive, yes. Constructive for SRL? Who knows?

I mean really we can sit here all day long and have these discussions but we wouldn't even worry about this kinda stuff if all this effort was put towards the Include.. lately it's been all about anything BUT the include. Simba/stats/MML/Python/Forums registration/Restructure… maybe that's just from my prospective though.


Seems like priority to me.

From: IceFire908

That is correct.


In that case you are just digging up arguments we have had years ago, which do not even in the least relate to this subject. ;)

Wanted

2010-04-06 10:53:29

From: Wizzup?
Have you tried it? No. Have others tried it? Yes.


Easy, yes.

Easy as learning pascal? And for a first timer?

It is no where near as easy to pick up Python, even from an obvious prospective the source is more complex.




From: Wizzup?
What SRL are you talking about?


The include obviously, lets say one thing goes wrong in the source… who is going to interpet it, let alone know how to fix it? The include (which is a significant portion behind every single script) won't even be readable to a large %ge of the intented user. Even if it works correctly, then the source isn't readable to the intened user either, so then properly using it is purely guess or negligence for the functions they are using out of the include.

Seriously, every time I use ANYTHING out of SRL, I read through the source first. Why? So I know what the hell I'm doing.





From: Wizzup?
Wow… This is extremely short sighted. :-/
If you don't know the limitations then it is not worth it?

Pascal on itself is not limited, but Pascal Script is VERY limited.
But if you want to write all the plugins, go right ahead.


What lolol? Short sighted?

I'm being realistic here, the community isn't going to follow every single decision made. Switching to python is pretty dam drastic even if it's going to be applied in small places it hides more from the intended user. And the cons outweigh the pros.

Not knowing the limitations is but a small factor in the equation.



From: Wizzup?
Is this only because you believe that SRL should turn into a Java botting community?


Not even close.

Why would I, or anyone for that matter, want SRL to be a Java botting community?

It would make more sense if the people writing all these scripts/ rs specific functions to understand the client, which is written in Java, and not python.




From: Wizzup?
Seems like priority to me.


Priority over the Include??



From: Wizzup?
In that case you are just digging up arguments we have had years ago, which do not even in the least relate to this subject. ;)



Digging them up?

The've been floating around this place daily ever since 3 years ago.

It directly relates to this subject, a proposed direction movement is made and not in the direction that has been pushed for the past years brings up odd suspicions, I can't even imagine if this was being discussed in members or lower.

Town

2010-04-06 10:53:42

Since Icefire is the only (?) one of us in this discussion who has scripts that are currently being worked on and updated, he may have a more representative opinion of how the community would respond to this change.

Is a poll necessary here, or maybe a discreet one in the members forum, of who will actually have the interest to develop scripts in a second language?

Nava2

2010-04-06 11:31:54

I think what IceFire is missing is the fact that change is a good thing, we cannot move forward if we are always adverse to change.

People don't know python because we haven't supported it yet! How can you argue that people don't know a language when we haven't even asked them too!

If we had supported Python from the beginning, and then said ``Lets switch to pascal.'', the same arguments would apply, which is just ridiculous in nature!

Many many people have asked for Simba to support OOP, not necessarily support Python, but two and two go together.

Wizzup?

2010-04-06 11:35:58

From: IceFire908
Easy, yes.

Easy as learning pascal? And for a first timer?

It is no where near as easy to pick up Python, even from an obvious prospective the source is more complex.


Again, yes. Just as easy. You're just used to Pascal and not to Python, that's why Pascal seems harder.

From: IceFire908
The include obviously, lets say one thing goes wrong in the source… who is going to interpet it, let alone know how to fix it? The include (which is a significant portion behind every single script) won't even be readable to a large %ge of the intented user. Even if it works correctly, then the source isn't readable to the intened user either, so then properly using it is purely guess or negligence for the functions they are using out of the include.


I mean SRL 4 / SRL 5 Pascal / SRL 5 Python. Not SRL as the ``include'' to create more ambiguity. I think your arguments make no sense, btw. If people know python, then they will simply fix it the same way as they do know with pascal? You're simply resolving to your previous point, and so will I, as counter argument.

From: IceFire908
Seriously, every time I use ANYTHING out of SRL, I read through the source first. Why? So I know what the hell I'm doing.


Right, so you think Python is not readable then. See the previous points, again.

From: IceFire908

What lolol? Short sighted?

I'm being realistic here, the community isn't going to follow every single decision made. Switching to python is pretty dam drastic even if it's going to be applied in small places it hides more from the intended user. And the cons outweigh the pros.


You believe that the cons outweigh the pros. Yeah, it is drastic. So is SRL 4 and the extreme drop of activity in the last few months.

From: IceFire908

Not even close.

Why would I, or anyone for that matter, want SRL to be a Java botting community?

It would make more sense if the people writing all these scripts/ rs specific functions to understand the client, which is written in Java, and not python.


Yeah, so you want to focus on coding java.

From: IceFire908

Priority over the Include??


Essentially, yes. They are the steps that are to be taken before we can start working further on SRL 5.


From: IceFire908

Digging them up?

The've been floating around this place daily ever since 3 years ago.

It directly relates to this subject, a proposed direction movement is made and not in the direction that has been pushed for the past years brings up odd suspicions, I can't even imagine if this was being discussed in members or lower.


Let me rephrase: You're constantly restating your views that hardly anyone seems to share, about Reflection. Reflection has NO relation to this discussion. Do you even realise that you can use SMART's reflection just as easily in Python?

HyperSecret

2010-04-06 12:48:15

From: IceFire908
Easy, yes.

Easy as learning pascal? And for a first timer?

It is no where near as easy to pick up Python, even from an obvious prospective the source is more complex.


It would probably be just as easy to learn if we have the same type of tutorials for it as we do for using Pascal. I have never written anything in Pascal outside of using it with SCAR.

So if we had the tutorials to teach people how to use Python directed towards Runescape autoing, just like we do Pascal here, I would assume people would be able to pick it up just as easily.

Ejjman

2010-04-06 13:09:02

From: Wizzup?
Again, yes. Just as easy. You're just used to Pascal and not to Python, that's why Python* seems harder.


Fixed. All these P words are getting you mixed up!

My father works for an IT company, and a couple of his employees work with Python. They compare Java side-by-side with Python, picking Python as the better of the two, he said.


I also think that it looks hard just from looking at samples, but I also thought that Pascal was hard. So I'm with HyperSecret on that.


If your claims that it is 'just as easy' as Pascal Script, I am for the switch.

Smartzkid

2010-04-06 13:28:16

A byproduct of having a well-equpped python ide would be an influx of people using it simply for its automation abilities. This is a big plus, because it would provide a larger group of people to draw knowledge and technique from. (and ad revenue)

It is clearly time to move on from pascal, why even write srl 5 in it?

mastaraymond

2010-04-06 13:31:32

From: Smartzkid
A byproduct of having a well-equpped python ide would be an influx of people using it simply for its automation abilities. This is a big plus, because it would provide a larger group of people to draw knowledge and technique from. (and ad revenue)

It is clearly time to move on from pascal, why even write srl 5 in it?

Because Python integration is by nowhere finished. It would take some time before people would get to know python etc.. Making it more a long-term project. A sudden switch would do no-one good

Nava2

2010-04-06 15:20:45

My plan is still valid IMO.

Wanted

2010-04-06 16:37:53

From: Nava2
I think what IceFire is missing is the fact that change is a good thing, we cannot move forward if we are always adverse to change.


Why is change always a good thing… just because we change something, it automatically makes it good. and the best idea available?

From: Nava2
People don't know python because we haven't supported it yet! How can you argue that people don't know a language when we haven't even asked them too!


Have Wizzup? start a discussion in members or lower, or better yet… move this thread into members.

From: Nava2
If we had supported Python from the beginning, and then said ``Lets switch to pascal.'', the same arguments would apply, which is just ridiculous in nature!


Because the same exact points would apply, even if pascal was better… one sweeping statement after the other.

From: Nava2
Many many people have asked for Simba to support OOP, not necessarily support Python, but two and two go together.


Then do it for Simba, why drag SRL into the picture?

From: Wizzup?
Again, yes. Just as easy. You're just used to Pascal and not to Python, that's why Pascal seems harder.


No it really isn't

Not used to it?

Yea just me and a majority of everyone else on this forum. No big deal.


From: Wizzup?
I mean SRL 4 / SRL 5 Pascal / SRL 5 Python. Not SRL as the ``include'' to create more ambiguity. I think your arguments make no sense, btw. If people know python, then they will simply fix it the same way as they do know with pascal? You're simply resolving to your previous point, and so will I, as counter argument.


If people know it then they can, but people don't know it.. therefor when they open their SRL folder and try and understand it, they won't be able to with out going out of their way.



From: Wizzup?
Right, so you think Python is not readable then. See the previous points, again.


Not readable to the masses, which is the most important aspect of open source.



From: Wizzup?
You believe that the cons outweigh the pros. Yeah, it is drastic. So is SRL 4 and the extreme drop of activity in the last few months.


The cons do outweigh the pros. Even if people do learn it, it's years of experience gone.



From: Wizzup?
Yeah, so you want to focus on coding java.


So that more people understand the client. I don't see how you can argue using python is better than understanding the client. But you didn't really say that you just kinda replied with "Yea. Ok" <.<



From: Wizzup?
Let me rephrase: You're constantly restating your views that hardly anyone seems to share, about Reflection. Reflection has NO relation to this discussion. Do you even realise that you can use SMART's reflection just as easily in Python?


The very reason I have had to restate my views is because they have been interpreted either on purpose or people not reading my posts entirely and somehow seeing this:

"Oh Java >>>>>>>>> Python"

When in fact I'm not saying that at all. Method spelled it out pretty clearly.

Lol, how is understanding the source code of runescape the same as using SMART's reflection?

I'm pretty sure you're right, using WalkToTile in python is just as easy as it is in python, but I'm not even talking about that.

I'm talking about the inner workings of reflection, and understanding the client itself by using knowledge of the Java code.

Or maybe I'm misinformed, is possible to use python to interpret runescape source code?

From: HyperSecret
It would probably be just as easy to learn if we have the same type of tutorials for it as we do for using Pascal. I have never written anything in Pascal outside of using it with SCAR.


Probably, and If

Even then, years of experience, gone.

From: HyperSecret
So if we had the tutorials to teach people how to use Python directed towards Runescape autoing, just like we do Pascal here, I would assume people would be able to pick it up just as easily.


Optimistically yes.

From: Ejjman1
Fixed. All these P words are getting you mixed up!

My father works for an IT company, and a couple of his employees work with Python. They compare Java side-by-side with Python, picking Python as the better of the two, he said.


I also think that it looks hard just from looking at samples, but I also thought that Pascal was hard. So I'm with HyperSecret on that.


If your claims that it is 'just as easy' as Pascal Script, I am for the switch.


There is probably no doubt Python>Java

The question is

is it more constructive to understand Python for Runescape purposes than it is Java, and I've yet to see anything convincing in this thread that would suggest so.

From: Smartzkid
A byproduct of having a well-equpped python ide would be an influx of people using it simply for its automation abilities. This is a big plus, because it would provide a larger group of people to draw knowledge and technique from. (and ad revenue)

It is clearly time to move on from pascal, why even write srl 5 in it?



There you jumped from the IDE (simba) supporting it to the SRL 5 core be written in it.

Nava2

2010-04-06 17:50:35

You seem to think that Simba supporting Python, and SRL being written in python can work separately. If we write SRL in python, then SCRIPTS would be in python.

Quite frankly, I think some others are thinking this, but you are being an idiot and belligerent for the sake of being belligerent.

You have stated no positives to Pascal, only that everyone is wrong. We have stated countless times what the positives and negatives are.

Rather than just attempting to castrate every positive point with complete crap counter-points, how about trying to be productive and find new points to support your argument rather than placing face paint onto your old arguments.

Wizzup?

2010-04-06 17:51:36

From: IceFire908
No it really isn't

Not used to it?

Yea just me and a majority of everyone else on this forum. No big deal.


You are confused I believe. I said Python was just as easy to learn. That of course doesn't compare to already knowing one of the two languages. Wouldn't really be a comparison, would it?
I don't see how people will understand Pascal much more than Python. Perhaps except for the few english-language aspects in Pascal.

From: IceFire908

If people know it then they can, but people don't know it.. therefor when they open their SRL folder and try and understand it, they won't be able to with out going out of their way.


My point is, they will understand it the same way as they understand Pascal…?

Not readable to the masses, which is the most important aspect of open source.


See previous.

From: IceFire908

The cons do outweigh the pros. Even if people do learn it, it's years of experience gone.


You think the little experience Pascal Script gives you is years of experience? :(


From: IceFire908

So that more people understand the client. I don't see how you can argue using python is better than understanding the client. But you didn't really say that you just kinda replied with "Yea. Ok" <.<


The point is you think about understanding the client; but that isn't on my mind nor on many others minds.

From: IceFire908

The very reason I have had to restate my views is because they have been interpreted either on purpose or people not reading my posts entirely and somehow seeing this:

"Oh Java >>>>>>>>> Python"

When in fact I'm not saying that at all. Method spelled it out pretty clearly.

Lol, how is understanding the source code of runescape the same as using SMART's reflection?

I'm pretty sure you're right, using WalkToTile in python is just as easy as it is in python, but I'm not even talking about that.

I'm talking about the inner workings of reflection, and understanding the client itself by using knowledge of the Java code.

Or maybe I'm misinformed, is possible to use python to interpret runescape source code?


See above point. And no, AFAIK it is not easy to do reflection for JAVA from python.

From: IceFire908

There is probably no doubt Python>Java

The question is

is it more constructive to understand Python for Runescape purposes than it is Java, and I've yet to see anything convincing in this thread that would suggest so.


I think it would be fair to state that, assuming we don't use Reflection / our ``knowledge'' about the client, and granted that Python > Java, Python would be a better choice?

PS: please stop splitting posts up, it confuses me.:p

@Smartzkid: I also think the change would be too big. Let's first see if we can get the Pascal stuff ready.

Boreas

2010-04-06 18:02:18

From: Wizzup?
I think it would be fair to state that, assuming we don't use Reflection / our ``knowledge'' about the client, and granted that Python > Java, Python would be a better choice?


Also, if we did use it, I believe having scripts and SRL in java would have a negligible effect.

Wanted

2010-04-06 19:25:20

Wizzup, We'll leave it at that.

From: Nava2
You seem to think that Simba supporting Python, and SRL being written in python can work separately. If we write SRL in python, then SCRIPTS would be in python.

Quite frankly, I think some others are thinking this, but you are being an idiot and belligerent for the sake of being belligerent.

You have stated no positives to Pascal, only that everyone is wrong. We have stated countless times what the positives and negatives are.

Rather than just attempting to castrate every positive point with complete crap counter-points, how about trying to be productive and find new points to support your argument rather than placing face paint onto your old arguments.


Tone it down dude.

You're the only one doing the name calling.

If you were expecting for me to respond seriously to this, then address what I said instead of this.

Town

2010-04-06 19:29:51

From: Boreas
Also, if we did use it, I believe having scripts and SRL in java would have a negligible effect.


To expand on this, in being an object-oriented language Python teaches many of the syntactical elements that a scripter in Java would be learning. In making Runescape scripts, the techniques being learned are so focused and repetitive that there is little learning of the language itself. I can't say I know all there is about reflection and interpreting the client, etc, but in my uninformed opinion I would say the benefits in that area are almost equal.

For example, my knowledge of Pascal is directly as a result of learning Scar. I know the syntax. I know basic programming concepts, ie loops, types, etc. I can do some pretty intense stuff with manipulating and identifying colors and shapes, but that's not very common outside of our purposes. My point is that if you can write in Python you can read Java.

The Claw

2010-04-06 22:58:18

From: IceFire908
Wizzup, We'll leave it at that.



Wizzup?

2010-04-07 03:30:40

From: IceFire908
Wizzup, We'll leave it at that.


Was going to suggest the same. :)

Smartzkid

2010-04-08 00:16:06

From: IceFire908
…years of experience gone.


The experience that matters in our situation is the technique we develop, not our knowledge of the simple language we currently script in.

If a person knows how to properly utilize color detection functions to cheat in a specific game, there should be very little problem for this person to pick up another language and cheat just as well.

–

Icefire, I am a little confused by your posts. You seem to be making a couple arguments at once:
  1. We should switch to java
  2. We should support reflection on a higher level
  3. We should not switch from pascal

I agree with number two, and would fully support creating a team of java developers for this purpose. Points one and three, however, don't make much sense to me.

~~~~

Is there any language that SRL could conceivably be coded in which would support both interpretation and compilation to a library? This would allow for SRL to continue to be distributed as source code, but would also allow for it to be compiled to a dll, which could then be wrapped in other languages, as per programmer preference.

Or maybe SRL could be coded in a compiled language, but still distributed as source code, and simply have a compiler built into simba?

I know I'm throwing out some pretty crazy ideas, but maybe there's a more flexible solution here?

Wanted

2010-04-08 00:34:55

From: Smartzkid
The experience that matters in our situation is the technique we develop, not our knowledge of the simple language we currently script in.

If a person knows how to properly utilize color detection functions to cheat in a specific game, there should be very little problem for this person to pick up another language and cheat just as well.

–

Icefire, I am a little confused by your posts. You seem to be making a couple arguments at once:
  1. We should switch to java
  2. We should support reflection on a higher level
  3. We should not switch from pascal

I agree with number two, and would fully support creating a team of java developers for this purpose. Points one and three, however, don't make much sense to me.

~~~~

Is there any language that SRL could conceivably be coded in which would support both interpretation and compilation to a library? This would allow for SRL to continue to be distributed as source code, but would also allow for it to be compiled to a dll, which could then be wrapped in other languages, as per programmer preference.

Or maybe SRL could be coded in a compiled language, but still distributed as source code, and simply have a compiler built into simba?

I know I'm throwing out some pretty crazy ideas, but maybe there's a more flexible solution here?


I never applied "argument one" as it states clearly in about 4 different places on my previous posts.

In a nutshell the point being made here is there is no reason for SRL itself to be involved in Python. Pascal is easy to learn and read(without any prior knowledge) and does virtually every single thing we need it for, plugins have always sufficed well as a last resort. Directing man power to a language other than the current that isn't Java doesn't make a whole lot of sense (from a Runescape point of view i.e. the SRL include) not because I think Java is a better language (because I obviously don't) but because Runescape, is written in Java, and to spend loads of extra time learning another language besides Java just doesn't add up.

What could we ever possibly do with SRL for runescape in python that we couldn't do with what we have now? And at that, what would be worth redoing every single aspect of the current system simply to achieve this yet-to-be-defined notion?

Town

2010-04-08 11:10:23

In my opinion, SRL has always been about learning, practicing correct programming technique, and beating the system. Pascal is not a language that's worth learning if you compare it with these languages that people are being paid to know and use everyday. Once I've forgotten completely about Runescape, Python is something that I'll still be using. Pascal, we'll see.

Dan Cardin

2010-04-08 16:21:16

people are being paid to use python? Doubt?

Wizzup?

2010-04-08 16:40:25

From: IceFire908
I never applied "argument one" as it states clearly in about 4 different places on my previous posts.

In a nutshell the point being made here is there is no reason for SRL itself to be involved in Python. Pascal is easy to learn and read(without any prior knowledge) and does virtually every single thing we need it for, plugins have always sufficed well as a last resort. Directing man power to a language other than the current that isn't Java doesn't make a whole lot of sense (from a Runescape point of view i.e. the SRL include) not because I think Java is a better language (because I obviously don't) but because Runescape, is written in Java, and to spend loads of extra time learning another language besides Java just doesn't add up.

What could we ever possibly do with SRL for runescape in python that we couldn't do with what we have now? And at that, what would be worth redoing every single aspect of the current system simply to achieve this yet-to-be-defined notion?


How many times have we stated that Python is simply more readable that Pascal? Stop saying Pascal is easy to learn and read, thus implying Python isn't. I suggest you spent at least 30 minutes in the documentation…! :)

c0de

2010-04-08 16:44:10

Dear Wizzup, I believe that focus should be on this part of post:

From: IceFire908

What could we ever possibly do with SRL for runescape in python that we couldn't do with what we have now? And at that, what would be worth redoing every single aspect of the current system simply to achieve this yet-to-be-defined notion?

Wizzup?

2010-04-08 16:47:48

From: c0de
Dear Wizzup, I believe that focus should be on this part of post:


The question is not if it is possible to achieve, but how easy it is to achieve. We could essentially just write a brainfuck/(other joke language) interpreter and do everything in BF, but that wouldn't be very productive, would it?

Town

2010-04-08 17:29:20

From: Dan Cardin
people are being paid to use python? Doubt?


http://en.wikipedia.org/wiki/List_of_Python_software

http://www.python.org/about/success/

http://wiki.python.org/moin/OrganizationsUsingPython

Maybe you didn't catch what I was talking about. I doubt you can find a comparable list of companies that hire people to develop in Pascal from post 2000.

Wanted

2010-04-08 18:23:40

From: Wizzup?
How many times have we stated that Python is simply more readable that Pascal? Stop saying Pascal is easy to learn and read, thus implying Python isn't. I suggest you spent at least 30 minutes in the documentation…! :)


How can I imply something opposite when I directly use the (er) and the end of every word?

Python may be easy to read, but Python is not easier to read than pascal, especially when more people around SRL already at least know some bit of it.

From: Wizzup?
The question is not if it is possible to achieve, but how easy it is to achieve. We could essentially just write a brainfuck/(other joke language) interpreter and do everything in BF, but that wouldn't be very productive, would it?


I don't understand, I thought it was all about being allpowerful and now it's about how easy it is.

We don't even know what it is.

Dan Cardin

2010-04-08 21:56:26

From: Town
http://en.wikipedia.org/wiki/List_of_Python_software

http://www.python.org/about/success/

http://wiki.python.org/moin/OrganizationsUsingPython

Maybe you didn't catch what I was talking about. I doubt you can find a comparable list of companies that hire people to develop in Pascal from post 2000.


Glancing through it, i didnt see any where python was the actual thing that was mainly being used. It was always used as an extension for other things. I doubt pascal is used. Then again, delphi is object pascal and delphi is certainly used for things.

c0de

2010-04-08 22:24:41

From: IceFire908
We don't even know what it is.


Amen.

Wizzup?

2010-04-09 05:36:34

From: IceFire908
How can I imply something opposite when I directly use the (er) and the end of every word?

Python may be easy to read, but Python is not easier to read than pascal, especially when more people around SRL already at least know some bit of it.


I don't see how a language becomes more readable when more people know it. In that sense, C is probably the most readable language on earth.

From: IceFire908

I don't understand, I thought it was all about being allpowerful and now it's about how easy it is.


I seriously frowned here… You're taking this horribly out of context. I simply gave a valid counter-argument to what you previously stated: How it is much easier to develop with Python, rather than with Pascal. And suddenly I am saying it not a powerful language?

From: IceFire908

We don't even know what it is.


A lot of people do know what is it, because they simply took the time to investigate! (Look at Nava, Coh3n, etc)
All you're doing it claiming how it's not going because people will have to put some effort in learning something new, whilst not even having taken a **** look at what we are talking about.

There's a word for that you know… Ignorant. :)

From: Dan Cardin
Glancing through it, i didnt see any where python was the actual thing that was mainly being used. It was always used as an extension for other things. I doubt pascal is used. Then again, delphi is object pascal and delphi is certainly used for things.


Hm… I'm pretty sure Python is used a lot more than Delphi… ;)

Dan Cardin

2010-04-09 06:41:50

I'm not saying its not because i really don't know, but its not as if its a dead language. I personally like python, but i don't if it would be good SRL, which is why i agreed (previously) with releasing it slowly, like you're currently doing with Simba, before deciding on anything. Especially since i think that many people liking this idea because of the same reasons as Simba when it was first announced. They were told by the upper class that it was a good thing, so they believe it is. Well, if its actually a good thing, they should be able to use it and determine that themselves rather than being biased by people that they think know what they're talking about.

Town

2010-04-09 10:17:27

I found a better example with this: http://www.python.org/community/jobs/

And I can't say whether or not this is a decent site, but there is a clear difference in numbers. Comparison:

http://www.indeed.com/jobs?q=Python+Programmer&l=
http://www.indeed.com/q-Delphi-Programmer-jobs.html

This can also be expected:

http://www.indeed.com/jobs?q=Java+Programmer&l=

Wanted

2010-04-09 10:39:42

From: Wizzup?
I don't see how a language becomes more readable when more people know it. In that sense, C is probably the most readable language on earth.


Why would it matter what is most readable in the whole world when we only worry about the current and potential people who actually might even know of/heard of SRL.

From: Wizzup?
I seriously frowned here… You're taking this horribly out of context. I simply gave a valid counter-argument to what you previously stated: How it is much easier to develop with Python, rather than with Pascal. And suddenly I am saying it not a powerful language?



A lot of people do know what is it, because they simply took the time to investigate! (Look at Nava, Coh3n, etc)
All you're doing it claiming how it's not going because people will have to put some effort in learning something new, whilst not even having taken a **** look at what we are talking about.

There's a word for that you know… Ignorant. :)


Well you evaded my question by answering with "we could do it easier" and yo continue to drift away from the question by discussing what Nava/Coh3n have said ect.. even though everything they've said in this thread in no way shape or form answers my question.

I spent a few hours looking through over half of both Python 2 and 3 manuals just to see if there was anything that jumped at me as

"OMFG REWRITE SRL NOW!"

Which is probably a lot more than at least a good percentage of people on this thread can say.

Why do you have to counter aruge, can you not answer a simple question?

What could we ever possibly do with SRL for runescape in python that we couldn't do with what we have now? And at that, what would be worth redoing every single aspect of the current system simply to achieve this yet-to-be-defined notion?

mastaraymond

2010-04-09 13:08:15

I like this discussions.. We all agreed on the fact that SRL 5 isn't going to be for Python and yet we remain discussing why SRL should or shouldn't be written in Python..

Honestly stop this madness and get to work.

Wizzup?

2010-04-09 15:36:33

From: IceFire908
Why would it matter what is most readable in the whole world when we only worry about the current and potential people who actually might even know of/heard of SRL.


That isn't quite what you said… You said Python was less readable than Pascal.

From: IceFire908

Well you evaded my question by answering with "we could do it easier" and yo continue to drift away from the question by discussing what Nava/Coh3n have said ect.. even though everything they've said in this thread in no way shape or form answers my question.


(Read later part of the post)


From: IceFire908

I spent a few hours looking through over half of both Python 2 and 3 manuals just to see if there was anything that jumped at me as

"OMFG REWRITE SRL NOW!"

Which is probably a lot more than at least a good percentage of people on this thread can say.


What makes python less readable than Pascal in that case?

From: IceFire908

Why do you have to counter aruge, can you not answer a simple question?


A counter argument usually is an answer, and I think answered the question… But I guess you need examples?

From: IceFire908

What could we ever possibly do with SRL for runescape in python that we couldn't do with what we have now? And at that, what would be worth redoing every single aspect of the current system simply to achieve this yet-to-be-defined notion?


What about the fact that PascalScript simply isn't extendable? Techically it is, but as I stated previously it is a hell to do, and simply stupid. Since Python offers a VERY rich std. library (probably just as rich as java) you can do a lot more in it than you could ever dream of doing in PascalScript. You want to work with SQL for your own script stats? import sqlite3. You want to run a small webserver which supplies you of live script stats? import SimpleHTTPServer. You want to mail yourself? import email. You want to do some bad ass image manipulation? import PIL. You want to compress / decompress? import gzip. You want to do use any external dll? import ctypes.
I probably could go on for quite awhile. Note that I am only pointing out the functionality difference. With Python we can also make SRL modular, OOP, etc.

You want to give your script a soul? import soul.

c0de

2010-04-09 16:51:52

From: Wizzup?
You want to work with SQL for your own script stats? import sqlite3. You want to run a small webserver which supplies you of live script stats? import SimpleHTTPServer. You want to mail yourself? import email. You want to do some bad ass image manipulation? import PIL. You want to compress / decompress? import gzip. You want to do use any external dll? import ctypes.
I probably could go on for quite awhile. Note that I am only pointing out the functionality difference. With Python we can also make SRL modular, OOP, etc.


Fuck yeah, let's mine essence using SimpleHTTPServer. Do quests using sqlite and bank using gzip!

mastaraymond

2010-04-09 17:27:37

From: c0de
Fuck yeah, let's mine essence using SimpleHTTPServer. Do quests using sqlite and bank using gzip!

Make your script stream porn while autoing? Seems like win for me :)

c0de

2010-04-09 17:37:05

From: mastaraymond
Make your script stream porn while autoing? Seems like win for me :)


No it's EPIC WIN :D

Wanted

2010-04-09 17:38:15

From: Wizzup?
That isn't quite what you said… You said Python was less readable than Pascal.



(Read later part of the post)




What makes python less readable than Pascal in that case?



A counter argument usually is an answer, and I think answered the question… But I guess you need examples?



What about the fact that PascalScript simply isn't extendable? Techically it is, but as I stated previously it is a hell to do, and simply stupid. Since Python offers a VERY rich std. library (probably just as rich as java) you can do a lot more in it than you could ever dream of doing in PascalScript. You want to work with SQL for your own script stats? import sqlite3. You want to run a small webserver which supplies you of live script stats? import SimpleHTTPServer. You want to mail yourself? import email. You want to do some bad ass image manipulation? import PIL. You want to compress / decompress? import gzip. You want to do use any external dll? import ctypes.
I probably could go on for quite awhile. Note that I am only pointing out the functionality difference. With Python we can also make SRL modular, OOP, etc.

You want to give your script a soul? import soul.


You didn't answer the question, you just said "it" was easier to do stuff in python, even though it's not. You didn't say what or how "it" was. And python isn't more readable than pascal, I don't know how you can say that is so… maybe because you're fluent in multiple programming languages already and can't really put yourself in the shoes of someone say whos never seen a drop of source code in his life.

Now you're listing a bunch of random stuff, is pretty useless to change everything from the ground up just so you can use things that are pretty random like gizp and image manipulation… all of which are obviously not widely used, not used at all in fact, or have anything that I would find directly useful for practical reasons like making a color bot in runescape.. anyways… could be imported… exactly.. plugins are amazing things. Besides, wouldn't some of that stuff be server side anyways? -.-

At best, the end product is going to be pretty much the same.

It's just gonna boil down to how well a script/include is made, not what language it was written in.

Wizzup?

2010-04-09 18:41:52

From: c0de
Fuck yeah, let's mine essence using SimpleHTTPServer. Do quests using sqlite and bank using gzip!


SQLite can indeed be very useful at times. Gzip has already proven to be useful when making custom installers for Simba.

From: IceFire908
You didn't answer the question, you just said "it" was easier to do stuff in python, even though it's not. You didn't say what or how "it" was. And python isn't more readable than pascal, I don't know how you can say that is so… maybe because you're fluent in multiple programming languages already and can't really put yourself in the shoes of someone say whos never seen a drop of source code in his life.


I can put myself in the shoes of someone who has never seen a drop of source code in his life.

Let's assume the common situation where we want to see if an array contains a specific element.

How would we do this in pascal?


var
i, myownnum: integer;
arr: array of integer;
found: boolean;

myownnum := 42;
for i := 0 to high(arr) do
if arr[i] = myownnum then
begin
found := true;
break;
end;
if found then
writeln('myownnum in array');

and in Python?


myownnum = 42
if arr in myarr:
print 'myownnum in array';

Now, you tell me what is more readable.
Examining the pascal example first:
Let's assume we don't even know what an array is. Ok, what does 'var' mean? Probably means variable… whatever that may mean. What is a boolean? Next, myownnum is assigned to a number, 42. Then, we are doing something with 'for'? And what is high? What does that even mean? What does break do? What is writeln?
<Reader stops here most likely>

Python:
Seeing 'in' is also an english word, the code seems rather readable, even is we assume the reader has no idea as to what an array is.

From: IceFire908
Now you're listing a bunch of random stuff, is pretty useless to change everything from the ground up just so you can use things that are pretty random like gizp and image manipulation… all of which are obviously not widely used, not used at all in fact, or have anything that I would find directly useful for practical reasons like making a color bot in runescape.. anyways… could be imported… exactly.. plugins are amazing things. Besides, wouldn't some of that stuff be server side anyways? -.-


Yes, I am listing some ``random'' stuff, but they could easily be used. The point is that getting ANY of these components in Simba w/ PascalScript will cost days, if not more. And since the users of SCAR seem to thrive on useless stuff, it should be taken into consideration. And I guess that if you are saying ``obviously not widely used'', you are restricting yourself again to SRL only? (because most are used A LOT)
What I don't understand is that you state that something is bad because it currently isn't used often. That doesn't really tell me anything about it's worth/value. Perhaps it isn't used often because it's annoying to write wrappers/plugins for it? You can't say something would be a bad addition just because it isn't currently being used.

Image manipulation is not useful? Oh, I forgot you only use reflection to find colours/bitmaps on RuneScape?

No, plugins aren't amazing, at all!
I really don't understand what you are trying to defend… You really have no clue what a pain plugins(.dll/.so) are, and how annoying they are as well w/ Pascalscript.

If you want your server to manage it's own stats local because you don't want to share them, or want to keep it private, then your script would have to run it's own server.

From: IceFire908

At best, the end product is going to be pretty much the same.

It's just gonna boil down to how well a script/include is made, not what language it was written in.


The end product will only be the same in the sense that there aren't any current new technologies for Colour/Bitmap finding. Everything else will improve in both maintainability and usability.

Wanted

2010-04-09 19:37:58

From: Wizzup?
SQLite can indeed be very useful at times. Gzip has already proven to be useful when making custom installers for Simba.


At times? Lol… try never. Because I'm totally gonna need a custom installer to chop my trees and use gametabs.



From: Wizzup?
I can put myself in the shoes of someone who has never seen a drop of source code in his life.

Let's assume the common situation where we want to see if an array contains a specific element.

How would we do this in pascal?


var
i, myownnum: integer;
arr: array of integer;
found: boolean;

myownnum := 42;
for i := 0 to high(arr) do
if arr[i] = myownnum then
begin
found := true;
break;
end;
if found then
writeln('myownnum in array');

and in Python?


myownnum = 42
if arr in myarr:
print 'myownnum in array';

Now, you tell me what is more readable.
Examining the pascal example first:
Let's assume we don't even know what an array is. Ok, what does 'var' mean? Probably means variable… whatever that may mean. What is a boolean? Next, myownnum is assigned to a number, 42. Then, we are doing something with 'for'? And what is high? What does that even mean? What does break do? What is writeln?
<Reader stops here most likely>

Python:
Seeing 'in' is also an english word, the code seems rather readable, even is we assume the reader has no idea as to what an array is.


Ok honestly that the most horrible example I could possibly think of

It's like saying oh they will be able to read these two lines better:

for I := 0 to 5 do S := S + 'hi.';
WriteLn(S);

vs

S = "hi."
print S*5

The fact of the matter is is that if you open something written in python and you have never seen python before or understand it your first impression is wtf? Overwhelmed by all the different structures, data types, implementations ect. ect. Python is an actual programming language after all <.<

import_stmt     ::=  "import" module ["as" name] ( "," module ["as" name] )*
| "from" relative_module "import" identifier ["as" name]
( "," identifier ["as" name] )*
| "from" relative_module "import" "(" identifier ["as" name]
( "," identifier ["as" name] )* [","] ")"
| "from" module "import" "*"
module ::= (identifier ".")* identifier
relative_module ::= "."* module | "."+
name ::= identifier

I had to read this entire article http://docs.python.org/reference/simple_stmts.html#the-break-statement just to understand that.

Imagine someone on MSN asking you how to do that, opposed to normal downto EARTH pascal were you might be able to explain in less than a minute.

And in the above example I completely don't understand why you wouldn't use function InIntArr(Int, Arr): Boolean;

-.-


From: Wizzup?
Yes, I am listing some ``random'' stuff, but they could easily be used. The point is that getting ANY of these components in Simba w/ PascalScript will cost days, if not more. And since the users of SCAR seem to thrive on useless stuff, it should be taken into consideration. And I guess that if you are saying ``obviously not widely used'', you are restricting yourself again to SRL only? (because most are used A LOT)
What I don't understand is that you state that something is bad because it currently isn't used often. That doesn't really tell me anything about it's worth/value. Perhaps it isn't used often because it's annoying to write wrappers/plugins for it? You can't say something would be a bad addition just because it isn't currently being used.


Easily used for WHAT? WHERE? HOW? Yea they will probably cost you a day or two to get something in rare situation to work for some unique purpose. But it will takes weeks, months, years to switch a community away from this and by that time my bet is you won't even be fond of python anyone because you tend to move around from language to language pretty frequently.

I ask you a question and you counter with something like "thats closed minded" "SCAR users thrive on useless stuff" when all you can tell me is about all the random great things it can do… not of which has any good use for our intended purposes. They are not widely used here for a reason.


From: Wizzup?
Image manipulation is not useful? Oh, I forgot you only use reflection to find colours/bitmaps on RuneScape?


Right I only use reflection because it totally hasn't been broken almost the entire time during my periods of activity. It worked for a week 3 years ago and for a month when I came back in June. And I totally didn't write the only script to runecraft through the Abyssal space entirely IN COLOR with the addition of 3 different land runes, completely in 100% COLOR. Clearly I only use reflection, and somehow found a way to use reflection to find bitmaps… lol??


From: Wizzup?
No, plugins aren't amazing, at all!
I really don't understand what you are trying to defend… You really have no clue what a pain plugins(.dll/.so) are, and how annoying they are as well w/ Pascalscript.


Obviously I have not a clue in the world, I had 1 limitation ever, writing the hardest script I ever faced and it was that it was to slow in the interpreter to find colors along a line for all 360 degrees so I wrote a plugin in a really short amount of time without much work at all and utilized it without any excess problems… or was that something SCAR is only capable as of now? Yea I agree plugins in simba are a MESS. <.< Plugins seem to be pretty amazing, take SMART for example. Just because it's not something some major corporation is ready to endorse it makes it not amazing, apparently.


From: Wizzup?
If you want your server to manage it's own stats local because you don't want to share them, or want to keep it private, then your script would have to run it's own server.


What? That's all server side anyways… it doesn't make sense to have that any other way.




From: Wizzup?
The end product will only be the same in the sense that there aren't any current new technologies for Colour/Bitmap finding. Everything else will improve in both maintainability and usability.


You've yet to explain how.

mixster

2010-04-09 20:59:00

I request a restart with better organised arguments as both sides are getting sloppy now and you two keep picking at things and blowing them out of proportion.

Firstly IceFire, I just want to establish something and that is your position. Is it that we should stick with PascalScript or that if we are going to change to another language, it should be Java?

If stick with PascalScript, then I have several key things in my opinion.

First of all, Python is a real language - PascalScript is not. It has development going into it from large amounts of proper programmers. It has a huge standard library to do anything any scripter would possibly ever want to do in mere seconds of searching for what to import. It's easy to install (and usually already installed) across both Linux distros and Windows (unsure about Mac, but I would like to think very much so).

It isn't restricted to one program to develop for as some big IDE's like Netbeans can work with it (usually after adding a plugin I admit). Also, people can learn a full language, rather than PascalScript as a limited version of Pascal - let's face it, a minority of scripters actually make plugins and even fewer of them do it for reasons other than speed. I would also like to say not everyone is amazing as BenLand and using him as any kind of example of how PS has no limits is silly.

On a furthering point, it has incredible readability - definitely better than Pascal does. The forced indenting also leads to so many less begin/end problems. The use of some C'ish operators isn't hard to understand and it is such a nice thing to have: *=, +=, -=, etc and being able to use ** for powers is a lot nicer for both reading and coding.

You also pasted extremely uncommon code right there as your example of how `Python isn't readable'. I would also like to say that generally if you read Python code out loud (and it isn't some peculiar piece of random code), it actually makes sense - s = 'meow' then s*5 => add 'meow' 5 together times to get 'meowmeowmeowmeowmeow' (not to mention the examples aren't the same as the former writes `hi'. 6 times on separate lines, where as the Python simply prints the one line, but only 5 lots of 'hi.' joined together)!

Anyway, if your argument is Java rather than Python if we were to change, then I shall post my beliefs on that.

Dan Cardin

2010-04-09 21:14:57

python doesnt have proper multiline comments and you need to call something global to use it in a function. I dislike those. In case anyone was wondering. (but i very much like the rest…in case anyone else was wondering.) On a side note, i dislike that pygame's method for displaying things to the screen is pygame.display.flip - this is also kind of annoying, but not directly related to python. On a brighter note, the for loops in python are really cool. And on a final note, almost every time i type out python i accidentally write pythong for some reason. I'm not sure whether that's a downside or not.

In general though, i would say python may be more readable in terms of synacticalness. I would also mention that i recently started python with basically just a general notion of how the syntax worked and was able to get a pretty nice game going (something that i had been procrastinating about doing for a while in pascal.) in under 200 lines. It is also nice that when you look at other people's code when learning, everyone has to do the same code basically (minus blank lines) to do things, so reading code from one person to another is basically the same. It also might be mentioned that you dont really neeed to learn many of the nuances of python for many things (minus cases). I haven't *needed* dicts and lambdas but they both seem to be helpful rather than confusing.

Wanted

2010-04-09 21:23:13

From: mixster
I request a restart with better organised arguments as both sides are getting sloppy now and you two keep picking at things and blowing them out of proportion.

Firstly IceFire, I just want to establish something and that is your position. Is it that we should stick with PascalScript or that if we are going to change to another language, it should be Java?


Sorry if I sound rude here, this question has already been answered 6 times.

From your first and second paragraphs. I already picked up that you TL;DR'd this topic.

I'll restate myself.

We should not switch languages.

If other languages were to even be considered to be perseud by SRL it should be Java, the native language of runescape and not python.

As clearly stated, by myself, many times in this thread alone.

There that is 7 times now.


From: mixster


If stick with PascalScript, then I have several key things in my opinion.

First of all, Python is a real language - PascalScript is not. It has development going into it from large amounts of proper programmers. It has a huge standard library to do anything any scripter would possibly ever want to do in mere seconds of searching for what to import. It's easy to install (and usually already installed) across both Linux distros and Windows (unsure about Mac, but I would like to think very much so).


Obviously, no one has disputed that claim, other than it does not do anything any scripter would possibly ever want to do in runescape, we already have that.

From: mixster


It isn't restricted to one program to develop for as some big IDE's like Netbeans can work with it (usually after adding a plugin I admit). Also, people can learn a full language, rather than PascalScript as a limited version of Pascal - let's face it, a minority of scripters actually make plugins and even fewer of them do it for reasons other than speed. I would also like to say not everyone is amazing as BenLand and using him as any kind of example of how PS has no limits is silly.


Cool story bro, I don't use Netbeans though sorry.

If you think that, then you understand an even smaller minority of scripters will find using python to be any more useful then what they use now as they have almost never had the need to go as far as importing something via plugin. Lol not as amazing as BenLand, on that note not everyone is amazing/has the time to even pick up python if they really wanted to.. so yea?


From: mixster

On a furthering point, it has incredible readability - definitely better than Pascal does. The forced indenting also leads to so many less begin/end problems. The use of some C'ish operators isn't hard to understand and it is such a nice thing to have: *=, +=, -=, etc and being able to use ** for powers is a lot nicer for both reading and coding.

You also pasted extremely uncommon code right there as your example of how `Python isn't readable'. I would also like to say that generally if you read Python code out loud (and it isn't some peculiar piece of random code), it actually makes sense - s = 'meow' then s*5 => add 'meow' 5 together times to get 'meowmeowmeowmeowmeow' (not to mention the examples aren't the same as the former writes `hi'. 6 times on separate lines, where as the Python simply prints the one line, but only 5 lots of 'hi.' joined together)!


Cool another "it's defiantly more readable" no example, no good explanation, no anything other than biased opinion.

"How Python isn't readable" Cool that's the 3rd time someone said I meant that when I did not.

I clearly said that Python is not as easy to read as pascal, and it is… you've yet to dispute that correctly other than some ridiculous meow-mix-code-song. Read python out loud to yourself, you'll sound just as much like a nerd either way… is this a real point or are you just rambling?

Funny how he compared the source for InIntArr to python instead of InIntArr to python :<

From: mixster
Anyway, if your argument is Java rather than Python if we were to change, then I shall post my beliefs on that.


TL;DR?

Long story short, read the thread before you post.

Kthxbai

c0de

2010-04-09 22:18:47

Which leaves me with only one thing to say:


Nava2

2010-04-10 01:22:55

*sigh* I think this is useless to continue with the current audience.

senrath

2010-04-10 01:37:16

From: IceFire908

import_stmt     ::=  "import" module ["as" name] ( "," module ["as" name] )*
| "from" relative_module "import" identifier ["as" name]
( "," identifier ["as" name] )*
| "from" relative_module "import" "(" identifier ["as" name]
( "," identifier ["as" name] )* [","] ")"
| "from" module "import" "*"
module ::= (identifier ".")* identifier
relative_module ::= "."* module | "."+
name ::= identifier

I had to read this entire article http://docs.python.org/reference/simple_stmts.html#the-break-statement just to understand that.

Imagine someone on MSN asking you how to do that, opposed to normal downto EARTH pascal were you might be able to explain in less than a minute.

And in the above example I completely don't understand why you wouldn't use function InIntArr(Int, Arr): Boolean;


I'm kinda confused as to why you would ever need to understand that part. Seriously, the only time you ever would need to even touch that stuff is if you wanted to redefine what everything does. Like if you wanted to make the word "potato" execute the same way that "break" does currently.

And I'd rather use the same syntax for all array checking (if 12 in arr, if 's' in arr, if 21.8 in arr, etc) instead of having to use multiple things, like InStrArr, InIntArr, etc. As well as being able to use this:

for x in arr:
something(x);
instead of having to use this:

for x := 0 to High(arr) do
something(arr[x]);

Wanted

2010-04-10 01:41:47

From: senrath
I'm kinda confused as to why you would ever need to understand that part. Seriously, the only time you ever would need to even touch that stuff is if you wanted to redefine what everything does. Like if you wanted to make the word "potato" execute the same way that "break" does currently.

And I'd rather use the same syntax for all array checking (if 12 in arr, if 's' in arr, if 21.8 in arr, etc) instead of having to use multiple things, like InStrArr, InIntArr, etc. As well as being able to use this:

for x in arr:
something(x);
instead of having to use this:

for x := 0 to High(arr) do
something(arr[x]);


1)http://docs.python.org/reference/simple_stmts.html#the-break-statement

2)InIntArrEx(X, Arr, ) is better… again personal preference. I missed your point.

senrath

2010-04-10 01:44:29

Um, that's just repeating what I responded to. Care to elaborate on how that refutes anything that I said?

Edit: Yes, it's largely personal preference, but how is having separate constructs for each separate type of array better than having a single standardized one?

Wanted

2010-04-10 01:46:46

From: senrath
Um, that's just repeating what I responded to. Care to elaborate on how that refutes anything that I said?

Edit: Yes, it's largely personal preference, but how is having separate constructs for each separate type of array better than having a single standardized one?


So you're saying

Python is easier to read than Pascal because you can use in for arrays? Because that was the entire context of the original quote, unless you're trying to make some other point here.

senrath

2010-04-10 01:53:39

The biggest point I was trying to make is you were giving this:
import_stmt     ::=  "import" module &#91;"as" name] ( "," module ["as" name] )*
| "from" relative_module "import" identifier &#91;"as" name]
( "," identifier &#91;"as" name] )*
| "from" relative_module "import" "(" identifier &#91;"as" name]
( "," identifier &#91;"as" name] )* [","] ")"
| "from" module "import" "*"
module ::= (identifier ".")* identifier
relative_module ::= "."* module | "."+
name ::= identifier
as something that would be much harder to explain in a few minutes in Python than in PascalScript. I'm not convinced. Explain to me how you would even do that in PascalScript. Explain to me, in less than a minute, how you would, within PascalScript, define the syntax (!gimme <something>) as the same as {.include <something>). Or how to define the word "maroon" as "break".

Wanted

2010-04-10 01:57:48

That's exactly the point, you would never run into crap like this in PascalScript and be wtfconfused for an hour let alone understand it.

senrath

2010-04-10 02:00:06

And my point is that you don't need to understand it. It's a completely optional feature. And it's something that PascalScript can't even do.

Wanted

2010-04-10 02:04:31

From: senrath
And my point is that you don't need to understand it. It's a completely optional feature. And it's something that PascalScript can't even do.


Moral of the story

senrath

2010-04-10 02:05:27

The moral of the story is that you were complaining about something that didn't need to be complained about? Because I'm not seeing anything else in there.

Wanted

2010-04-10 02:07:48

From: senrath
The moral of the story is that you were complaining about something that didn't need to be complained about? Because I'm not seeing anything else in there.


It's 1 AM and I've had a long day, don't have any more time to spell things out.

So I'm just gonna log off and hope everything goes well while I sleep. Because this thread is going absolutely nowhere.

senrath

2010-04-10 02:10:19

Of course. Because from what I've seen you've decided that you're not going to accept what anyone else says on the subject. And I don't think the pro-python side is doing much better.

I was just trying to say that that particular, small part of your argument wasn't holding much water (ignoring the greater part of your argument because, honestly, I can't think of any reason why switching to Python would bring about anything more than minor benefits), and you came back saying "Eh, that's not how I've been doing it, and I really like how I've been doing it, so it must be wrong and confusing."

Wanted

2010-04-10 02:13:43

From: senrath
Of course. Because from what I've seen you've decided that you're not going to accept what anyone else says on the subject. And I don't think the pro-python side is doing much better.

I was just trying to say that that particular, small part of your argument wasn't holding much water (ignoring the greater part of your argument because, honestly, I can't think of any reason why switching to Python would bring about anything more than minor benefits), and you came back saying "Eh, that's not how I've been doing it, and I really like how I've been doing it, so it must be wrong and confusing."


Because it's totally cool for me to type pages of responses, only to have someone come in and quote 1% of the things I said and be completely technical and miss the entire context purpose of the intended meaning, in an attempt to derail any progress made.

senrath

2010-04-10 02:17:18

How is it derailing when I'm attempting to refute one of your points? Just because I'm not refuting every single thing you said does not make my points any less valid.

Look, you might not have intended it to sound this way, but pretty much all of your responses have ended up sounding like "Waaah, I don't like change. New things scare me. Make the bad Python go away."

Wanted

2010-04-10 02:20:23

(Source1)
From: senrath
Look, you might not have intended it to sound this way, but pretty much all of your responses have ended up sounding like "Waaah, I don't like change. New things scare me. Make the bad Python go away."


From: senrath
How is it derailing when I'm attempting to refute one of your points? Just because I'm not refuting every single thing you said does not make my points any less valid.


See source 1

Yea I'm not going to reply to this.

senrath

2010-04-10 02:24:09

Okay, that one was a bit of a derail. But my point still stands about my previous comments not being a derail. Also, you just did reply to it.

I'm done here. I can't add anything else productive, and I'd just end up saying something else stupid. There's obviously nothing that anyone can do that will make IceFire change his mind on the subject.

mixster

2010-04-10 12:01:47

From: IceFire908
Sorry if I sound rude here, this question has already been answered 6 times.

From your first and second paragraphs. I already picked up that you TL;DR'd this topic.

I'll restate myself.

We should not switch languages.

If other languages were to even be considered to be perseud by SRL it should be Java, the native language of runescape and not python.

As clearly stated, by myself, many times in this thread alone.

There that is 7 times now.


I've actually read every post in this topic (so far remained quiet because, well, I don't always enjoy having pointless arguments with people who I know won't change their position regardless of what evidence or the like I put forward) and your position always seems to be which ever one suits best to the latest post. I was hoping to clarify it as one or the other so I could make sure any posts I made were precisely to the point, but I guess I'll have to target 2 things at once. I thought that as I made several completely new points that so far haven't really been discussed (and you haven't actually refuted them - you just keep saying `it doesn't help with runescape', even though not everyone here actually is here to macro on runescape and you haven't said why it doesn't help).

First of all then, Java is a stupid language for macroing. It restricts you to running the big chunky JVM when you want to do anything. It just about restricts you to only macroing on Java applets unless you want to add a load of wrapper stuff for allowing it also to use the robot class too (not even sure how well that works).

Java is also a very different language that would take a lot longer for the majority of people to learn compared to Python. If you think it would be worth it in the long run to learn Java, then it would also be just as worth it to learn Python. The main reasoning being Java is forced OOP, something which would take a lot of getting used to and it shares C syntax which greatly differers from Pascal syntax - Python still has elements of English to it like Pascal with a hint of C syntax for operators, which I quite like.

With every ounce of my reasoning behind me, I can only see Java as a good move if SRL were to only auto RS and use a client like Smart (similar to RSBot and co). But not everyone uses Scar/Simba and SRL to auto RS nor does everyone use (or like using) Smart, but I guess those people aren't really needed in this community.


In regards to Python's readability, so far you haven't actually given any decent proof that PascalScript is more readable than Python.
What do you want us to give you? Should I make a `fairly large' script in both PascalScript and in Python then compare which one is more readable? Ok, let's do it!

Scar sauce code

Lazily converted code by me in an hour

I'm not actually that familiar with Python - this is pretty much done with syntax knowledge, outline knowledge for classes and a few documentation pages (1, 2, 3, 4). I also know it's not exactly the same content, but for me it produces the same end results - it collects the SRL SVN, downloads all the files to where I tell it and finds any plugins and moves those to where I tell it. If you change the directories to yours, it should work on Windows too (may need to change line 71 from '/' to '\\' though).

I also know it's quite ugly code, but that's what you get when you convert code pretty much line by line and if I made it in Python from the start it would be a lot more elegant. However, I still see nothing there that's hard to explain, so I've decided to pick out the `hardest' to understand bits and convert them either into Pascal'y stuff or English if that's easier.

class TFile(object):
def __init__(self, path, name):
self.path = path
self.name = name

Which is the equivalent of:
type
TFile = record
path, name: string;
end;

function CreateTFile(path, name: string): TFile;
begin
Result.path := path;
Result.name := name;
end;

That same example can be used for all the other classes I've used to emulate records.

return inp[s:e]
Result := Copy(inp, s, e - s);
or, in English, return everything between (and including) the index s and e from string inp.

There are a couple of intimidating lines like
TSVNFile(TFile(curdir.local.path + tmploc + '/', ''), TFile(curdir.remote.path + tmprem, ''))
But by calling TSVNFile or the like, it's basically calling the `CreateTSVNFile' I mentioned earlier with the class equivalent code.

def ensure_dir(f):
d = os.path.dirname(f)
if not os.path.exists(d):
os.makedirs(d)

Scar doesn't have an equivalent - it just usually lets you create the directory, but sometimes doesn't. Simba does have a function equivalent, but it pretty much does the same as this except returns true or false as to whether or not it was able to.

Erm, yeah. I think that's all the code that would be completely alien to a typical scripter. Some of it may be strange, but I think it's just about readable even if you don't know Python. If there is anything there that you aren't sure about, do give me a shout and I'll give you its Scar equivalent.

Nava2

2010-04-10 13:06:58

I'd like to point out, the SCAR code is twice as long as the python code, and less elegant.

That is all.

Wizzup?

2010-04-10 13:37:06

From: IceFire908
At times? Lol… try never. Because I'm totally gonna need a custom installer to chop my trees and use gametabs.


Very useful indeed. Just because you don't think out of the box doesn't mean other won't. :)

From: IceFire908

Ok honestly that the most horrible example I could possibly think of

It's like saying oh they will be able to read these two lines better:

for I := 0 to 5 do S := S + 'hi.';
WriteLn(S);

vs

S = "hi."
print S*5


Horrible??? Wat. This is very common code, and it applies to a lot of cases.

From: IceFire908
The fact of the matter is is that if you open something written in python and you have never seen python before or understand it your first impression is wtf? Overwhelmed by all the different structures, data types, implementations ect. ect. Python is an actual programming language after all <.<


I don't see the disadvantage to this? When I first read Pascal I was like "wtf?" too.

From: IceFire908

import_stmt     ::=  "import" module ["as" name] ( "," module ["as" name] )*
| "from" relative_module "import" identifier ["as" name]
( "," identifier ["as" name] )*
| "from" relative_module "import" "(" identifier ["as" name]
( "," identifier ["as" name] )* [","] ")"
| "from" module "import" "*"
module ::= (identifier ".")* identifier
relative_module ::= "."* module | "."+
name ::= identifier

I had to read this entire article http://docs.python.org/reference/simple_stmts.html#the-break-statement just to understand that.


Hahahahaaaa… You made me laugh out loud… :D
You do know that this is not actual syntax, right?

From: IceFire908

And in the above example I completely don't understand why you wouldn't use function InIntArr(Int, Arr): Boolean;

-.-


Replace Int with any other type…? Unless you want to create something for every type? Damn…

From: IceFire908

Easily used for WHAT? WHERE? HOW? Yea they will probably cost you a day or two to get something in rare situation to work for some unique purpose. But it will takes weeks, months, years to switch a community away from this and by that time my bet is you won't even be fond of python anyone because you tend to move around from language to language pretty frequently.


To the first point, I really don't have much to say. I'm stumbled by this comment…

Moving from languages? Get your facts straight, bro…

From: IceFire908
I ask you a question and you counter with something like "thats closed minded" "SCAR users thrive on useless stuff" when all you can tell me is about all the random great things it can do… not of which has any good use for our intended purposes. They are not widely used here for a reason.


The reason I named them random is because I didn't want to defend my choice about those specific awesomely useful utilities. I know you won't accept it anyway.

From: IceFire908


Right I only use reflection because it totally hasn't been broken almost the entire time during my periods of activity. It worked for a week 3 years ago and for a month when I came back in June. And I totally didn't write the only script to runecraft through the Abyssal space entirely IN COLOR with the addition of 3 different land runes, completely in 100% COLOR. Clearly I only use reflection, and somehow found a way to use reflection to find bitmaps… lol??


Wait, what. You TOTALLY missed my point. The reflection was only added to my sentence to add that little sarcasm.

From: IceFire908

Obviously I have not a clue in the world, I had 1 limitation ever, writing the hardest script I ever faced and it was that it was to slow in the interpreter to find colors along a line for all 360 degrees so I wrote a plugin in a really short amount of time without much work at all and utilized it without any excess problems… or was that something SCAR is only capable as of now? Yea I agree plugins in simba are a MESS. <.< Plugins seem to be pretty amazing, take SMART for example. Just because it's not something some major corporation is ready to endorse it makes it not amazing, apparently.


You're really randomly trying to offend me, but are failing to do so… You do know that we maintained the same plug-in standards as SCAR, right?

From: IceFire908
What? That's all server side anyways… it doesn't make sense to have that any other way.


I don't really have to add anything to this… You're not thinking clearly I guess…

From: IceFire908
You've yet to explain how.


I think everyone else in this thread except you (and c0de, but he's a different story) quite understands my ``explanation''…

—-

I'm completely done arguing with you… :)
Perhaps some time later you read this again and think ``/facepalm… was that really me?'' ;)

Wizzup?

2010-04-10 14:11:50

From: Dan Cardin
python doesnt have proper multiline comments and you need to call something global to use it in a function. I dislike those. In case anyone was wondering. (but i very much like the rest…in case anyone else was wondering.) On a side note, i dislike that pygame's method for displaying things to the screen is pygame.display.flip - this is also kind of annoying, but not directly related to python. On a brighter note, the for loops in python are really cool. And on a final note, almost every time i type out python i accidentally write pythong for some reason. I'm not sure whether that's a downside or not.


It does have multiline comments, and they are also automatically turned into doc. :)


>>> class A:
... """This is a class
... lolol
... """
... def __init__(self):
... pass
...
help(A)

Help on class A in module __main__:

class A
| This is a class
| lolol
|
| Methods defined here:
|
| __init__(self)

:)

Wanted

2010-04-10 15:41:33

Good morning everyone

From: senrath
Okay, that one was a bit of a derail. But my point still stands about my previous comments not being a derail. Also, you just did reply to it.

I'm done here. I can't add anything else productive, and I'd just end up saying something else stupid. There's obviously nothing that anyone can do that will make IceFire change his mind on the subject.


Really it's not a derail? Sure maybe not for the thread because it is already a wild train speeding out of control skidding across a frozen lake, but your stick in the spokes comments don't exactly help any.

The reason you can't add anything productive is because you refuse to reply to anything in this thread other than <1% of the points being discussed here or even to the context of those quotes for that matter.

<@last sentence of your post>

You may be right on that one, with the exception of mixster (in the below posts) no one else has even made a good attempt to prove anything to me with real examples.

But I would also like to point out the same can be said for any one who is 'pro-python'.

_______________________________________

From: mixster
I've actually read every post in this topic (so far remained quiet because, well, I don't always enjoy having pointless arguments with people who I know won't change their position regardless of what evidence or the like I put forward) and your position always seems to be which ever one suits best to the latest post. I was hoping to clarify it as one or the other so I could make sure any posts I made were precisely to the point, but I guess I'll have to target 2 things at once. I thought that as I made several completely new points that so far haven't really been discussed (and you haven't actually refuted them - you just keep saying `it doesn't help with runescape', even though not everyone here actually is here to macro on runescape and you haven't said why it doesn't help).


I find it hard to believe you've read every post in this topic, let alone every word of it. Mainly because you're discussing how I think in some way Java is better than python when I clearly don't, even though it says otherwise in this thread that is not the it at all.

Yea people using SCAR/simba/SRL ect. ect. shouldn't be using SRL include to auto for other things you can fight that all you want but it is about runescape the sad truth is all of this is over a pixel game no matter how well anyone tries to sugar coat it with external uses, SRL (the include) is not about anything else (in terms of usage).

So whether it is intentional or not, we have already drifted away from the main purpose, but for lulz since this thread is so much fun lets continue our adventure. :)

From: mixster
First of all then, Java is a stupid language for macroing. It restricts you to running the big chunky JVM when you want to do anything. It just about restricts you to only macroing on Java applets unless you want to add a load of wrapper stuff for allowing it also to use the robot class too (not even sure how well that works).


Yea you're absolutely right on that one, but who said anything about writing SRL in Java or simba or SCAR ect. ect. I'm 100% sure it wasn't me. I think there was a quote from javamaster Moparisthebest, but since it's dated 2006, I don't think I'll even bother posting it here, and I don't agree with it anyways.

From: mixster
Java is also a very different language that would take a lot longer for the majority of people to learn compared to Python. If you think it would be worth it in the long run to learn Java, then it would also be just as worth it to learn Python. The main reasoning being Java is forced OOP, something which would take a lot of getting used to and it shares C syntax which greatly differers from Pascal syntax - Python still has elements of English to it like Pascal with a hint of C syntax for operators, which I quite like.


Yep you got that one right, Java is the equivalent of alien language when you compare it to something like Pascal, Delphi, or python.

How could is possibly be more useful to know python in the long wrong (if we are indeed talking about the truth behind the purpose of SRL) when runescape itself written in Java, when fixing reflection, relys on knowledge of Java, when understanding the runescape source code, rely on Java… none of these amount to anything python.

Now if you want to talk about real life implications of Python vs Java, it's not even a discussion. The answer is obvious, but we can change contexts all day here and never get anywhere as proven time and time again in this thread.

From: mixster
With every ounce of my reasoning behind me, I can only see Java as a good move if SRL were to only auto RS and use a client like Smart (similar to RSBot and co). But not everyone uses Scar/Simba and SRL to auto RS nor does everyone use (or like using) Smart, but I guess those people aren't really needed in this community.


How very wrong you are about that. If you really believe that then you are looking at SRL and runescape cheating through a collide-a-scope


+



=



Pretty isn't it?

From: mixster
In regards to Python's readability, so far you haven't actually given any decent proof that PascalScript is more readable than Python.
What do you want us to give you? Should I make a `fairly large' script in both PascalScript and in Python then compare which one is more readable? Ok, let's do it!

Scar sauce code

Lazily converted code by me in an hour

I'm not actually that familiar with Python - this is pretty much done with syntax knowledge, outline knowledge for classes and a few documentation pages (1, 2, 3, 4). I also know it's not exactly the same content, but for me it produces the same end results - it collects the SRL SVN, downloads all the files to where I tell it and finds any plugins and moves those to where I tell it. If you change the directories to yours, it should work on Windows too (may need to change line 71 from '/' to '\\' though).

I also know it's quite ugly code, but that's what you get when you convert code pretty much line by line and if I made it in Python from the start it would be a lot more elegant. However, I still see nothing there that's hard to explain, so I've decided to pick out the `hardest' to understand bits and convert them either into Pascal'y stuff or English if that's easier.

class TFile(object):
def __init__(self, path, name):
self.path = path
self.name = name

Which is the equivalent of:
type
TFile = record
path, name: string;
end;

function CreateTFile(path, name: string): TFile;
begin
Result.path := path;
Result.name := name;
end;

That same example can be used for all the other classes I've used to emulate records.

return inp[s:e]
Result := Copy(inp, s, e - s);
or, in English, return everything between (and including) the index s and e from string inp.

There are a couple of intimidating lines like
TSVNFile(TFile(curdir.local.path + tmploc + '/', ''), TFile(curdir.remote.path + tmprem, ''))
But by calling TSVNFile or the like, it's basically calling the `CreateTSVNFile' I mentioned earlier with the class equivalent code.

def ensure_dir(f):
d = os.path.dirname(f)
if not os.path.exists(d):
os.makedirs(d)

Scar doesn't have an equivalent - it just usually lets you create the directory, but sometimes doesn't. Simba does have a function equivalent, but it pretty much does the same as this except returns true or false as to whether or not it was able to.

Erm, yeah. I think that's all the code that would be completely alien to a typical scripter. Some of it may be strange, but I think it's just about readable even if you don't know Python. If there is anything there that you aren't sure about, do give me a shout and I'll give you its Scar equivalent.


I salute thee, taking as much time to put efforts and actual usages of python and comparing them to SCAR, something people on here have refused to do out of laziness or neglect, thank you for supplying us with this fine example :D

Although it only goes as far to compare an updater written in SCAR to the syntax equivalent in python, it still shows the clear differences between the two in latent terms. But I'd like to point out to everyone that that is an auto updater, and not anything that uses the SRL Include or runescape related functions in any way.

Hey lets look at Quickmarche's auto updater in POMS http://srlpoms.googlecode.com/svn/trunk/Includes/SVN.scar yea hmm I'm not surprised the python equivalent isn't any harder to read.

Why don't you create a python equivalent for this?

{*******************************************************************************
function OpenBankIce: Boolean;
By: IceFire908.
Description: Opens any bank needed for RCrB using color.
*******************************************************************************}

function OpenBankIce: Boolean;
var
BankInfo: TVariantArray;
TPAA: T2DPointArray;
Use: TStringArray;
TPA: TPointArray;
I, T: LongInt;
Bank: string;
OB: TPoint;
Re: Byte;
begin
if (not (LoggedIn)) then
Exit;
Bank := Between('(', ')', Players[CurrentPlayer].Strings[1]);
if (Bank = 'Abyss') then
Bank := 'EB';
case Bank of
'VWB': BankInfo := [1, 0.12, 0.29, MSX1, MSCY, 2443092, 5, 30, 30, 150];
'VEB': BankInfo := [0, 0.11, 1.70, MSCX, MSCY, 2115671, 5, 30, 30, 100];
'AKB': BankInfo := [0, 3.40, 0.84, MSCX, MSCY, 7435867, 14, 15, 30, 200];
'EB': BankInfo := [0, 0.34, 0.99, MSCX, MSCY, 4216161, 1, 35, 35, 75];
end;
WriteLn('Opening ' + Bank + '...');
for Re := 0 to BankInfo[0] do
begin
ColorToleranceSpeed(2);
SetColorSpeed2Modifiers(BankInfo[1], BankInfo[2]);
FindColorsSpiralTolerance(BankInfo[3], BankInfo[4], TPA, BankInfo[5], MSX1, MSY1, MSX2, MSY2, BankInfo[6]);
SetColorSpeed2Modifiers(0.2, 0.2);
ColorToleranceSpeed(1);
if (Length(TPA) > 0) then
begin
TPAA := TPAToATPAEx(TPA, BankInfo[7], BankInfo[8]);
SortATPAFromFirstPoint(TPAA, Point(BankInfo[3], BankInfo[4]));
for I := 0 to High(TPAA) do
begin
if (Length(TPAA[I]) < BankInfo[9]) then
Continue;
OB := MiddleTPA(TPAA[I]);
MMouse(OB.X, OB.Y, 1, 1);
Wait(200 + Random(50));
Use := [];
if (CountColorTolerance(14342657, 7, 7, 100, 25, 70) > 150) then
Use := ['quick', 'uick', 'uic']
else
if (CountColorTolerance(648165, 7, 7, 100, 25, 50) > 100) then
Use := ['ank B', 'nk B', 'k Ba'];
if (Length(Use) > 0) then
begin
GetMousePos(OB.X, OB.Y);
Mouse(OB.X, OB.Y, 0, 0, False);
Wait(200 + Random(50));
if (not (ChooseOptionMulti(Use))) then
Continue;
FFlag(0);
T := GetSystemTime;
repeat
Wait(100 + Random(50));
if (PinScreen) then
begin
InPin(Players[CurrentPlayer].Strings[0]);
Wait(2000 + Random(200));
ClickToContinue;
end;
if (BankScreen) then
begin
Result := True;
Break;
end;
until ((GetSystemTime - T) > 6000);
if (Result) then
Break;
end;
end;
end;
if (not (Result)) then
if ((Re = 0) and (Bank = 'VWB')) then
begin
Mouse(MMCX, MMCY - 10, 0, 0, True);
FFlag(0);
Wait(1000 + Random(1000));
end
else
begin
Result := OpenBankFast(Bank);
if (Result) then
WriteLn('Opened ' + Bank + ' using OpenBankFast.');
end;
if (Result) then
begin
WriteLn('Opened ' + Bank + '.');
Inc(Players[CurrentPlayer].Banked);
Inc(TotalScript[10]);
WriteINI('TotalScript', '10', IntToStr(TotalScript[10]), ScriptPath + 'ScriptSettings.INI');
Inc(Total[9]);
Inc(Banks);
FixBank;
Exit;
end;
end;
WriteLn('Failed to open ' + Bank + ', logging out...');
LogOut;
end;

I'm 100% positive that will be easier to read in pascal than any other language.


From: Nava2
I'd like to point out, the SCAR code is twice as long as the python code, and less elegant.

That is all.


I'm so glad we have you here to keep commenting like this. :rolleyes: :p ;)

From: Wizzup?
Very useful indeed. Just because you don't think out of the box doesn't mean other won't. :)


Yea who would of ever thought to use gzip to make a color script, I need expand my mind more here.

Why stop there? Why not use python's super l333t "image manipulation" to make SplitTPA ridiculously over powered and complicated?

The possibilities in python are endless.

Lol@streaming porn :shifty:

From: Wizzup?
Horrible??? Wat. This is very common code, and it applies to a lot of cases.


Hahaha yea maybe in chapter 1 of scripting manuals

function TakeOverTheWorld
<Strange shit here>
<The easy to read debug part>

Yea it is common, but who cares… I mean seriously.


From: Wizzup?
I don't see the disadvantage to this? When I first read Pascal I was like "wtf?" too.


Srsly comon, you mean to tell me you were as wtf confused when you first saw pascal than you would have been if had first ever tried to read through python?



From: Wizzup?
Hahahahaaaa… You made me laugh out loud… :D
You do know that this is not actual syntax, right?


Sorry I'm not a python expert, I was completely wtfconfused by that for a while even after reading the article… sorry if I don't know every language you randomly decide is the best one every 6 months.

From: Wizzup?
Replace Int with any other type…? Unless you want to create something for every type? Damn…


function InArr(X: Variant; Arr: TVariantArray): Boolean;
var
I: LongInt;
begin
Result := True;
for I := High(Arr) downto 0 do
if (VarType(X) = VarType(Arr[I])) then
if (Arr[I] = X) then
Exit;
Result := False;
end;

var
X: Variant;
Arr: TVariantArray;

begin
X := 56.3211;
Arr := [5, 'a', True, 56.3211];
if (InArr(X, Arr)) then
WriteLn('wow');
end.

Try it out :)


From: Wizzup?
To the first point, I really don't have much to say. I'm stumbled by this comment…

Moving from languages? Get your facts straight, bro…


"Yes, I am listing some ``random'' stuff, but they could easily be used."

'easily used' yet you fail to provide any actual examples or uses for them.

I have my facts straight, do you really want me to start digging out your posts in year intervals all the way back to '06?



From: Wizzup?
The reason I named them random is because I didn't want to defend my choice about those specific awesomely useful utilities. I know you won't accept it anyway.


The real reason is because there is nothing.



From: Wizzup?
Wait, what. You TOTALLY missed my point. The reflection was only added to my sentence to add that little sarcasm.


Yea I responded to your sarcasm with my own maybe I should of used [/sarcasm] tags.



From: Wizzup?
You're really randomly trying to offend me, but are failing to do so… You do know that we maintained the same plug-in standards as SCAR, right?


Yea except for :std; which is only… ohwait.

Call me an idiot, but every attempt I've made at making a plugin for simba has failed.



From: Wizzup?
I don't really have to add anything to this… You're not thinking clearly I guess…


Yea obviously, because I totally want local script stats… that makes no sense dude. WriteINI if personal records I have no idea what you're talking about with local script stats…seriously man?



From: Wizzup?
I think everyone else in this thread except you (and c0de, but he's a different story) quite understands my ``explanation''…

—-


Lol apparently we are the only ones wasting time even bothering to dispute this thread… there are many more trust me. There are more people in this thread too which you have neglected (raymond, nielsie, RM ect..)

I would love to see this discussed in jr's or even in members. But that isn't going to happen now is it?

From: Wizzup?
I'm completely done arguing with you… :)
Perhaps some time later you read this again and think ``/facepalm… was that really me?'' ;)


I have a strong feeling this thread will be the very least of mine or your worries if the ideas expressed in this thread are carried through with.

From: Wizzup?
You're leading this thread nowhere.


"SRL 5 is going to be written in pascal"

Sorry but this thread was going nowhere from the very start.

Wizzup?

2010-04-10 15:57:13

I'd like to point out that a Variant is far from any type. It only exists out of a select few. (Read: base types) So your argument is completely invalid.


program new;
var
t:tpoint;
v: variant;
begin
t:=point(40,50);
v := t;
end.

You're doing nothing but stating the opposite of what I try to support with good arguments, yet your counter-opinion isn't supported by any arguments; to the other stuff you posted, I can only smile in dismay. I mean come on… WriteINI? lol

Wanted

2010-04-10 16:11:17

From: Wizzup?
I'd like to point out that a Variant is far from any type. It only exists out of a select few. (Read: base types) So your argument is completely invalid.


program new;
var
t:tpoint;
v: variant;
begin
t:=point(40,50);
v := t;
end.

You're doing nothing but stating the opposite of what I try to support with good arguments, yet your counter-opinion isn't supported by any arguments; to the other stuff you posted, I can only smile in dismay. I mean come on… WriteINI? lol


Really? No shit I didn't know it only worked with primitives.

Lo@local stats.

Great response.

Dan Cardin

2010-04-10 16:17:41

From: Wizzup?


>>> class A:
... """This is a class
... lolol
... """
... def __init__(self):
... pass
...


i realize that, i think i meant more commenting in the middle of a line as a multiline comment and doing something like this
x, y = 0, """0""" 1

From: Nava2
*sigh* I think this is useless to continue with the current audience.

the current audience is the same audience that you're going to need to use and deal with when/if srl includes python.

Wizzup?

2010-04-10 16:26:12

From: Dan Cardin
i realize that, i think i meant more commenting in the middle of a line as a multiline comment and doing something like this
x, y = 0, """0""" 1



I'm not sure if you can comment in the middle of a line… Don't really see the purpose to it…

senrath

2010-04-10 16:27:44

From: IceFire908

The reason you can't add anything productive is because you refuse to reply to anything in this thread other than <1% of the points being discussed here or even to the context of those quotes for that matter.


I know I said I was done, but this is too stupid for me to pass up. I was saying, using what I quoted in context, that you being "overwhelmed" by a small, optional piece of Python is not a good argument against it. It would be like me arguing against using Pascal because I didn't know how to read it when I first came here. Just because I didn't feel like refuting every single point you made doesn't mean what I say is any less valid.

From: IceFire908
function InArr(X: Variant; Arr: TVariantArray): Boolean;
var
I: LongInt;
begin
Result := True;
for I := High(Arr) downto 0 do
if (VarType(X) = VarType(Arr[I])) then
if (Arr[I] = X) then
Exit;
Result := False;
end;

var
X: Variant;
Arr: TVariantArray;

begin
X := 56.3211;
Arr := [5, 'a', True, 56.3211];
if (InArr(X, Arr)) then
WriteLn('wow');
end.
Yeah, try that with a TIntegerArray, or an array of Extended, or anything other than a TVariantArray. It won't work, I promise.

c0de

2010-04-10 17:19:23

From: Wizzup?
I'm not sure if you can comment in the middle of a line… Don't really see the purpose to it…


You can do it in C, so why not in Python? Seems like a reason to me to rewrite SRL in C then… After all I would like to have that ``option''.

Janilabo

2010-04-10 17:47:22

How about… ..a chance to support both languages in future?
I would love to have Pascal available even in the future.. :( Not only (note: ONLY) the Python.

I do support Python, though.
Just hoping it will be optional, like a personal choice, which language to use…
So, maybe 2 projects? Simba with Pascal and the other with Python? Any possibility to go with that? Or was it the plan?

Nava2

2010-04-10 17:59:28

The plan was never to drop support fully, afaik.

mixster

2010-04-10 19:58:48

From: IceFire908
I find it hard to believe you've read every post in this topic, let alone every word of it. Mainly because you're discussing how I think in some way Java is better than python when I clearly don't, even though it says otherwise in this thread that is not the it at all.


No, you are saying it's better. You may not be saying it's better as a language, but you're saying it's better for SRL to use Java than it is to use Python. If Java is a much worse language, then it obviously isn't a better idea - that's what I was getting at.


Yea people using SCAR/simba/SRL ect. ect. shouldn't be using SRL include to auto for other things you can fight that all you want but it is about runescape the sad truth is all of this is over a pixel game no matter how well anyone tries to sugar coat it with external uses, SRL (the include) is not about anything else (in terms of usage).


So because of that they have no say in anything here? I've actually put a lot of time into SRL and haven't really autoed. Others are in a similar situation - does that make them all worthless in the grand scheme of things to the point where they don't matter?


Yea you're absolutely right on that one, but who said anything about writing SRL in Java or simba or SCAR ect. ect. I'm 100% sure it wasn't me. I think there was a quote from javamaster Moparisthebest, but since it's dated 2006, I don't think I'll even bother posting it here, and I don't agree with it anyways.


Well, you did! You even cleared your stance - we should stick with PascalScript or if we are to move, it should be Java over Python! You can't say you think it should be Java rather than Python and say that you didn't advocate for Java! This is why I wanted to clear your stance - it makes it very easy for you to just alternate between the two to make people seem wrong.


How could is possibly be more useful to know python in the long wrong (if we are indeed talking about the truth behind the purpose of SRL) when runescape itself written in Java, when fixing reflection, relys on knowledge of Java, when understanding the runescape source code, rely on Java… none of these amount to anything python.


I believe multiple people in this thread have said that they know Java or have learned Java or the like and it didn't help at all in regards to reflection. Then again, maybe I imagined it as you're telling me I didn't read the thread.

Anyway, Python is pretty much more useful in the long run compared to PascalScript. If you take into mind my above point, then it comes to reason that Java is no more useful than Python could be.

With every ounce of my reasoning behind me, I can only see Java as a good move if SRL were to only auto RS and use a client like Smart (similar to RSBot and co). But not everyone uses Scar/Simba and SRL to auto RS nor does everyone use (or like using) Smart, but I guess those people aren't really needed in this community.

How very wrong you are about that. If you really believe that then you are looking at SRL and runescape cheating through a collide-a-scope


Why is it wrong? Your claim is worthless with no evidence (and no random, large pictures aren't evidence in this case). My other points supported that overall claim of mine, so you can't simply dismiss it that easily!


I salute thee, taking as much time to put efforts and actual usages of python and comparing them to SCAR, something people on here have refused to do out of laziness or neglect, thank you for supplying us with this fine example :D

Although it only goes as far to compare an updater written in SCAR to the syntax equivalent in python, it still shows the clear differences between the two in latent terms. But I'd like to point out to everyone that that is an auto updater, and not anything that uses the SRL Include or runescape related functions in any way.


Funnily enough I couldn't really as the SRL include isn't ported to Python yet - kinda what this topic is discussing. Thanks for trying to undermine me with such a silly argument.


Hey lets look at Quickmarche's auto updater in POMS http://srlpoms.googlecode.com/svn/trunk/Includes/SVN.scar yea hmm I'm not surprised the python equivalent isn't any harder to read.


I'm not actually sure what that was about. Are you saying it's really easy to read, hard to read, simple, complex? Regardless of what it is, there actually isn't a Python equivalent of his - mine is quite different from his as mine is a more general one that was intended to be widely applicable with minimal knowledge of the overall code, where as I believe his is firmly rooted into Googlecode only - try something more relevant next time :)


Why don't you create a python equivalent for this?


Sure, but I hope you don't expect it to do anything more than compile, due to my earlier point of there currently being no SRL in Python.

import sys, time, random

class TPoint(object):
def __init__(self, x=0, y=0):
self.x = x
self.y = y

class TPlayer(object):
def __init__(self, strs=[]):
self.Strings = strs
self.Banked = 0

def Loggedin():
return True

def Between(st, en, inp):
s = inp.find(st) + len(st)
e = inp.find(en, s)
if (s == len(st) - 1) or (e == -1):
return ''
else:
return inp[s:e]

def ColorToleranceSpeed(x):
return

def SetColorSpeed2Modifiers(x, y):
return

def FindColorsSpiralTolerance(x, y, tpa, color, x1, y1, x2, y2, tol):
tpa = [TPoint(), TPoint(5, 5), TPoint(10, 0)]
return True

def TPAToATPAEx(TPA, w, h):
return [TPA]

def SortATPAFromFirstPoint(ATPA, Point):
return ATPA

def MiddleTPA(tpa):
return tpa[0]

def MMouse(x, y, rx, ry):
return

def Mouse(x, y, rx, ry, click):
return

def CountColorTolerance(c, x1, y1, x2, y2, t):
return 42

def GetMousePos(x, y):
return TPoint(x + 5, y - 7)

def ChooseOptionMulti(x):
return True

def FFlag(x):
return

def PinScreen():
return False

def InPin(x):
return

def ClickToContinue():
return

def BankScreen():
return True

def OpenBankFast(bank):
return True

def LogOut():
return

def OpenBankIce():
if not Loggedin():
return False
Bank = Between('(', ')', Players[CurrentPlayer].Strings[1])
if Bank == 'VWB':
BankInfo = [1, 0.12, 0.29, MSX1, MSCY, 2443092, 5, 30, 30, 150]
elif Bank == 'VEB':
BankInfo = [0, 0.11, 1.70, MSCX, MSCY, 2115671, 5, 30, 30, 100]
elif Bank == 'AKB':
BankInfo = [0, 3.40, 0.84, MSCX, MSCY, 7435867, 14, 15, 30, 200]
elif Bank == 'EB':
BankInfo = [0, 0.34, 0.99, MSCX, MSCY, 4216161, 1, 35, 35, 75]
else:
return False # Really just a failsafe to ensure Python doesn't crash when passed an invalid bank as you don't check that

print('Opening ' + Bank + '...')

res = False
for Re in range(0, BankInfo[0]):
ColorToleranceSpeed(2);
SetColorSpeed2Modifiers(BankInfo[1], BankInfo[2]);
TPA = []
FindColorsSpiralTolerance(BankInfo[3], BankInfo[4], TPA, BankInfo[5], MSX1, MSY1, MSX2, MSY2, BankInfo[6]);
SetColorSpeed2Modifiers(0.2, 0.2);
ColorToleranceSpeed(1);
if len(TPA) > 0:
TPAA = TPAToATPAEx(TPA, BankInfo[7], BankInfo[8])
SortATPAFromFirstPoint(TPAA, TPoint(BankInfo[3], BankInfo[4]))

for curTPA in TPAA:
if len(curTPA) < BankInfo[9]:
continue
OB = MiddleTPA(curTPA)
MMouse(OB.x, OB.y, 1, 1)
time.sleep(0.2 + (random.random() * 0.05))
use = []
if CountColorTolerance(14342657, 7, 7, 100, 25, 70) > 150:
use = ['quick', 'uick', 'uic']
elif CountColorTolerance(648165, 7, 7, 100, 25, 50) > 100:
use = ['ank B', 'nk B', 'k Ba']
if len(use) > 0:
OB = GetMousePos(OB.x, OB.y)
Mouse(OB.x, OB.y, 0, 0, False)
time.sleep(0.2 + (random.random() * 0.05))
if not ChooseOptionMulti(use):
continue

FFlag(0)
t = time.clock() + 6
while time.clock() < t:
time.sleep(0.1 + (random.random()*0.05))
if PinScreen():
InPin(Players[CurrentPlayer].Strings[0])
time.sleep(2 + (random.random() * 0.2))
ClickToContinue()
if BankScreen():
res = True
break
if res:
break
if not res:
if (Re == 0) and (Bank == 'VWB'):
Mouse(MMCX, MMCY - 10, 0, 0, True)
FFlag(0)
time.sleep(1 + random.random())
else:
res = OpenBankFast(Bank)
if res:
print('Opened ' + Bank + ' using OpenBankFast.')
if res:
print('Opened ' + Bank + '.')
Players[CurrentPlayer].Banked += 1
# Insert some other incs here
return res
print('Failed to open ' + Bank + ', logging out...')
LogOut()
return False

def Test(a):
a.x += 1

Players = [TPlayer(['', '(VWB)'])]
CurrentPlayer = 0
MSX1, MSY1 = 0, 0
MSCY = 0
MSX2, MSY2 = 0, 0
MMCX, MMCY = 0, 0
random.seed()
OpenBankIce()


I'm 100% positive that will be easier to read in pascal than any other language.


I also just want to point out that what I've done is pretty much copied it over and fixed the syntax to make it Python compatible (which it is). As an analogy (which you will without question say is stupid and pointless), a poem translated into any other language will never sound as sweet as in the language it was written.

Maybe if you are up for proving how much more readable PascalScript is, I could post a Python script I've made and you can translate it and show us how amazing PascalScript is (go on then, Pascal/Delphi/FPC if you really want to)?


Yea who would of ever thought to use gzip to make a color script, I need expand my mind more here.


Who would have thought that people may have large pieces of data that they would rather be smaller when downloaded then expand later on, like the SRL include (more specifically the plugins and some of the other exe tools that come with it) or large bitmaps.


Why stop there? Why not use python's super l333t "image manipulation" to make SplitTPA ridiculously over powered and complicated?


None of this has been about complicating anything or the like. It has pretty much about giving scripters any option they can possibly think of. Python has modules to do a lot of stuff, some of which could very well be of use to people.


The possibilities in python are endless.

Lol@streaming porn :shifty:


I have sauce for one if you want

function InArr(X: Variant; Arr: TVariantArray): Boolean;
var
I: LongInt;
begin
Result := True;
for I := High(Arr) downto 0 do
if (VarType(X) = VarType(Arr[I])) then
if (Arr[I] = X) then
Exit;
Result := False;
end;

var
X: Variant;
Arr: TVariantArray;

begin
X := 56.3211;
Arr := [5, 'a', True, 56.3211];
if (InArr(X, Arr)) then
WriteLn('wow');
end.

Try it out :)


Try changing Arr to an integer array - it doesn't really like it. Or a string array… Or anything other than a TVariantArray really. So we shall be requiring one of those functions for ints, strings, floats, chars (or use Pos I guess), tpoints would be nice too.

Wanted

2010-04-10 22:37:42

From: mixster
No, you are saying it's better. You may not be saying it's better as a language, but you're saying it's better for SRL to use Java than it is to use Python. If Java is a much worse language, then it obviously isn't a better idea - that's what I was getting at.


No, I am not saying it's by any means better, if you fail to understand that then don't even bother talking to me on this subject any longer if you fail to comprehend my stance on it even though I've spelled it out 8 times on this thread. Obviously your idea of "use" is "oh lets write FindColor in Java" or some shit. I'm talking about people at SRL accepting Java and perusing it so they can fix /utilize reflection hooks, interpret the damn Runescape client… and maybe hold their own against the new update. I know what you're getting at, but you obviously have no idea what I'm getting at, which is a major problem.



From: mixster
So because of that they have no say in anything here? I've actually put a lot of time into SRL and haven't really autoed. Others are in a similar situation - does that make them all worthless in the grand scheme of things to the point where they don't matter?


Why would someone, not using the SRL include, want to or even care about having a say in whether or not it supports python? You mean to tell me (outside of Mouse.scar) that someone using SCAR or simba for some other purpose besides runescape, is going to need to use the SRL include? Tell me what possible things in SRL could they find so useful that they would need to include the entire thing, rather than take a piece of it and copy it out, just to have the compile time increase times over 9000. And it MUST be in python, makes absolutely no sense to me at all. If you did anything runescape related that used the SRL include in recent history, you would realize how absolutely ridiculous the idea of using python is for it.

I'm not saying your opinion shouldn't matter, I'm just saying that it doesn't make sense for people not using the Include to tell people who do use it what language it should be written in.

Make sense?


From: mixster
Well, you did! You even cleared your stance - we should stick with PascalScript or if we are to move, it should be Java over Python! You can't say you think it should be Java rather than Python and say that you didn't advocate for Java! This is why I wanted to clear your stance - it makes it very easy for you to just alternate between the two to make people seem wrong.


Kindly go ahead and try to dig that up for me, because I didn't post it. I've already explained the rest of misunderstanding in my previous paragraphs.



From: mixster
I believe multiple people in this thread have said that they know Java or have learned Java or the like and it didn't help at all in regards to reflection. Then again, maybe I imagined it as you're telling me I didn't read the thread.


That's funny because I don't remember a single person in this thread other than Method doing anything at all even related to reflection via Java, and his stance sounds a bit different than that. "maybe you imagined" I like how you left yourself a way out there. :)

From: mixster
Anyway, Python is pretty much more useful in the long run compared to PascalScript. If you take into mind my above point, then it comes to reason that Java is no more useful than Python could be.


Really, because no matter how good you are at Python it probably is never going to help you understand the runescape client much better… espicially in comparison to Java… but you'll just continue to focus on all the nonexistant outside uses of the SRL include.

___________________________

"But not everyone uses Scar/Simba and SRL to auto RS nor does everyone use (or like using) Smart, but I guess those people aren't really needed in this community."

From: mixster
Why is it wrong? Your claim is worthless with no evidence (and no random, large pictures aren't evidence in this case). My other points supported that overall claim of mine, so you can't simply dismiss it that easily!




In that case, your claim is equally worthless (as it has no evidence either), according to your logic that is, moreso because it is completely wrong when proven. Funnier how this thread is in senior members where there is limited access to it, funnier how you think people interested in using the SRL include are not going to use it for runescape. And It's extremely funny that you think that these 'people' hold some kinda of even remotely near a majority.



From: mixster
Funnily enough I couldn't really as the SRL include isn't ported to Python yet - kinda what this topic is discussing. Thanks for trying to undermine me with such a silly argument.


Would help if you put the collide-a-scope down. ;)




From: mixster
I'm not actually sure what that was about. Are you saying it's really easy to read, hard to read, simple, complex? Regardless of what it is, there actually isn't a Python equivalent of his - mine is quite different from his as mine is a more general one that was intended to be widely applicable with minimal knowledge of the overall code, where as I believe his is firmly rooted into Googlecode only - try something more relevant next time :)


The fact of the matter is, you chose something that wasn't SRL include or runescape script related, rather an auto internet updater, and compared it to python so likewise I showed you something that was equally hard to understand in pascal. You should trying being more relevant next time aswell :)




From: mixster
Sure, but I hope you don't expect it to do anything more than compile, due to my earlier point of there currently being no SRL in Python.

import sys, time, random

class TPoint(object):
def __init__(self, x=0, y=0):
self.x = x
self.y = y

class TPlayer(object):
def __init__(self, strs=[]):
self.Strings = strs
self.Banked = 0

def Loggedin():
return True

def Between(st, en, inp):
s = inp.find(st) + len(st)
e = inp.find(en, s)
if (s == len(st) - 1) or (e == -1):
return ''
else:
return inp[s:e]

def ColorToleranceSpeed(x):
return

def SetColorSpeed2Modifiers(x, y):
return

def FindColorsSpiralTolerance(x, y, tpa, color, x1, y1, x2, y2, tol):
tpa = [TPoint(), TPoint(5, 5), TPoint(10, 0)]
return True

def TPAToATPAEx(TPA, w, h):
return [TPA]

def SortATPAFromFirstPoint(ATPA, Point):
return ATPA

def MiddleTPA(tpa):
return tpa[0]

def MMouse(x, y, rx, ry):
return

def Mouse(x, y, rx, ry, click):
return

def CountColorTolerance(c, x1, y1, x2, y2, t):
return 42

def GetMousePos(x, y):
return TPoint(x + 5, y - 7)

def ChooseOptionMulti(x):
return True

def FFlag(x):
return

def PinScreen():
return False

def InPin(x):
return

def ClickToContinue():
return

def BankScreen():
return True

def OpenBankFast(bank):
return True

def LogOut():
return

def OpenBankIce():
if not Loggedin():
return False
Bank = Between('(', ')', Players[CurrentPlayer].Strings[1])
if Bank == 'VWB':
BankInfo = [1, 0.12, 0.29, MSX1, MSCY, 2443092, 5, 30, 30, 150]
elif Bank == 'VEB':
BankInfo = [0, 0.11, 1.70, MSCX, MSCY, 2115671, 5, 30, 30, 100]
elif Bank == 'AKB':
BankInfo = [0, 3.40, 0.84, MSCX, MSCY, 7435867, 14, 15, 30, 200]
elif Bank == 'EB':
BankInfo = [0, 0.34, 0.99, MSCX, MSCY, 4216161, 1, 35, 35, 75]
else:
return False # Really just a failsafe to ensure Python doesn't crash when passed an invalid bank as you don't check that

print('Opening ' + Bank + '...')

res = False
for Re in range(0, BankInfo[0]):
ColorToleranceSpeed(2);
SetColorSpeed2Modifiers(BankInfo[1], BankInfo[2]);
TPA = []
FindColorsSpiralTolerance(BankInfo[3], BankInfo[4], TPA, BankInfo[5], MSX1, MSY1, MSX2, MSY2, BankInfo[6]);
SetColorSpeed2Modifiers(0.2, 0.2);
ColorToleranceSpeed(1);
if len(TPA) > 0:
TPAA = TPAToATPAEx(TPA, BankInfo[7], BankInfo[8])
SortATPAFromFirstPoint(TPAA, TPoint(BankInfo[3], BankInfo[4]))

for curTPA in TPAA:
if len(curTPA) < BankInfo[9]:
continue
OB = MiddleTPA(curTPA)
MMouse(OB.x, OB.y, 1, 1)
time.sleep(0.2 + (random.random() * 0.05))
use = []
if CountColorTolerance(14342657, 7, 7, 100, 25, 70) > 150:
use = ['quick', 'uick', 'uic']
elif CountColorTolerance(648165, 7, 7, 100, 25, 50) > 100:
use = ['ank B', 'nk B', 'k Ba']
if len(use) > 0:
OB = GetMousePos(OB.x, OB.y)
Mouse(OB.x, OB.y, 0, 0, False)
time.sleep(0.2 + (random.random() * 0.05))
if not ChooseOptionMulti(use):
continue

FFlag(0)
t = time.clock() + 6
while time.clock() < t:
time.sleep(0.1 + (random.random()*0.05))
if PinScreen():
InPin(Players[CurrentPlayer].Strings[0])
time.sleep(2 + (random.random() * 0.2))
ClickToContinue()
if BankScreen():
res = True
break
if res:
break
if not res:
if (Re == 0) and (Bank == 'VWB'):
Mouse(MMCX, MMCY - 10, 0, 0, True)
FFlag(0)
time.sleep(1 + random.random())
else:
res = OpenBankFast(Bank)
if res:
print('Opened ' + Bank + ' using OpenBankFast.')
if res:
print('Opened ' + Bank + '.')
Players[CurrentPlayer].Banked += 1
# Insert some other incs here
return res
print('Failed to open ' + Bank + ', logging out...')
LogOut()
return False

def Test(a):
a.x += 1

Players = [TPlayer(['', '(VWB)'])]
CurrentPlayer = 0
MSX1, MSY1 = 0, 0
MSCY = 0
MSX2, MSY2 = 0, 0
MMCX, MMCY = 0, 0
random.seed()
OpenBankIce()



I also just want to point out that what I've done is pretty much copied it over and fixed the syntax to make it Python compatible (which it is). As an analogy (which you will without question say is stupid and pointless), a poem translated into any other language will never sound as sweet as in the language it was written.

Maybe if you are up for proving how much more readable PascalScript is, I could post a Python script I've made and you can translate it and show us how amazing PascalScript is (go on then, Pascal/Delphi/FPC if you really want to)?


I'm impressed no, really you've provided me with the exact evidence I need to shove back into thread.

Python does not even support the case
feature!

http://www.python.org/dev/peps/pep-3103/

Status: rejected!

Funny stuff!

Hey why don't show us what this looks like in python:

case Random(100) of
0..25: WriteLn('bottom quarter');
26..50: WriteLn('third quarter');
51..75: WriteLn('second quarter');
76..100: WriteLn('first quarter');
end;

case Something of
'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k': WriteLn('lmaooo!!');
end;

Thats a lot of elif's :sasmokin:



From: mixster
Who would have thought that people may have large pieces of data that they would rather be smaller when downloaded then expand later on, like the SRL include (more specifically the plugins and some of the other exe tools that come with it) or large bitmaps.


Try making sense next time.





From: mixster
None of this has been about complicating anything or the like. It has pretty much about giving scripters any option they can possibly think of. Python has modules to do a lot of stuff, some of which could very well be of use to people.


Cool I'm all for that, just keep it the hell out of the SRL include.





From: mixster
I have sauce for one if you want


Post it.




From: mixster
Try changing Arr to an integer array - it doesn't really like it. Or a string array… Or anything other than a TVariantArray really. So we shall be requiring one of those functions for ints, strings, floats, chars (or use Pos I guess), tpoints would be nice too.


Congratz!

That's only been discussed three times in the past 7 posts!

We already know it only works with primitives! Way to point out the obvious, to bad three people (including me) already beat you to it ::thumbsup:

Oh wait, we already have anything that is InArr<Type> here already premade either in SRL or SCAR/simba so yea kinda a stupid point to make.

Town

2010-04-10 22:38:07

I disagree that this is all over pixels. Learning Scar motivated me to learn several programming languages and to get some real experience in things I might be doing for the rest of my life. In learning real languages, though, I find that writing in Pascal is a real burden. There's a better chance of me writing Runescape macros when I'm getting some worthwhile experience along the way.

I don't expect my personal experiences to influence anyone else in any way. However, I would presume that some of you have had similar experiences.

senrath

2010-04-10 22:52:50

From: IceFire908

We already know it only works with primitives! Way to point out the obvious, to bad three people (including me) already beat you to it ::thumbsup:


Yeah, that's not what he said. I don't know if you misread it, or if it's something else, but what he was saying was that your InVarArr would only work with TVariantArray, not a TIntegerArray or a TPointArray. The whole thing about primitives was simply saying that only primitives would fit inside a TVariantArray.

But you are right saying that someone did beat him to mentioning it. Only one person beat him, but someone did.

Wanted

2010-04-10 23:04:58

From: senrath
Yeah, that's not what he said. I don't know if you misread it, or if it's something else, but what he was saying was that your InVarArr would only work with TVariantArray, not a TIntegerArray or a TPointArray. The whole thing about primitives was simply saying that only primitives would fit inside a TVariantArray.

But you are right saying that someone did beat him to mentioning it. Only one person beat him, but someone did.


Which are types of primitive arrays.

mixster

2010-04-10 23:05:13

From: IceFire908

Hey why don't show us what this looks like in python:

case Random(100) of
0..25: WriteLn('bottom quarter');
26..50: WriteLn('third quarter');
51..75: WriteLn('second quarter');
76..100: WriteLn('first quarter');
end;

case Something of
'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k': WriteLn('lmaooo!!');
end;

Thats a lot of elif's :sasmokin:



import random

r = random.randrange(100)
if r in range(0, 25):
print('bottom quarter')
elif r in range(26, 50):
print('third quarter')
elif r in range(51, 75):
print('second quarter')
elif r in range(76, 100):
print('first quarter')

s = 'a'
if s in 'abcdefghijk':
print('lmaooo!')

Python doesn't support cases because if's and elif's are pretty short and often cases can be avoided. I also find that the use of if's and elif's to be a lot less confusing when chained in Python due to the indenting clearly showing exactly which bits link together. I also find the first example to be much more clear, especially to a beginner or non-scripter, what exactly is going on - `if a random number is in the range 0 to 25 then print out bottom quarter' :)

Anyway, I would comment on the rest of your post too, but it's like 4am now - quite tired. I will say though that I like how you very calmly sidestepped the fact that I did indeed convert your script to Python and instead focused on lack of case. I also like how you feel comfortable not to accept my challenge of converting a Python script to PascalScrip. I also like how you tell me to put the collide-a-scope down for making a very much valid point - how do you expect me to make a SRL or RS script in Python when SRL hasn't got a Python port?

Wanted

2010-04-10 23:07:26

I'll wait for you to rest then so you can make a proper reply :)

c0de

2010-04-10 23:10:15

If you just want to learn Python, you really do not need to convert a whole community over to Python just so *YOU* could learn it and benefit.

And IMHO the starting debate wasn't really about generally switching languages, it was rather why exactly you chose Python over, let's say Ruby, or C++, or Java, or any other high-level language? Java was just an example and how it would benefit towards RuneScape cheating directly which is, let's face it, 80% of these forums dedicated to. On the other hand everything you said you could do in Python could be done in majority of other high-level languages with same ease, and all of that hardly improves cheating in RuneScape.

Why don't you poll people for what language they would like the best, and then convert SRL to the language majority has voted for. After all they are the ones that are supposed to become scripters and use SRL. Why are you so certain that everyone will accept the change? You should ask the public first, see what numbers say and choose the best choice.

If majority votes Python, and converting to Python would mean loosing only a small bit of community, I guess converting to Python would be a good choice, and those that are left would either have to adjust or find another community. But if only minority votes for Python and you do a switch to Python, you are risking of losing lots of members. Since when did majority conform to minority? Aristocracy?

That's what this debate was really about, it just took a wrong turn somewhere in the thread.

Cheers.

Dan Cardin

2010-04-10 23:42:57

From: IceFire908

case Random(100) of
0..25: WriteLn('bottom quarter');
26..50: WriteLn('third quarter');
51..75: WriteLn('second quarter');
76..100: WriteLn('first quarter');
end;

case Something of
'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k': WriteLn('lmaooo!!');
end;



word = 'd'
print {'a': 'lmaooo', 'b': 'this is fun', 'c': 'easier to read', 'd':'maybe'}[word]

i dont know enough about dicts to know how to do the first one without listing out each one, but im fairly sure its possible, so just wait for Wizzup. He also tells me dicts are much faster than cases. Not that you were using it as an example, but switch/case statements are not a good example of easy to read/understand code. if statements are much more noob friendly.


From: c0de
If you just want to learn Python, you really do not need to convert a whole community over to Python just so *YOU* could learn it and benefit.

And IMHO the starting debate wasn't really about generally switching languages, it was rather why exactly you chose Python over, let's say Ruby, or C++, or Java, or any other high-level language? Java was just an example and how it would benefit towards RuneScape cheating directly which is, let's face it, 80% of these forums dedicated to. On the other hand everything you said you could do in Python could be done in majority of other high-level languages with same ease, and all of that hardly improves cheating in RuneScape.

Why don't you poll people for what language they would like the best, and then convert SRL to the language majority has voted for. After all they are the ones that are supposed to become scripters and use SRL. Why are you so certain that everyone will accept the change? You should ask the public first, see what numbers say and choose the best choice.

If majority votes Python, and converting to Python would mean loosing only a small bit of community, I guess converting to Python would be a good choice, and those that are left would either have to adjust or find another community. But if only minority votes for Python and you do a switch to Python, you are risking of losing lots of members. Since when did majority conform to minority? Aristocracy?

That's what this debate was really about, it just took a wrong turn somewhere in the thread.

Cheers.

if you have more than 2 choices you risk having no majority. 36% vs 40% vs 24% nobody has "majority", though someone will will. That happens (if not often, i dont know) in democracy. American presidents have been elected without >50% votes.

senrath

2010-04-11 00:28:00

From: Dan Cardin

if you have more than 2 choices you risk having no majority. 36% vs 40% vs 24% nobody has "majority", though someone will will. That happens (if not often, i dont know) in democracy. American presidents have been elected without >50% votes.


A fix to that is multi-stage voting. You can either eliminate the lowest scoring one each time, or a shorter method would be to just pick the top two and have them compete again.

c0de

2010-04-11 00:37:01

From: Dan Cardin
if you have more than 2 choices you risk having no majority. 36% vs 40% vs 24% nobody has "majority", though someone will will. That happens (if not often, i dont know) in democracy. American presidents have been elected without >50% votes.


Try to narrow it down to two with a poll, then have a poll for those two. At least ask the public what they think and want :)

EDIT: Forgot to refresh, but senrath answered it as well.

Nava2

2010-04-11 01:07:24

I think this needs a broader audience.

I'd also like to, once again, point out that the thought was *never* to drop PS support, but to move SRL5 to Python, while keeping the PS support.

Also, I can see a few places where mixster's open bank could be improved, purely using Python syntax.

c0de

2010-04-11 01:11:16

From: Nava2
I'd also like to, once again, point out that the thought was *never* to drop PS support, but to move SRL5 to Python, while keeping the PS support.


That wouldn't be bad, but someone did mention phasing PS support out and distancing from SCAR…

bullzeye95

2010-04-11 02:06:23

From: Nava2
I'd also like to, once again, point out that the thought was *never* to drop PS support, but to move SRL5 to Python, while keeping the PS support.


That's fine and all, but I agree with c0de: If support for another language is going to be added, the community as a whole should decide what that language will be.

The Claw

2010-04-11 03:01:09

This thread is fucked

Naum

2010-04-11 06:35:57

I also agree with bullzeye and c0de.
However, I think if the community will change then the community should be able to decide what to change to, or to remain the same for that matter.
It is pretty irrepresentative if many of the people who do not script make decisions for people who do script. There is a far greater number of SRL Members who script, we can use their opinions to decide whether or not change is for the better.
(This is kinda what IceFire said in his post)

TRiLeZ

2010-04-11 06:58:37

From: Naum
I also agree with bullzeye and c0de.
However, I think if the community will change then the community should be able to decide what to change to, or to remain the same for that matter.
It is pretty irrepresentative if many of the people who do not script make decisions for people who do script. There is a far greater number of SRL Members who script, we can use their opinions to decide whether or not change is for the better.
(This is kinda what IceFire said in his post)


I agree with Naum. If you're going to change SRL's programming language, you should let us together, as a community to vote on whether or not to change SRL's programming language and if we decide to change the programming language, then we should decide which language it should be. You shouldn't be the one who makes all of the decisions for us.

Are you going to be the one who is going to do all of the coding for SRL? Or are you going to be the one making all of the scripts? NO. When was the last time that you, Wizzup, made a script? Don't you think that the people of SRL should vote?

Don't turn SRL into Jagex, changing RuneScape because they thought that it would improve it, and thought that it was best for it's users. Many RuneScape players are quitting because of Jagex's choices. Did Jagex ever ask their players before changing RuneScape? No. Did you ask this community before deciding to change SRL to Python? No. So, don't make SRLers quit because of your actions, ask the community before you try changing SRL up.

mastaraymond

2010-04-11 07:01:40

Really; You cannot say 'Pascal > Python' without having tried it, that's a biased call. However that's not the issue here.. I'm sure it was Icefire's intention to just say "Don't switch programming language" however this general argument failed so the topic went down to bitching at python which is fucking irrelevant.

Besides I see no reason to 'block' this language out? Just let them Python guys do there thing, it's not like they actively develop SRL in it's current Pascal-state.. So who gives a damn what they do? It's not like there is any intention to 'erase' pascal from SRL? If there is a group of people who want to switch to another language, let them be? It's not like SRL isn't big enough for these kind of developments… On the contrary, it might actually improve SRL as a community..

Wizzup?

2010-04-11 07:41:20

From: mixster

import random

r = random.randrange(100)
if r in range(0, 25):
print('bottom quarter')
elif r in range(26, 50):
print('third quarter')
elif r in range(51, 75):
print('second quarter')
elif r in range(76, 100):
print('first quarter')

s = 'a'
if s in 'abcdefghijk':
print('lmaooo!')

Python doesn't support cases because if's and elif's are pretty short and often cases can be avoided. I also find that the use of if's and elif's to be a lot less confusing when chained in Python due to the indenting clearly showing exactly which bits link together. I also find the first example to be much more clear, especially to a beginner or non-scripter, what exactly is going on - `if a random number is in the range 0 to 25 then print out bottom quarter' :)

Anyway, I would comment on the rest of your post too, but it's like 4am now - quite tired. I will say though that I like how you very calmly sidestepped the fact that I did indeed convert your script to Python and instead focused on lack of case. I also like how you feel comfortable not to accept my challenge of converting a Python script to PascalScrip. I also like how you tell me to put the collide-a-scope down for making a very much valid point - how do you expect me to make a SRL or RS script in Python when SRL hasn't got a Python port?


Actually, it does support cases, it just doesn't have a keyword for them, as that's not really required to do a case statement;
if & elif are quite fine as they are. (Nice going checking the language spec again, Icefire)
They are also easily recreated using Python's o-so-powerful hashmap. (It really is one of the world's top 5.)


>>> {'VWB' : [1, 0.12, 0.29, MSX1, MSCY, 2443092, 5, 30, 30, 150],
'VEB' : [0, 0.11, 1.70, MSCX, MSCY, 2115671, 5, 30, 30, 100],
'AKB' : [0, 3.40, 0.84, MSCX, MSCY, 7435867, 14, 15, 30, 200],
'EB' : [0, 0.34, 0.99, MSCX, MSCY, 4216161, 1, 35, 35, 75]}['VWB']
[1, 0.12, 0.28999999999999998, 0, 0, 2443092, 5, 30, 30, 150]


import sys, time, random

class TPoint(object):
def __init__(self, x=0, y=0):
self.x = x
self.y = y

class TPlayer(object):
def __init__(self, strs=[]):
self.Strings = strs
self.Banked = 0

def Loggedin():
return True

def Between(st, en, inp):
s = inp.find(st) + len(st)
e = inp.find(en, s)
if (s == len(st) - 1) or (e == -1):
return ''
else:
return inp[s:e]

def ColorToleranceSpeed(x):
return

def SetColorSpeed2Modifiers(x, y):
return

def FindColorsSpiralTolerance(x, y, tpa, color, x1, y1, x2, y2, tol):
tpa = [TPoint(), TPoint(5, 5), TPoint(10, 0)]
return True

def TPAToATPAEx(TPA, w, h):
return [TPA]

def SortATPAFromFirstPoint(ATPA, Point):
return ATPA

def MiddleTPA(tpa):
return tpa[0]

def MMouse(x, y, rx, ry):
return

def Mouse(x, y, rx, ry, click):
return

def CountColorTolerance(c, x1, y1, x2, y2, t):
return 42

def GetMousePos(x, y):
return TPoint(x + 5, y - 7)

def ChooseOptionMulti(x):
return True

def FFlag(x):
return

def PinScreen():
return False

def InPin(x):
return

def ClickToContinue():
return

def BankScreen():
return True

def OpenBankFast(bank):
return True

def LogOut():
return

def OpenBankIce():
if not Loggedin():
return False
Bank = Between('(', ')', Players[CurrentPlayer].Strings[1])
if Bank == 'VWB':
BankInfo = [1, 0.12, 0.29, MSX1, MSCY, 2443092, 5, 30, 30, 150]
elif Bank == 'VEB':
BankInfo = [0, 0.11, 1.70, MSCX, MSCY, 2115671, 5, 30, 30, 100]
elif Bank == 'AKB':
BankInfo = [0, 3.40, 0.84, MSCX, MSCY, 7435867, 14, 15, 30, 200]
elif Bank == 'EB':
BankInfo = [0, 0.34, 0.99, MSCX, MSCY, 4216161, 1, 35, 35, 75]
else:
return False # Really just a failsafe to ensure Python doesn't crash when passed an invalid bank as you don't check that

print('Opening ' + Bank + '...')

res = False
for Re in range(0, BankInfo[0]):
ColorToleranceSpeed(2);
SetColorSpeed2Modifiers(BankInfo[1], BankInfo[2]);
TPA = []
FindColorsSpiralTolerance(BankInfo[3], BankInfo[4], TPA, BankInfo[5], MSX1, MSY1, MSX2, MSY2, BankInfo[6]);
SetColorSpeed2Modifiers(0.2, 0.2);
ColorToleranceSpeed(1);
if len(TPA) > 0:
TPAA = TPAToATPAEx(TPA, BankInfo[7], BankInfo[8])
SortATPAFromFirstPoint(TPAA, TPoint(BankInfo[3], BankInfo[4]))

for curTPA in TPAA:
if len(curTPA) < BankInfo[9]:
continue
OB = MiddleTPA(curTPA)
MMouse(OB.x, OB.y, 1, 1)
time.sleep(0.2 + (random.random() * 0.05))
use = []
if CountColorTolerance(14342657, 7, 7, 100, 25, 70) > 150:
use = ['quick', 'uick', 'uic']
elif CountColorTolerance(648165, 7, 7, 100, 25, 50) > 100:
use = ['ank B', 'nk B', 'k Ba']
if len(use) > 0:
OB = GetMousePos(OB.x, OB.y)
Mouse(OB.x, OB.y, 0, 0, False)
time.sleep(0.2 + (random.random() * 0.05))
if not ChooseOptionMulti(use):
continue

FFlag(0)
t = time.clock() + 6
while time.clock() < t:
time.sleep(0.1 + (random.random()*0.05))
if PinScreen():
InPin(Players[CurrentPlayer].Strings[0])
time.sleep(2 + (random.random() * 0.2))
ClickToContinue()
if BankScreen():
res = True
break
if res:
break
if not res:
if (Re == 0) and (Bank == 'VWB'):
Mouse(MMCX, MMCY - 10, 0, 0, True)
FFlag(0)
time.sleep(1 + random.random())
else:
res = OpenBankFast(Bank)
if res:
print('Opened ' + Bank + ' using OpenBankFast.')
if res:
print('Opened ' + Bank + '.')
Players[CurrentPlayer].Banked += 1
# Insert some other incs here
return res
print('Failed to open ' + Bank + ', logging out...')
LogOut()
return False

def Test(a):
a.x += 1

Players = [TPlayer(['', '(VWB)'])]
CurrentPlayer = 0
MSX1, MSY1 = 0, 0
MSCY = 0
MSX2, MSY2 = 0, 0
MMCX, MMCY = 0, 0
random.seed()
OpenBankIce()

I understand you mainly recreated SRL/Simba functions to show how it would work, but there's not a lot of oop in there. Scripts would look slightly different, although this is possible too. ;)

From: mastaraymond
Really; You cannot say 'Pascal > Python' without having tried it, that's a biased call. However that's not the issue here.. I'm sure it was Icefire's intention to just say "Don't switch programming language" however this general argument failed so the topic went down to bitching at python which is fucking irrelevant.

Besides I see no reason to 'block' this language out? Just let them Python guys do there thing, it's not like they actively develop SRL in it's current Pascal-state.. So who gives a damn what they do? It's not like there is any intention to 'erase' pascal from SRL? If there is a group of people who want to switch to another language, let them be? It's not like SRL isn't big enough for these kind of developments… On the contrary, it might actually improve SRL as a community..


Agreed. :)

From: c0de
If you just want to learn Python, you really do not need to convert a whole community over to Python just so *YOU* could learn it and benefit.

And IMHO the starting debate wasn't really about generally switching languages, it was rather why exactly you chose Python over, let's say Ruby, or C++, or Java, or any other high-level language? Java was just an example and how it would benefit towards RuneScape cheating directly which is, let's face it, 80% of these forums dedicated to. On the other hand everything you said you could do in Python could be done in majority of other high-level languages with same ease, and all of that hardly improves cheating in RuneScape.

Why don't you poll people for what language they would like the best, and then convert SRL to the language majority has voted for. After all they are the ones that are supposed to become scripters and use SRL. Why are you so certain that everyone will accept the change? You should ask the public first, see what numbers say and choose the best choice.

If majority votes Python, and converting to Python would mean loosing only a small bit of community, I guess converting to Python would be a good choice, and those that are left would either have to adjust or find another community. But if only minority votes for Python and you do a switch to Python, you are risking of losing lots of members. Since when did majority conform to minority? Aristocracy?

That's what this debate was really about, it just took a wrong turn somewhere in the thread.

Cheers.


A poll will probably follow when it's time. Assuming polling this now will just lead to more confused people who don't really know Python, it's probably better if the Python bindings are first finished, so people will get a better picture of SRL/Simba w/ Python.

mixster

2010-04-11 10:22:59

From: IceFire908
No, I am not saying it's by any means better, if you fail to understand that then don't even bother talking to me on this subject any longer if you fail to comprehend my stance on it even though I've spelled it out 8 times on this thread. Obviously your idea of "use" is "oh lets write FindColor in Java" or some shit. I'm talking about people at SRL accepting Java and perusing it so they can fix /utilize reflection hooks, interpret the damn Runescape client… and maybe hold their own against the new update. I know what you're getting at, but you obviously have no idea what I'm getting at, which is a major problem.


So we still use PascalScript, but tell everyone to go learn Java? Please, I asked you to tell me your stance for this very reason and you said `Stick with PascalScript, learn Java over Python' and I then said why Java is a pretty horrible language for macroing, but you meant just like, learn both at the same? The problem with that being people who have wanted to fix reflection have kind of tried to and I don't think many succeeded. So if people who want to do it failed, why would the average Joe scripter who doesn't really want to be able to do it?

Sure I agree, having a Java-fluent community would most likely lead to reflection being more permanently fixed, but why would the whole community learn Java when they're already learning PascalScript and Java wouldn't actually allow them to macro?


Why would someone, not using the SRL include, want to or even care about having a say in whether or not it supports python? You mean to tell me (outside of Mouse.scar) that someone using SCAR or simba for some other purpose besides runescape, is going to need to use the SRL include? Tell me what possible things in SRL could they find so useful that they would need to include the entire thing, rather than take a piece of it and copy it out, just to have the compile time increase times over 9000.


Why can't they include the whole thing? But anyway, useful parts of the library are improved mouse functions, improved typing functions, the Object.scar file has multiple FindObject's that can are pretty useful if you remove the UpText checking. Color.scar has some general use wrappers for harder to use functions and a couple of nice general use functions (GetBestColor for example). Text.scar has the explode and implode for older Scar versions as well as a few like InStrArr and others rearranging those words. Timing.scar has a few expansions to Scar's normal time functions.

It may not be overly much, but it is a lot of useful additions to Scar. Then there's also all the neat stuff in WizzyPlugin (yes that is part of SRL - it comes with SRL's plugins) that's pretty useful if you plan on doing anything serious.

Anyway, I in no way suggested they were a majority, but I do think that dismissing them because they don't auto is out of hand as they are still members of the community.


And it MUST be in python, makes absolutely no sense to me at all. If you did anything runescape related that used the SRL include in recent history, you would realize how absolutely ridiculous the idea of using python is for it.


The idea of using Python for Runescape macroing is almost as far out and crazy as using PascalScript to do it!


I'm not saying your opinion shouldn't matter, I'm just saying that it doesn't make sense for people not using the Include to tell people who do use it what language it should be written in.

Make sense?


This hasn't been about telling you to use it, but trying to show you why I think it would be beneficial to use it rather than PascalScript (something which is less clear when you see how far the debate has come).


Kindly go ahead and try to dig that up for me, because I didn't post it. I've already explained the rest of misunderstanding in my previous paragraphs.


If am indeed correct with my above thought that you want to encourage learning Java alongside PascalScript, then indeed that would make what I said wrong.


That's funny because I don't remember a single person in this thread other than Method doing anything at all even related to reflection via Java, and his stance sounds a bit different than that. "maybe you imagined" I like how you left yourself a way out there. :)


Just want to point you to Method's post here which clearly does say that him learning Java helped him become awesome… oh no wait, it doesn't. But wait, he posted again here where he said that learning general Java probably won't be enough and say `that is nothing close to the amount required to build an updater and look through the client for fields you're interested in (and then to build patterns to locate those fields across client revisions).' - yeah, quite a supportive view for you. After that, you then have HyperSecret here talking about him learning Java in no way enabled him to help with reflection at all. True, he does say he would like to try again after Java classes.



Really, because no matter how good you are at Python it probably is never going to help you understand the runescape client much better… espicially in comparison to Java… but you'll just continue to focus on all the nonexistant outside uses of the SRL include.


Since when does PascalScript help you understand the Runescape client? SRL has actually never been about understanding it or using reflection at all - it was an unofficial side project of a group of people. Why Python over PascalScript? For all the reasons that have been said that you have dismissed as `false' for reasons only known to you.


"But not everyone uses Scar/Simba and SRL to auto RS nor does everyone use (or like using) Smart, but I guess those people aren't really needed in this community."

In that case, your claim is equally worthless (as it has no evidence either), according to your logic that is, moreso because it is completely wrong when proven. Funnier how this thread is in senior members where there is limited access to it, funnier how you think people interested in using the SRL include are not going to use it for runescape. And It's extremely funny that you think that these 'people' hold some kinda of even remotely near a majority.


The claim I was referring to was actually the bit right before that - `With every ounce of my reasoning behind me, I can only see Java as a good move if SRL were to only auto RS and use a client like Smart (similar to RSBot and co).'
That did indeed have support - the previous few paragraphs. I'll put this little slip-up down to a mistake and not you purposely picking the weaker one and then assuming what I said only referred to that to make it easier for you to break it.

Anyway, as you did want to focus on that, it's because Scar & Simba are very much general macroers, but by switching to Java you would indeed make them very different products for the reasons I stated.



Funnily enough I couldn't really as the SRL include isn't ported to Python yet - kinda what this topic is discussing. Thanks for trying to undermine me with such a silly argument.

Would help if you put the collide-a-scope down. ;)

The fact of the matter is, you chose something that wasn't SRL include or runescape script related, rather an auto internet updater, and compared it to python so likewise I showed you something that was equally hard to understand in pascal. You should trying being more relevant next time aswell :)


Because making a silly joke some how makes my defence of producing a functioning Python equivalent of a PascalScript script that doesn't relate to RS any less important? The main point of the script anyway was to show you how similar the general syntax is - I bet if you looked at them side by side you could easily match up the same lines and read one just as easily as the other. Oh and for the record, my script was SRL Include related as it downloaded it :)


I'm impressed no, really you've provided me with the exact evidence I need to shove back into thread.

Python does not even support the case
feature!

http://www.python.org/dev/peps/pep-3103/

Status: rejected!

Funny stuff!


Funny stuff - I did exactly what you asked, but instead you completely dismissed that and focused on whatever you could to make it seem like Python sucks. Evidence to the contrary has been given since then, so I shall leave it at this.

Hey why don't show us what this looks like in python:


Done so in previous post and as also been improved by Wizzup?


Try making sense next time.


I think it made perfect sense - people who produce scripts may want to download or store large pieces of data that could benefit from being compressed. Having the script decompress it is just a bonus for making it easier for the end user.


Post it.

You can find it at http://python.org



Congratz!

That's only been discussed three times in the past 7 posts!

We already know it only works with primitives! Way to point out the obvious, to bad three people (including me) already beat you to it ::thumbsup:

Oh wait, we already have anything that is InArr<Type> here already premade either in SRL or SCAR/simba so yea kinda a stupid point to make.


Then why do you still support it as a point? Is having several different functions that do the exact same thing (check if something is in an array) make a language any more readable?


Anyway, it seems other people may be getting annoyed with the mass debating. Possibly we should tone it down a little, or not - your choice really.


To target the broader people, I would be up for changing to just about any interpreted language around, but Python seems like the best choice to me. Perl being another big one is quite a lot more difficult to follow (I commonly refer to it as being obfus'd Python - others may not) and Ruby is a silly language (ask Craig` on IRC). Lisp, while being loved by Yakman, does have a very different syntax compared to Pascal. I'm sure there are countless others you could name, but I don't think any of them would be as user friendly as Python is nor as similar to PascalScript too.

Sure, I would love to ask everyone what one they wanted to use, but I would also think it's important that they make a fair decision. However, is it just enough that they choose their favourite or is it important they choose the one they think is easiest for new people to learn or existing scripter to change to? If you are to propose a community (or just Members) wide poll, then please don't rush into and think about what exactly you want to ask.

c0de

2010-04-11 12:01:20

From: mixster

To target the broader people, I would be up for changing to just about any interpreted language around, but Python seems like the best choice to me. Perl being another big one is quite a lot more difficult to follow (I commonly refer to it as being obfus'd Python - others may not) and Ruby is a silly language (ask Craig` on IRC). Lisp, while being loved by Yakman, does have a very different syntax compared to Pascal. I'm sure there are countless others you could name, but I don't think any of them would be as user friendly as Python is nor as similar to PascalScript too.

Sure, I would love to ask everyone what one they wanted to use, but I would also think it's important that they make a fair decision. However, is it just enough that they choose their favourite or is it important they choose the one they think is easiest for new people to learn or existing scripter to change to? If you are to propose a community (or just Members) wide poll, then please don't rush into and think about what exactly you want to ask.


Ruby is an awesome language (and I'm pretty sure Craig` would tell you that as well), it's just that Wizzup doesn't agree with that. Let's face it, you like Python because Wizzup hyped it up for you… Give a Ruby try without any prejudices and you'll see what I mean…

mixster

2010-04-11 12:04:42

It's nice of you to assume that Wizzup? dictates my life - I actually first tried Python a year or two ago at R0b0t1's suggestion as well as trying Perl as Jason2gs told me to and as many other ones as I could as I wanted to expand my experience beyond Pascal (which did include Ruby). Python was my favourite out of the ones I did try, though I didn't do much more than a couple of basic tutorials. Oh and the Craig` reference is somewhat a joke as he does use it and gets annoyed if you tell him it's silly.

Method

2010-04-11 12:18:16

From: mixster
Just want to point you to Method's post here which clearly does say that him learning Java helped him become awesome… oh no wait, it doesn't. But wait, he posted again here where he said that learning general Java probably won't be enough and say `that is nothing close to the amount required to build an updater and look through the client for fields you're interested in (and then to build patterns to locate those fields across client revisions).' - yeah, quite a supportive view for you. After that, you then have HyperSecret here talking about him learning Java in no way enabled him to help with reflection at all. True, he does say he would like to try again after Java classes.


From what I can tell, this post is trying to take what I said out of context and make it something negative.

Learning Java did help me build an updater to help maintain our reflection implementation. However, like I said, learning enough Java to write a script for a bot like RSBot, iBot, KBot, etc. is not nearly enough to write an updater. Much more has to be understood (the API of one of the bytecode libraries, bytecode itself, the RuneScape client, etc.), which is why I mentioned how that small amount of Java learned is minor compared to what is required.

And of course nobody else has been able to fix reflection - nobody has invested the time I did to learn Java, study the client, and work to build and fix my updater as the updates rolled out. Without that effort, which could be achieved by multiple intelligent, interested people in a shorter time, there will not be any results. This can be clearly seen with reflection's current state. Only a few people are working on it, and none of them are really working together to solve the problems.

Dan Cardin

2010-04-11 12:28:48

From: c0de
Try to narrow it down to two with a poll, then have a poll for those two. At least ask the public what they think and want :)

it will still end up with the same problem.

First round - c++ vs python, 30% vs 70%.
Second Round - python vs pascal, 30% vs 40%
Pascal wins.

You still end up with 60% that don't want pascal. Opening it up to many languages is silly because it really ought to still be interpreted languages to retain its actual similarities with the actual community. Keep things as is unless someone else feels the need to implement a different language themself. Then if people like it, general integration can take place.

Town

2010-04-11 12:39:49

This thread has taken a pretty significant turn in the past 12 hours.

I wouldn't mind a battle-royal discussion of languages. We've been through the advantages and disadvantages of Python and Pascal, more than anyone would have liked, and have touched on Java.

Is there anyone in particular rooting for a change to Ruby/Perl/C/etc that would like to make a coherent explanation of why they are better for our purposes? Otherwise, we'll probably be at a standstill for another 8 pages.

mixster

2010-04-11 12:47:22

From: Method
From what I can tell, this post is trying to take what I said out of context and make it something negative.


I'm sorry, but I did see it as quite a negative post regarding learning Java leading to fixing reflection and I see the rest of your post as that too. It still seems to be that you're saying learning basic Java isn't enough - only learning a crap load of specific Java would be. I'm not denying that you have to learn Java initially to get to that goal - I'm saying that teaching a lot of people a little bit of Java will not mean that suddenly there will be a group of people with enough skill and the like to fix reflection and keep it up to date forever.

Method

2010-04-11 13:12:00

From: mixster
It still seems to be that you're saying learning basic Java isn't enough - only learning a crap load of specific Java would be.


If by specific you mean actually learning the fundamentals behind the language instead of using one specific API (that of one of the popular RuneScape bots), then yes, you will need to learn a lot of "specific Java". Learning Java is more than just making a script for a bot that requires little work to be effective.

From: mixster
I'm not denying that you have to learn Java initially to get to that goal - I'm saying that teaching a lot of people a little bit of Java will not mean that suddenly there will be a group of people with enough skill and the like to fix reflection and keep it up to date forever.


Was anyone even debating this? Of course people with little Java experience couldn't maintain an updater to get our reflection implementation up-and-running again…

Wizzup?

2010-04-11 13:46:59

From: Town
This thread has taken a pretty significant turn in the past 12 hours.

I wouldn't mind a battle-royal discussion of languages. We've been through the advantages and disadvantages of Python and Pascal, more than anyone would have liked, and have touched on Java.

Is there anyone in particular rooting for a change to Ruby/Perl/C/etc that would like to make a coherent explanation of why they are better for our purposes? Otherwise, we'll probably be at a standstill for another 8 pages.


If we want to bundle the language with Simba/SRL, then we will need an interpreted language. So compiled C is out of the question. If you want to preserve ANY kind of readability, then I would suggest to stay away from Ruby. I guess the same goes for Perl.

(Random benchmarks)
http://shootout.alioth.debian.org/u32q/benchmark.php?test=all&lang=python&lang2=jruby
http://shootout.alioth.debian.org/u32q/benchmark.php?test=all&lang=python&lang2=perl

senrath

2010-04-11 16:37:50

From: Dan Cardin
it will still end up with the same problem.

First round - c++ vs python, 30% vs 70%.
Second Round - python vs pascal, 30% vs 40%
Pascal wins.

You still end up with 60% that don't want pascal. Opening it up to many languages is silly because it really ought to still be interpreted languages to retain its actual similarities with the actual community. Keep things as is unless someone else feels the need to implement a different language themself. Then if people like it, general integration can take place.


That's not how it would be. It would be more like:
First round: Python vs Java vs Pascal, x% vs y% vs z%
Second round: Winner 1 vs Winner 2 of the first round.

Dan Cardin

2010-04-11 20:19:02

From: Town
This thread has taken a pretty significant turn in the past 12 hours.

I wouldn't mind a battle-royal discussion of languages. We've been through the advantages and disadvantages of Python and Pascal, more than anyone would have liked, and have touched on Java.

Is there anyone in particular rooting for a change to Ruby/Perl/C/etc that would like to make a coherent explanation of why they are better for our purposes? Otherwise, we'll probably be at a standstill for another 8 pages.
Perl is confusing, Ruby has rails and something akin to C++script i know nothing about. We could program in javascript, but that's basically C, and other such languages, but really, most languages are so much alike that it barely even matters. Which is why this whole thread barely even matters other than to make people look silly and misinformed.

From: senrath
That's not how it would be. It would be more like:
First round: Python vs Java vs Pascal, x% vs y% vs z%
Second round: Winner 1 vs Winner 2 of the first round.

you'd still and always end up with the losers (in this case lets say the 30% = y%) that have to pick between two languages that they don't want, so in any case, if there is actually any competition in these votes, then the votes will fail and if there isn't then the votes are pointless. Either way, its a lose, so one might as well not have a vote. Then after that whoever feels like they are left out and want to go programming in whatever interpreted language they want, they can go implement it themselves. The main focus for the SRL devs should be developing SRL, not completely changing it simply to make changes that will barely matter in the grand scheme of things (as i think it indeed is). The people that chose to go about implementing python and Ruby can do so, and if it garners enough support, it might be in the best interests of SRL as an community, to include them. Until then, its a rather moot point.

Wanted

2010-04-11 22:49:18

From: The Claw
This post* is fucked


Fixed :)

From: mastaraymond
Really; You cannot say 'Pascal > Python' without having tried it, that's a biased call. However that's not the issue here.. I'm sure it was Icefire's intention to just say "Don't switch programming language" however this general argument failed so the topic went down to bitching at python which is fucking irrelevant.

Besides I see no reason to 'block' this language out? Just let them Python guys do there thing, it's not like they actively develop SRL in it's current Pascal-state.. So who gives a damn what they do? It's not like there is any intention to 'erase' pascal from SRL? If there is a group of people who want to switch to another language, let them be? It's not like SRL isn't big enough for these kind of developments… On the contrary, it might actually improve SRL as a community..


I only looked through most of python2&3 manuals, sure maybe I didn't pick up everything in the dam thing. But what more must I do to "try it" convert every function I need to work in python then write a script totally in python just so I can run into the exact same problems on python that I do in pascal like failed randoms, script bugging up, OCR not working ect. ect. ?

Yea let the 'python people' do what they want, I'm not stopping them… I'm just pointing out what a unneeded use of time it is for everyone else to have to live with it involving the SRL include.

There might not be intentions to "erase" pascal from SRL, but there are intentions to

  • Erase SCAR
  • Promote Simba in every single way possible
  • Crush anyone who disagrees
  • And do what ever you can to justify it

Switching to python would be a big plus +1 for simba right?

Don't believe me, I can dig up plenty of quotes from around the forum that prove every statement and I've said and more on these 'intentions'.

From: Wizzup?
Actually, it does support cases, it just doesn't have a keyword for them, as that's not really required to do a case statement;
if & elif are quite fine as they are. (Nice going checking the language spec again, Icefire)
They are also easily recreated using Python's o-so-powerful hashmap. (It really is one of the world's top 5.)


>>> {'VWB' : [1, 0.12, 0.29, MSX1, MSCY, 2443092, 5, 30, 30, 150],
'VEB' : [0, 0.11, 1.70, MSCX, MSCY, 2115671, 5, 30, 30, 100],
'AKB' : [0, 3.40, 0.84, MSCX, MSCY, 7435867, 14, 15, 30, 200],
'EB' : [0, 0.34, 0.99, MSCX, MSCY, 4216161, 1, 35, 35, 75]}['VWB']
[1, 0.12, 0.28999999999999998, 0, 0, 2443092, 5, 30, 30, 150]


import sys, time, random

class TPoint(object):
def __init__(self, x=0, y=0):
self.x = x
self.y = y

class TPlayer(object):
def __init__(self, strs=[]):
self.Strings = strs
self.Banked = 0

def Loggedin():
return True

def Between(st, en, inp):
s = inp.find(st) + len(st)
e = inp.find(en, s)
if (s == len(st) - 1) or (e == -1):
return ''
else:
return inp[s:e]

def ColorToleranceSpeed(x):
return

def SetColorSpeed2Modifiers(x, y):
return

def FindColorsSpiralTolerance(x, y, tpa, color, x1, y1, x2, y2, tol):
tpa = [TPoint(), TPoint(5, 5), TPoint(10, 0)]
return True

def TPAToATPAEx(TPA, w, h):
return [TPA]

def SortATPAFromFirstPoint(ATPA, Point):
return ATPA

def MiddleTPA(tpa):
return tpa[0]

def MMouse(x, y, rx, ry):
return

def Mouse(x, y, rx, ry, click):
return

def CountColorTolerance(c, x1, y1, x2, y2, t):
return 42

def GetMousePos(x, y):
return TPoint(x + 5, y - 7)

def ChooseOptionMulti(x):
return True

def FFlag(x):
return

def PinScreen():
return False

def InPin(x):
return

def ClickToContinue():
return

def BankScreen():
return True

def OpenBankFast(bank):
return True

def LogOut():
return

def OpenBankIce():
if not Loggedin():
return False
Bank = Between('(', ')', Players[CurrentPlayer].Strings[1])
if Bank == 'VWB':
BankInfo = [1, 0.12, 0.29, MSX1, MSCY, 2443092, 5, 30, 30, 150]
elif Bank == 'VEB':
BankInfo = [0, 0.11, 1.70, MSCX, MSCY, 2115671, 5, 30, 30, 100]
elif Bank == 'AKB':
BankInfo = [0, 3.40, 0.84, MSCX, MSCY, 7435867, 14, 15, 30, 200]
elif Bank == 'EB':
BankInfo = [0, 0.34, 0.99, MSCX, MSCY, 4216161, 1, 35, 35, 75]
else:
return False # Really just a failsafe to ensure Python doesn't crash when passed an invalid bank as you don't check that

print('Opening ' + Bank + '...')

res = False
for Re in range(0, BankInfo[0]):
ColorToleranceSpeed(2);
SetColorSpeed2Modifiers(BankInfo[1], BankInfo[2]);
TPA = []
FindColorsSpiralTolerance(BankInfo[3], BankInfo[4], TPA, BankInfo[5], MSX1, MSY1, MSX2, MSY2, BankInfo[6]);
SetColorSpeed2Modifiers(0.2, 0.2);
ColorToleranceSpeed(1);
if len(TPA) > 0:
TPAA = TPAToATPAEx(TPA, BankInfo[7], BankInfo[8])
SortATPAFromFirstPoint(TPAA, TPoint(BankInfo[3], BankInfo[4]))

for curTPA in TPAA:
if len(curTPA) < BankInfo[9]:
continue
OB = MiddleTPA(curTPA)
MMouse(OB.x, OB.y, 1, 1)
time.sleep(0.2 + (random.random() * 0.05))
use = []
if CountColorTolerance(14342657, 7, 7, 100, 25, 70) > 150:
use = ['quick', 'uick', 'uic']
elif CountColorTolerance(648165, 7, 7, 100, 25, 50) > 100:
use = ['ank B', 'nk B', 'k Ba']
if len(use) > 0:
OB = GetMousePos(OB.x, OB.y)
Mouse(OB.x, OB.y, 0, 0, False)
time.sleep(0.2 + (random.random() * 0.05))
if not ChooseOptionMulti(use):
continue

FFlag(0)
t = time.clock() + 6
while time.clock() < t:
time.sleep(0.1 + (random.random()*0.05))
if PinScreen():
InPin(Players[CurrentPlayer].Strings[0])
time.sleep(2 + (random.random() * 0.2))
ClickToContinue()
if BankScreen():
res = True
break
if res:
break
if not res:
if (Re == 0) and (Bank == 'VWB'):
Mouse(MMCX, MMCY - 10, 0, 0, True)
FFlag(0)
time.sleep(1 + random.random())
else:
res = OpenBankFast(Bank)
if res:
print('Opened ' + Bank + ' using OpenBankFast.')
if res:
print('Opened ' + Bank + '.')
Players[CurrentPlayer].Banked += 1
# Insert some other incs here
return res
print('Failed to open ' + Bank + ', logging out...')
LogOut()
return False

def Test(a):
a.x += 1

Players = [TPlayer(['', '(VWB)'])]
CurrentPlayer = 0
MSX1, MSY1 = 0, 0
MSCY = 0
MSX2, MSY2 = 0, 0
MMCX, MMCY = 0, 0
random.seed()
OpenBankIce()


Hey everyone what is easier to read?

This


>>> {'VWB' : [1, 0.12, 0.29, MSX1, MSCY, 2443092, 5, 30, 30, 150],
'VEB' : [0, 0.11, 1.70, MSCX, MSCY, 2115671, 5, 30, 30, 100],
'AKB' : [0, 3.40, 0.84, MSCX, MSCY, 7435867, 14, 15, 30, 200],
'EB' : [0, 0.34, 0.99, MSCX, MSCY, 4216161, 1, 35, 35, 75]}['VWB']
[1, 0.12, 0.28999999999999998, 0, 0, 2443092, 5, 30, 30, 150]

or this

  case Bank of
'VWB': BankInfo := [1, 0.12, 0.29, MSX1, MSCY, 2443092, 5, 30, 30, 150];
'VEB': BankInfo := [0, 0.11, 1.70, MSCX, MSCY, 2115671, 5, 30, 30, 100];
'AKB': BankInfo := [0, 3.40, 0.84, MSCX, MSCY, 7435867, 14, 15, 30, 200];
'EB': BankInfo := [0, 0.34, 0.99, MSCX, MSCY, 4216161, 1, 35, 35, 75];
end;


and

this

case Random(100) of
0..25: WriteLn('bottom quarter');
26..50: WriteLn('third quarter');
51..75: WriteLn('second quarter');
76..100: WriteLn('first quarter');
end;

or this

import random

r = random.randrange(100)
if r in range(0, 25):
print('bottom quarter')
elif r in range(26, 50):
print('third quarter')
elif r in range(51, 75):
print('second quarter')
elif r in range(76, 100):
print('first quarter')

s = 'a'
if s in 'abcdefghijk':
print('lmaooo!')

I think it's pretty obvious, but to confuse everyone I'll say it's better to use python now instead of more readable in pascal… which was the focus in the first place =/

From: mixster
So we still use PascalScript, but tell everyone to go learn Java? Please, I asked you to tell me your stance for this very reason and you said `Stick with PascalScript, learn Java over Python' and I then said why Java is a pretty horrible language for macroing, but you meant just like, learn both at the same? The problem with that being people who have wanted to fix reflection have kind of tried to and I don't think many succeeded. So if people who want to do it failed, why would the average Joe scripter who doesn't really want to be able to do it?


Yes we still use Pascal, because it's already very fluent in a very very very large percentage of the population of SRL.

And we spend our time learning Java instead of Python, not so we can "macro with it" what ever the hell that means, and use that knowledge to pursue Reflection and understanding the Runescape client.

@Lasttwosentances

Ok in that case, what makes you think 'average joe' is gonna go, omfg python

*starts over his knowledge*

only to come out with a product in the end where none of his original problems where solved by switching, his bank still fails every 15 trys, randoms don't really work to well… and the auto responder isn't timed right.

But it's all better now! It's written in Python!

Wtf?

From: mixster
Sure I agree, having a Java-fluent community would most likely lead to reflection being more permanently fixed, but why would the whole community learn Java when they're already learning PascalScript and Java wouldn't actually allow them to macro?


It doesn't sound like you agree in the other above quote box, but hey I'm not here to question your sense of surroundings so I'll just ignore that.

Having Java-fluency would push SRL over the top, and make it better than any other runescape cheating community ever made, and would attract more people, and ultimately the increase in people would push every aspect of SRL over the top.. where switching to python has the potential to do serious damage to a lot of aspects of SRL.. including activity and likability, as well as user friendliness.. but hey… who cares about the "what-if-ers" anyways right?

Lol Java wouldn't allow them to macro, only open up the source code to RS and maybe actually pick up on a few things….


From: mixster
Why can't they include the whole thing? But anyway, useful parts of the library are improved mouse functions, improved typing functions, the Object.scar file has multiple FindObject's that can are pretty useful if you remove the UpText checking. Color.scar has some general use wrappers for harder to use functions and a couple of nice general use functions (GetBestColor for example). Text.scar has the explode and implode for older Scar versions as well as a few like InStrArr and others rearranging those words. Timing.scar has a few expansions to Scar's normal time functions.


Heres a clue, because on my computer SRL slows it the hell down… there's so much unneeded (not even working) junk dead and buried being compiled it takes 9001 m-seconds just to compile my firemaker when it only takes 100 ms to compile no includes at all.

Are you seriously trying to tell me that if you removed uptext from FindObj you could some how use it to find crap in other things not runescape related? Wow…. that just made my day.

Sure there may be a few things you would need out of SRL… but no one is going to make a script for Eve online and include the entire SRL and be like "ah shit it's written in Pascal… I wish it were python!!!! :( :duh: )


From: mixster
It may not be overly much, but it is a lot of useful additions to Scar. Then there's also all the neat stuff in WizzyPlugin (yes that is part of SRL - it comes with SRL's plugins) that's pretty useful if you plan on doing anything serious.


You don't need to include SRL to use things in any plugin, in fact, but you probably already knew that. =/

From: mixster
Anyway, I in no way suggested they were a majority, but I do think that dismissing them because they don't auto is out of hand as they are still members of the community.


I'm dismissing "them" as they (people not using SRL include) to tell people (using SRL include) that SRL include will be written in this language. When people who use SRL include should decide, and not people who don't use it at all.

Either way it's not even close to a majority, so it will never fly… it's just the fact that you something outlandish like that and knew it was made my laugh and I couldn't resist posting a picture of a collideascope as I though it displayed what you said perfectly.

Hey we can't have a sense of humor? We're all friends here.



From: mixster
The idea of using Python for Runescape macroing is almost as far out and crazy as using PascalScript to do it!


LOL ok.

Especially when people are already fluent in one and not the other.

Let's write the SAT in Spanish too.



From: mixster
This hasn't been about telling you to use it, but trying to show you why I think it would be beneficial to use it rather than PascalScript (something which is less clear when you see how far the debate has come).


So far, I've seen absolutely nothing in this thread worth my while to use python over pascal when making a runescape script.

Absolutely nothing.



From: mixster
If am indeed correct with my above thought that you want to encourage learning Java alongside PascalScript, then indeed that would make what I said wrong.


That is correct…. the last part anyways… because from what I've seen so far I have no idea what to interpret that first part of your sentence to mean so I'm not going to.



From: mixster
Just want to point you to Method's post here which clearly does say that him learning Java helped him become awesome… oh no wait, it doesn't. But wait, he posted again here where he said that learning general Java probably won't be enough and say `that is nothing close to the amount required to build an updater and look through the client for fields you're interested in (and then to build patterns to locate those fields across client revisions).' - yeah, quite a supportive view for you. After that, you then have HyperSecret here talking about him learning Java in no way enabled him to help with reflection at all. True, he does say he would like to try again after Java classes.


I'd just like to post them here to make them more readable

From: Method
Well, you'd need some basic knowledge of Java involving methods, fields, variables, the API, etc. to make a script for iBot or one of the other Java bots, but that is nothing close to the amount required to build an updater and look through the client for fields you're interested in (and then to build patterns to locate those fields across client revisions).

edit: That's one of the reasons why botting (and private server) communties are so poor. People learn just enough to get by and don't take the time to really learn the language to investigate further applications of it.


From: HyperSecret
I was able to write a script for iBot, RSBot, etc… before taking any java classes and was not able to make an updater or anything to really help with reflection (on the java side).

I really want to try again since I took a Java class.


From: Method
If by specific you mean actually learning the fundamentals behind the language instead of using one specific API (that of one of the popular RuneScape bots), then yes, you will need to learn a lot of "specific Java". Learning Java is more than just making a script for a bot that requires little work to be effective.



Was anyone even debating this? Of course people with little Java experience couldn't maintain an updater to get our reflection implementation up-and-running again…


From: mixster
I'm sorry, but I did see it as quite a negative post regarding learning Java leading to fixing reflection and I see the rest of your post as that too. It still seems to be that you're saying learning basic Java isn't enough - only learning a crap load of specific Java would be. I'm not denying that you have to learn Java initially to get to that goal - I'm saying that teaching a lot of people a little bit of Java will not mean that suddenly there will be a group of people with enough skill and the like to fix reflection and keep it up to date forever.


From: HyperSecret
It would probably be just as easy to learn if we have the same type of tutorials for it as we do for using Pascal. I have never written anything in Pascal outside of using it with SCAR.

So if we had the tutorials to teach people how to use Python directed towards Runescape autoing, just like we do Pascal here, I would assume people would be able to pick it up just as easily.


I think that about sums it up. And hyper sceret, from Methods' explanation on what he had to do to understand the client, sounds like hyper didn't go to far with it.


From: mixster
Since when does PascalScript help you understand the Runescape client? SRL has actually never been about understanding it or using reflection at all - it was an unofficial side project of a group of people. Why Python over PascalScript? For all the reasons that have been said that you have dismissed as `false' for reasons only known to you.


Since when does Python. I have never said PascalScript helps you understand the client, only Java.. You have clearly misread my post. Try again.

"Reasons only known to me" I seriously lol'd at that one.

I've yet to see any great advantage for runescape macroing by using python, only that Wizzup said there was… and could not produce one.

So maybe you were talking about Wizzup and somehow put my name in there.



From: mixster
The claim I was referring to was actually the bit right before that - `With every ounce of my reasoning behind me, I can only see Java as a good move if SRL were to only auto RS and use a client like Smart (similar to RSBot and co).'
That did indeed have support - the previous few paragraphs. I'll put this little slip-up down to a mistake and not you purposely picking the weaker one and then assuming what I said only referred to that to make it easier for you to break it.


I'm sorry but, wtf are you talking about… SMART already grabs reflection hooks.. thats all pascal based functions need (in combination with understanding the Runescape source code "I-kno-crazy-ritee?") to get the maths right in pascal.

I can't really make sense of your post right there for some reason.

From: mixster
Anyway, as you did want to focus on that, it's because Scar & Simba are very much general macroers, but by switching to Java you would indeed make them very different products for the reasons I stated.


Who said anything about switching ANYTHING to Java?

I said it would be more helpful to pursue Java than Python, and it is.

You're still a very confused person.



From: mixster
Because making a silly joke some how makes my defence of producing a functioning Python equivalent of a PascalScript script that doesn't relate to RS any less important? The main point of the script anyway was to show you how similar the general syntax is - I bet if you looked at them side by side you could easily match up the same lines and read one just as easily as the other. Oh and for the record, my script was SRL Include related as it downloaded it :)


Downloading SRL does not make it include related because it does not use the include, it distributes it. Nice sarcasm.

Anyways that's only if you have both side by side to compare, otherwise it's jibberish to anyone who doesn't know python.



From: mixster
Funny stuff - I did exactly what you asked, but instead you completely dismissed that and focused on whatever you could to make it seem like Python sucks. Evidence to the contrary has been given since then, so I shall leave it at this.


Evidence above~ =)

I'll accept your challenge from earlier as well, but I'll probably have some outside help from one of my buddies that is good at python, if that's not against the rules.


From: mixster
Done so in previous post and as also been improved by Wizzup?


And refuted this too about 5 quotation boxes ago.


From: mixster
I think it made perfect sense - people who produce scripts may want to download or store large pieces of data that could benefit from being compressed. Having the script decompress it is just a bonus for making it easier for the end user.


Sorry but that's just absolutely retarded on so many levels.


From: mixster
You can find it at http://python.org


you mean python.com ? ;)




From: mixster
Then why do you still support it as a point? Is having several different functions that do the exact same thing (check if something is in an array) make a language any more readable?


Because the original connotation of that entire discussion between me and Wizzup was "show me python being more readable" and posted the source of InIntArr compared to python doing it with the in word. But seriously… all those are already premade for every type you need… InStrArr, InStrArr… even better because they actually return an index where it was found! Which is about the only useful part of it even!

The entire discussion was over readability and became about which one is better… which was never a point made in the opposite direction.

I like how I was the first one to point out they were called primitives, yet 4 people basically copied and pasted each other shortly afterwords like I had no idea what I was talking about. Seriously made me facepalm. Especially after wasting hours trying to debunk this dam thread.


From: mixster
Anyway, it seems other people may be getting annoyed with the mass debating. Possibly we should tone it down a little, or not - your choice really.


I could honestly give a shit if people are annoyed. Everyday I sign in to SRL with out being able to check daily posts without seing "God is imaginary" or some other crap along those lines. Me debating over Python, compared to seeing threads with titles like "why do people hate pedophiles" "Belief in miracles in contradictory to science" same goes for the IRC. And the atheists signatures aswell.

No one cares that you hate God… get over yourselfs and tell someone who gives a shit.

So really… truly… I'm not complaining about the above neither should people complain about me posting.

Sorry for going offtopic

Back on topic!

A lot of that was not directed at you… if not all of it. :)


From: mixster
To target the broader people, I would be up for changing to just about any interpreted language around, but Python seems like the best choice to me. Perl being another big one is quite a lot more difficult to follow (I commonly refer to it as being obfus'd Python - others may not) and Ruby is a silly language (ask Craig` on IRC). Lisp, while being loved by Yakman, does have a very different syntax compared to Pascal. I'm sure there are countless others you could name, but I don't think any of them would be as user friendly as Python is nor as similar to PascalScript too.


@above

From: c0de
Ruby is an awesome language (and I'm pretty sure Craig` would tell you that as well), it's just that Wizzup doesn't agree with that. Let's face it, you like Python because Wizzup hyped it up for you… Give a Ruby try without any prejudices and you'll see what I mean…

What he said^^

From: mixster
Sure, I would love to ask everyone what one they wanted to use, but I would also think it's important that they make a fair decision. However, is it just enough that they choose their favourite or is it important they choose the one they think is easiest for new people to learn or existing scripter to change to? If you are to propose a community (or just Members) wide poll, then please don't rush into and think about what exactly you want to ask.


From: Wizzup?
If we want to bundle the language with Simba/SRL, then we will need an interpreted language. So compiled C is out of the question. If you want to preserve ANY kind of readability, then I would suggest to stay away from Ruby. I guess the same goes for Perl.

(Random benchmarks)
http://shootout.alioth.debian.org/u32q/benchmark.php?test=all&lang=python&lang2=jruby
http://shootout.alioth.debian.org/u32q/benchmark.php?test=all&lang=python&lang2=perl


From: Dan Cardin
Perl is confusing, Ruby has rails and something akin to C++script i know nothing about. We could program in javascript, but that's basically C, and other such languages, but really, most languages are so much alike that it barely even matters. Which is why this whole thread barely even matters other than to make people look silly and misinformed.


you'd still and always end up with the losers (in this case lets say the 30% = y%) that have to pick between two languages that they don't want, so in any case, if there is actually any competition in these votes, then the votes will fail and if there isn't then the votes are pointless. Either way, its a lose, so one might as well not have a vote. Then after that whoever feels like they are left out and want to go programming in whatever interpreted language they want, they can go implement it themselves. The main focus for the SRL devs should be developing SRL, not completely changing it simply to make changes that will barely matter in the grand scheme of things (as i think it indeed is). The people that chose to go about implementing python and Ruby can do so, and if it garners enough support, it might be in the best interests of SRL as an community, to include them. Until then, its a rather moot point.


@ the above posts.

The polling sounds like the right thing to do.

But the main problem is that you have to make it clear exactly what you are posting.

I don't think anyone is against simba supporting python, it's SRL 5 or ect. being written in python ect..

So if you do poll be sure to be very very specific so there is no confusing (like there is clearly in this thread)

I'd also like to say that any polling problems can be solved by making every round after it is narrowed down giving the "Neither" option and requiring that at least 50% (or you can make it 66.7% like in congress) be reached to say that any decision was fairly made.

Wizzup?

2010-04-12 03:26:07

From: IceFire908
Hey everyone what is easier to read?


Are you tense?

From: IceFire908

This


>>> {'VWB' : [1, 0.12, 0.29, MSX1, MSCY, 2443092, 5, 30, 30, 150],
'VEB' : [0, 0.11, 1.70, MSCX, MSCY, 2115671, 5, 30, 30, 100],
'AKB' : [0, 3.40, 0.84, MSCX, MSCY, 7435867, 14, 15, 30, 200],
'EB' : [0, 0.34, 0.99, MSCX, MSCY, 4216161, 1, 35, 35, 75]}['VWB']
[1, 0.12, 0.28999999999999998, 0, 0, 2443092, 5, 30, 30, 150]

or this

  case Bank of
'VWB': BankInfo := [1, 0.12, 0.29, MSX1, MSCY, 2443092, 5, 30, 30, 150];
'VEB': BankInfo := [0, 0.11, 1.70, MSCX, MSCY, 2115671, 5, 30, 30, 100];
'AKB': BankInfo := [0, 3.40, 0.84, MSCX, MSCY, 7435867, 14, 15, 30, 200];
'EB': BankInfo := [0, 0.34, 0.99, MSCX, MSCY, 4216161, 1, 35, 35, 75];
end;


I think it's pretty obvious, but to confuse everyone I'll say it's better to use python now instead of more readable in pascal… which was the focus in the first place =/


I'm not sure if you understand the flexibility of the piece of code I pasted. A dict can contain any string, and contain any related result. It is also dynamic so you can add or remove items on the fly, which (for example) allows you to do dynamic cases. And yeah, if I use the ``location'' case statement at multiple places it will surely be more readable.


# Better use tuples for the info, but we'll lists for now I guess.
BankInfos = {'VWB' : [1, 0.12, 0.29, MSX1, MSCY, 2443092, 5, 30, 30, 150], \
'VEB' : [0, 0.11, 1.70, MSCX, MSCY, 2115671, 5, 30, 30, 100], \
'AKB' : [0, 3.40, 0.84, MSCX, MSCY, 7435867, 14, 15, 30, 200], \
'EB' : [0, 0.34, 0.99, MSCX, MSCY, 4216161, 1, 35, 35, 75]}

def doSomething(bank):
myinfo := BankInfos[bank]

# Add another bank.
BankInfos['FDR'] = [1, 0.12, 0.29, MSX1, MSCY, 2443092, 5, 30, 30, 150]

# You can also print all items in it.
for key, item: in BankInfos.iteritems():
print key, item
print BankInfos
print BankInfos.keys()
print BankInfos.values()

if BankInfos.has_key('FDR'):
print 'Has FDR key'

Whereas in Pascal you'd be doing the case all over again. Assuming you want to use the banks elsewhere, it would be really simple to see how this is definitely an advantage. You can use and store the bank data dynamically, access it in several ways, and you can reuse it in (other) cases.

From: IceFire908

and

this

case Random(100) of
0..25: WriteLn('bottom quarter');
26..50: WriteLn('third quarter');
51..75: WriteLn('second quarter');
76..100: WriteLn('first quarter');
end;

or this

import random

r = random.randrange(100)
if r in range(0, 25):
print('bottom quarter')
elif r in range(26, 50):
print('third quarter')
elif r in range(51, 75):
print('second quarter')
elif r in range(76, 100):
print('first quarter')

s = 'a'
if s in 'abcdefghijk':
print('lmaooo!')


Or perhaps this…


#!/usr/bin/env python

a = ("watwatinthebutt",lol)

if type(a) == str:
print 'a is a string'
elif a in range(0,100):
print 'a is in range 0-100'
elif type(a) == list:
print 'a is a list'
elif a in ['This is a string', 42]:
print 'a is in the previously seen list'
else:
print 'a is ', type(a), 'with value ', repr(a)

Sorry, couldn't create a pascal example. Cases are limited in so many ways it not funny any more. What about a case where a is a number somewhere in the range of 0, 100 (like previously used), and b is another number, ranging from 0, 1000? Can you create a readable case in pascal that handles all/both, flexibly?

Thanks. There's a reason Python belongs to the scripting languages whereas Pascal is statically typed, and usually not fit for scripting purposes. (Yes, Java too.)

"I think it's pretty obvious, but to confuse everyone I'll say it's better to use pascal now instead of more readable in python… which was the focus in the first place =/"

Dan Cardin

2010-04-12 06:57:27

you ignored my python post in response to your case :(.

And didnt get the point of my polling one. If you actually garner any support for one of the programming languages and it loses, then you'll still end up with people disappointed (possibly a fairly large percentage). I can see python gaining support just because Wizzup? supports it (just like Simba in some ways), so what happens if that beats out pascal? silly in general. The two options that I see as viable are not having polling, and allowing people that want to do new ones to do so. Or doing polling (allowing pollees to choose as many as they want, then having the devs do all the popular ones. To me, it makes much more sense to do the first because
1. you dont have the majority of the community going based on who supports it rather than the actual language. They can try it out, then see if they like it.
2. The devs won't be doing something completely unrelated to SRL
3. no one is left out. If someone feels strongly enough about doing something, they can.

Wizzup?

2010-04-12 07:26:50

From: TRiLeZ
I agree with Naum. If you're going to change SRL's programming language, you should let us together, as a community to vote on whether or not to change SRL's programming language and if we decide to change the programming language, then we should decide which language it should be. You shouldn't be the one who makes all of the decisions for us.

Are you going to be the one who is going to do all of the coding for SRL? Or are you going to be the one making all of the scripts? NO. When was the last time that you, Wizzup, made a script? Don't you think that the people of SRL should vote?

Don't turn SRL into Jagex, changing RuneScape because they thought that it would improve it, and thought that it was best for it's users. Many RuneScape players are quitting because of Jagex's choices. Did Jagex ever ask their players before changing RuneScape? No. Did you ask this community before deciding to change SRL to Python? No. So, don't make SRLers quit because of your actions, ask the community before you try changing SRL up.


There's no need to act like this. I started with a script several times, but pascal annoyed me so much I often quit shortly after. Perhaps if you read the thread you'd know that this is only an idea I tossed up rather than some *new* direction that we *must* go and follow, which quite some of you seem to assume. I'm only defending the possibility of the idea working out well.

Wanted

2010-04-12 10:38:11

From: Wizzup?
Are you tense?



I'm not sure if you understand the flexibility of the piece of code I pasted. A dict can contain any string, and contain any related result. It is also dynamic so you can add or remove items on the fly, which (for example) allows you to do dynamic cases. And yeah, if I use the ``location'' case statement at multiple places it will surely be more readable.


# Better use tuples for the info, but we'll lists for now I guess.
BankInfos = {'VWB' : [1, 0.12, 0.29, MSX1, MSCY, 2443092, 5, 30, 30, 150], \
'VEB' : [0, 0.11, 1.70, MSCX, MSCY, 2115671, 5, 30, 30, 100], \
'AKB' : [0, 3.40, 0.84, MSCX, MSCY, 7435867, 14, 15, 30, 200], \
'EB' : [0, 0.34, 0.99, MSCX, MSCY, 4216161, 1, 35, 35, 75]}

def doSomething(bank):
myinfo := BankInfos[bank]

# Add another bank.
BankInfos['FDR'] = [1, 0.12, 0.29, MSX1, MSCY, 2443092, 5, 30, 30, 150]

# You can also print all items in it.
for key, item: in BankInfos.iteritems():
print key, item
print BankInfos
print BankInfos.keys()
print BankInfos.values()

if BankInfos.has_key('FDR'):
print 'Has FDR key'

Whereas in Pascal you'd be doing the case all over again. Assuming you want to use the banks elsewhere, it would be really simple to see how this is definitely an advantage. You can use and store the bank data dynamically, access it in several ways, and you can reuse it in (other) cases.



Or perhaps this…


#!/usr/bin/env python

a = ("watwatinthebutt",lol)

if type(a) == str:
print 'a is a string'
elif a in range(0,100):
print 'a is in range 0-100'
elif type(a) == list:
print 'a is a list'
elif a in ['This is a string', 42]:
print 'a is in the previously seen list'
else:
print 'a is ', type(a), 'with value ', repr(a)

Sorry, couldn't create a pascal example. Cases are limited in so many ways it not funny any more. What about a case where a is a number somewhere in the range of 0, 100 (like previously used), and b is another number, ranging from 0, 1000? Can you create a readable case in pascal that handles all/both, flexibly?

Thanks. There's a reason Python belongs to the scripting languages whereas Pascal is statically typed, and usually not fit for scripting purposes. (Yes, Java too.)

"I think it's pretty obvious, but to confuse everyone I'll say it's better to use pascal now instead of more readable in python… which was the focus in the first place =/"


The fact of the matter is, you are so focused on how much better and flexible one is over the other it's blinded you to the fact the structure is more complex and complicated to read.

If you honestly believe python is the one of those that is easier to interpret for the downto earth person, then there is nothing more me, or anyone, can say to you to convince you otherwise.

Wizzup?

2010-04-12 10:45:20

From: IceFire908
The fact of the matter is, you are so focused on how much better and flexible one is over the other it's blinded you to the fact the structure is more complex and complicated to read.


Let's swap this. You're one of the few arguing that Pascal is more readable than Python. Everyone has given you countless of arguments on how Python is in fact more readable. You have tried countless of times to prove your point, constantly swapping examples as I struck them down every time, with good arguments and code to support my point. Python is in fact, not complex at all. It's just that you can't be fucked to learn it, as you've proven yourself countless of times in this thread. Now who's blind?

From: IceFire908

If you honestly believe python is the one of those that is easier to interpret for the downto earth person, then there is nothing more me, or anyone, can say to you to convince you otherwise.


I'm actually quite sick of you assuming I'm some sort of religious zealot of certain languages or computer subjects. If I speak out my preference on a certain subject, then it is based on rational facts.

Wanted

2010-04-12 10:47:57

Then move this thread into members or poll it, let the community of SRL decide and not our personal opinnions.

Wizzup?

2010-04-12 10:50:43

From: IceFire908
Then move this thread into members or poll it, let the community of SRL decide and not our personal opinnions.


That was the plan anyway, as I have also stated previously, but there's no point in making a thread in SRL Members already. If I wanted to make a thread before there is a good Py-MML in SRL Members, then I would have done so.

Dan Cardin

2010-04-12 14:17:05

Like i said above, i think that just the fact that its you suggesting it will bias people towards voting for you.

Wanted

2010-04-12 14:30:15

From: Dan Cardin
Like i said above, i think that just the fact that its you suggesting it will bias people towards voting for you.


You'd be suprised how many people are against this, it's mainly the small group of seniors here. Only one way to find out.

Wizzup?

2010-04-12 14:30:39

From: Dan Cardin
Like i said above, i think that just the fact that its you suggesting it will bias people towards voting for you.


I have my doubts. Most people in here are rational thinkers, and I'm sure most of them investigated at least a little bit into what Python is. The fact that people agree with me could perhaps also just mean that think believe it is a good idea…?

Nava2

2010-04-12 15:20:06

From: IceFire908
You'd be suprised how many people are against this, it's mainly the small group of seniors here. Only one way to find out.


Like?

Wanted

2010-04-12 16:20:50

From: Nava2
Like?


http://villavu.com/forum/showpost.php?p=701587&postcount=219

Town

2010-04-12 16:27:28

From: IceFire908
http://villavu.com/forum/showpost.php?p=701587&postcount=219


That will be a disaster unless its carried out correctly. Lock discussion, or have replies be moderator-approved so that only legitimate questions are answered.

I really hope you aren't actually considering just making that thread for everyone to "discuss".

XcanadamanX

2010-04-12 16:27:40

Im going to give my $0.02, even though i want to stay as far away from this thread as possible because everyone is just countering eachother. I agree that we should have an option of using another language other than pascal to be able to script with. And when i was a noob, it didnt matter what language it was, it was unreadable to me. It took time to adjust, just like if we do change, it will take time to adjust to the new language.

anyway think what you want. i think every other ssrl posted so i felt the need to.

Wanted

2010-04-12 16:29:24

From: Town
That will be a disaster unless its carried out correctly. Lock discussion, or have replies be moderator-approved so that only legitimate questions are answered.

I really hope you aren't actually considering just making that thread for everyone to "discuss".


Are you suggesting that we shove python down the community's throat without even asking for their opinion? I don't see any other way of justifying such drastic changes.

Nava2

2010-04-12 16:35:27

From: IceFire908
http://villavu.com/forum/showpost.php?p=701587&postcount=219


You stated that like you had proof. You have none, you argument thus becomes invalid.


Wanted

2010-04-12 16:39:13

From: Nava2
You stated that like you had proof. You have none, you argument thus becomes invalid.



Wow, way to be a complete hypocrite on so many levels.

I am asking that this be allowed to in some form be discussed somewhere other than here, and you respond with this.

Wizzup?

2010-04-12 16:40:51

From: IceFire908
Wow, way to be a complete hypocrite on so many levels.

I am asking that this be allowed to in some form be discussed somewhere other than here, and you respond with this.


No, you stated it like you knew a lot of people who were against this, and then provided an argument that merely suggested people might be against it.

Ejjman

2010-04-12 16:42:03

From: Nava2
You stated that like you had proof. You have none, you argument thus becomes invalid.



That didn't make sense.He said move it to SRL for discussion, to get more opinions?

Either way, this process will take forever. My only worry (rushing into things) obviously will not be a problem.

EDIT: After seeing Wizzup's post, I see that Nava quoted the wrong response.

Wanted

2010-04-12 16:42:35

What are you afraid of the public's opinion then?

Town

2010-04-12 16:46:30

From: IceFire908
Are you suggesting that we shove python down the community's throat without even asking for their opinion? I don't see any other way of justifying such drastic changes.


I don't see how I said that at all. I'll add a sentence.

That will be a disaster unless its carried out correctly. Make a thread in the members or general forum. Lock discussion, or have replies be moderator-approved so that only legitimate questions or opinions are answered or responded to.

Do you suggest that we repeat the method of discussion chosen in this thread, with the SRL members or registered users rather than the senior members? I don't.

senrath

2010-04-12 16:48:16

From: IceFire908
What are you afraid of the public's opinion then?


I don't think anyone here is afraid of public opinion on this subject.

Wanted

2010-04-12 16:53:39

From: Town
I don't see how I said that at all. I'll add a sentence.

That will be a disaster unless its carried out correctly. Make a thread in the members or general forum. Lock discussion, or have replies be moderator-approved so that only legitimate questions or opinions are answered or responded to.

Do you suggest that we repeat the method of discussion chosen in this thread, with the SRL members or registered users rather than the senior members? I don't.


The way it was originally posted, made it sound different.. but I guess it's hard to interpret everything over a computer.

I don't think anyone filtering the posts is a good idea though tbh. If someone posts way out of place, it could be dealt with normally.

From: senrath
I don't think anyone here is afraid of public opinion on this subject.


Maybe afraid isn't the correct word.

Either way, this thread has been in seniors for far to long. In my opinion atleast.

mastaraymond

2010-04-12 17:00:45

From: IceFire908
The way it was originally posted, made it sound different.. but I guess it's hard to interpret everything over a computer.

I don't think anyone filtering the posts is a good idea though tbh. If someone posts way out of place, it could be dealt with normally.



Maybe afraid isn't the correct word.

Either way, this thread has been in seniors for far to long. In my opinion atleast.

Hey look what I found in your sig "I will update RCrB soon." Might as well update that instead of wasting your and our time here in this thread.

Wizzup?

2010-04-12 17:01:58

From: IceFire908
Either way, this thread has been in seniors for far to long. In my opinion atleast.


From: Wizzup?
That was the plan anyway, as I have also stated previously, but there's no point in making a thread in SRL Members already. If I wanted to make a thread before there is a good Py-MML in SRL Members, then I would have done so.


This…?

Wanted

2010-04-12 17:05:00

From: mastaraymond
Hey look what I found in your sig "I will update RCrB soon." Might as well update that instead of wasting your and our time here in this thread.


Oh boy, the beauty of having a laptop next to me computer… it lets me do other things while reading this thread.

Not responding to my other posts, either.

From: Wizzup?
This…?


K. I'll be waiting for that thread then.

TRiLeZ

2010-04-12 17:46:41

From: Wizzup?
There's no need to act like this. I started with a script several times, but pascal annoyed me so much I often quit shortly after. Perhaps if you read the thread you'd know that this is only an idea I tossed up rather than some *new* direction that we *must* go and follow, which quite some of you seem to assume. I'm only defending the possibility of the idea working out well.


I'm sorry that you are not able to script with pascal, but most of the users here are used to making scripts in pascal and are getting good with it. If we were to switch to Python, some people would have an easier time scripting (ie: you) but most of the other scripters in the community will have a hard time because they will have a learn a whole new programming language / syntax.

A lot of us are busy people who don't really have to time to learn Python. If we switch, it will take a while before some good scripts are made. So, in the time of everyone learning Python, there would only be a few good scripts. What will attract new members to these forums? What attracted me to these forums was running Naracle's fast fighter which inspired me to write a cow killer script which brought me into this community. If a new person comes to SRL-Forums, they'll find out that there are only few working scripts and go off to another botting site. Just telling you…

Also, if switching SRL to Python was just an idea that you threw up, why have you already started working on it when everyone is still debating? Just to let you know, this thread is my entertainment. I read the whole thing (up to this post that I'm replying to).

Anyways, why did you ignore me talking about having a poll? Seriously, this thread is going nowhere, so we need to have a poll. Everyone should be able to vote on what happens.

Wizzup?

2010-04-12 18:01:03

From: TRiLeZ
I'm sorry that you are not able to script with pascal, but most of the users here are used to making scripts in pascal and are getting good with it. If we were to switch to Python, some people would have an easier time scripting (ie: you) but most of the other scripters in the community will have a hard time because they will have a learn a whole new programming language / syntax.


I really hope you mean that it's simply my problem that PascalScript is much more limited than Python, and not that I actually can't work with it. I've written countless of scripts, and some of them got over 5 years of runtime in SRL Stats.

This is not about my preferences, but about the future of SRL. I believe that changing from PascalScript to a language more suited for general purpose scripting (like we are doing) will be a significant advantage to SRL as a community and include.

I also don't see your problem as there was already stated that Pascal would still be supported.

From: TRiLeZ
A lot of us are busy people who don't really have to time to learn Python. If we switch, it will take a while before some good scripts are made. So, in the time of everyone learning Python, there would only be a few good scripts. What will attract new members to these forums? What attracted me to these forums was running Naracle's fast fighter which inspired me to write a cow killer script which brought me into this community. If a new person comes to SRL-Forums, they'll find out that there are only few working scripts and go off to another botting site. Just telling you…


Us busy people…? Should I see this as another insult?
Anyway, I don't think there currently are a lot of SRL 4 scripts either. (Ones that actually kept up to date) So that shouldn't be a big issue. And SRL 5 in Pascal will ALSO break all existing scripts, so that issue will be there, regardless of the choice of language. Any change will bring the issue up.

From: TRiLeZ

Also, if switching SRL to Python was just an idea that you threw up, why have you already started working on it when everyone is still debating? Just to let you know, this thread is my entertainment. I read the whole thing (up to this post that I'm replying to).


I'm very glad it is entertaining to you.
There is no point in arguing over something that doesn't exist now is there? I'm going to write the Py-MML wrappers anyway since I want to have them for Simba, even if SRL doesn't want to use them. Your argument is invalid.

From: TRiLeZ
Anyways, why did you ignore me talking about having a poll? Seriously, this thread is going nowhere, so we need to have a poll. Everyone should be able to vote on what happens.


I never ignored you about the poll??? I responded to a similar question by someone else in this thread.
There's just no point to poll it now and here, if we are going to poll it later in SRL Members or lower.

TRiLeZ

2010-04-12 18:11:01

From: Wizzup?
I really hope you mean that it's simply my problem that PascalScript is much more limited than Python.


How much better does PascalScript have to be in order for you to be able to work with it? Does it really need all of the features of Python? After all, it's just a RuneScape script, it's main purpose is to auto for you.

By the way, I was not trying to insult anyone in my previous posts. I am one of those busy people because of school, my job, and my current projects.

Wizzup?

2010-04-12 18:18:53

From: TRiLeZ
How much better does PascalScript have to be in order for you to be able to work with it? Does it really need all of the features of Python? After all, it's just a RuneScape script, it's main purpose is to auto for you.

By the way, I was not trying to insult anyone in my previous posts. I am one of those busy people because of school, my job, and my current projects.


Well, for a start, it should work on Linux and Mac. But that's just a feature.

The main point is that Pascal is statically typed. IMO the main excuse for a statically typed language is that it is going to be turned into machine code, and needs to perform fast. Thus all type checking is done at compile time. Using a statically typed language for scripting is simply a mistake.

It's not very easy to make a list, as I would probably end up listing a lot of Python's features which are not even possible in a statically typed language. My point is that if you are using a language only for binding code together, and not for performance, it makes no sense to pascal. Sure, it can do the job, but it's much more painful than most scripting languages. I guess in this case I'm not just referring to Python, but also to Ruby, and other scripting languages. (Which one of those is better is an entirely different story)

Sure, it's just a Runescape script, but that doesn't mean we can't improve on it. :)

Wanted

2010-04-12 18:26:47

We're still going to have the same problems, a script working well is going to depend more on what someone puts into it and how well they test tweak it, as well as how well they make their functions and use of failsafes.

Python isn't going to solve any of these problems.

Wizzup?

2010-04-12 18:34:48

From: IceFire908
We're still going to have the same problems, a script working well is going to depend more on what someone puts into it and how well they test tweak it, as well as how well they make their functions and use of failsafes.

Python isn't going to solve any of these problems.


No, Python (or any scripting language) cannot make you smarter.
Nor will it solve problems if your mathematics or logic are simply wrong…

But it will solve a lot of the problems/annoyances experienced scripters still experience every day.
It is also said to improve productivity at least by 5 times compared to Java. And some people think developing in Java is fast… ;)

Wanted

2010-04-12 18:42:18

From: Wizzup?
No, Python (or any scripting language) cannot make you smarter. (Stupid comment again, man…)
Nor will it solve problems if your mathematics or logic are simply wrong…


Not really a stupid comment, if you think about it. Any good that comes out of it will be completely outweighed by how well the user makes their script.

From: Wizzup?
But it will solve a lot of the problems/annoyances experienced scripters still experience every day.
It is also said to improve productivity at least by 5 times compared to Java. And some people think developing in Java is fast… ;)


The only annoyances I seem to have scripting everyday are things that have absolutely nothing to do with the ``limitiations'' of pascal. Yea maybe if you're making something that isn't a runescape script.

Wizzup?

2010-04-12 18:45:17

From: IceFire908
The only annoyances I seem to have scripting everyday are things that have absolutely nothing to do with the ``limitiations'' of pascal. Yea maybe if you're making something that isn't a runescape script.


OK. But it isn't just about your annoyances. It's about the stuff I mentioned in the last 10 pages. Just because you don't know how much better programming can really be, doesn't mean you should be so close minded about it.

Sir R. M8gic1an

2010-04-12 19:57:18

I've pretty much stayed out of this thread so far…

Python looks like crap. Then again, I can't really read it, so that might be why.

As to Python > Pascal script, I can easily believe that, but here's my question:

How easy is it to learn python for someone who has never scripted/programmed in their lives?

Do keep in mind that most people who come here are young teenagers who have never seen a line of code before.

We want something easy for them to start with and be on their way.


I don't disagree with supporting python more openly (how about startingbyadding a python forum..?)

But before anything… We have a lot of knowledge, tutorials, experience and scripts in PS. With python……….. some of us have knowledge and experience. The whole 'learning base' would have to be built before we even consider switching to python, otherwise any new people coming in here would have to find their learning resources elsewhere. Now don't go and send me a link to some python manual. We need the tutorials on here.

The only real disadvantage I see from the switch is the loss of knowledge and knowledge base. I'd be against the move until there are enough resources in SRL for the community to actually learn it. And again - these are people who have never seen a line of code in their life. PS is pretty much English and therefore extremely easy to learn.

~RM

Runescapian321

2010-04-12 20:51:12

I read the first ~10 pages, but not the last few, so forgive me if I restate some points…

  • The main reason I see for using Python has to do with "readability". But really, why does it matter if it's slightly more readable or simple than Pascal? What does Python bring to the RS Cheating scene that is new, vastly applicable, and un-doable in Pascal? I guess what I'm saying is, why Python and not another language like Java (continued below)?
  • As IceFire has said, why not Java? I'm sure you're all sick of the hundreds of threads and posts complaining about the lack of reflection, eventually boiling down to the conclusion "It's not fixed because it's not worth learning Java in depth since this is a Pascal and Color based community". Using Java seems to bring the most useful benefits to me. As for SRL/Simba not being solely for RS, why does that have to change with Java (pardon my script kiddie-ness if I'm missing something here)? As for Java being insanely inferior, I'm not one to argue that, but if that was the case, it seems as if the "Python vs. Java" comparisons around the net that were brought up earlier are pointless, which I doubt is the case. There's probably pro's and con's to both.

I had more thoughts, but I seem to have forgotten them, and I'm pressed for time.

Town

2010-04-12 21:05:28

From: Tad
As IceFire has said, why not Java? I'm sure you're all sick of the hundreds of threads and posts complaining about the lack of reflection, eventually boiling down to the conclusion "It's not fixed because it's not worth learning Java in depth since this is a Pascal and Color based community". Using Java seems to bring the most useful benefits to me. As for SRL/Simba not being solely for RS, why does that have to change with Java (pardon my script kiddie-ness if I'm missing something here)?


Why recreate what's already been done in (around) 3 other communities? That's only my reasoning though. Others have expressed their thoughts on its distance from Pascal syntax and its "inherent inefficiencies".

Your first question, I would say, was covered a little more thoroughly in the last few pages. You may not get the answer you're looking for, though.

Runescapian321

2010-04-12 21:24:42

From: Town
Why recreate what's already been done in (around) 3 other communities? That's only my reasoning though. Others have expressed their thoughts on its distance from Pascal syntax and its "inherent inefficiencies".


Just because it's been done before doesn't mean it can't be done again and/or done better. As for the difference in syntax, I doubt that's a major problem. Personally, although I've never delved in complexities in either Pascal or Java, I found the transition simple when going from making SCAR scripts to RSBot scripts. Maybe the major differences are in the upper works, which I wouldn't, know, but then again, is it really so much more difficult going Pascal -> Java vs -> Python that it wouldn't be worth the benefits (namely reflection)?

I don't doubt that Python is better than Pascal, I just am not convinced that it's worth making that specific switch.

EDIT: I also finished reading the whole thread, but I do not see any major reason why Python would enhance SRL in the RS aspect, other than perhaps make scripters' lives a bit easier in terms of readability and scriptability in the future; a good enough reason in itself to leave Pascal behind, maybe (to me, it seems, as RM said, that Pascal is much more noob friendly, but it's hard to tell I suppose). Either way, at this point, almost any language would probably be an improvement over Pascal in that aspect (maybe not on as great a level, but something like Java would bring other major benefits as well).

Smartzkid

2010-04-12 23:09:11

From: Wizzup?
If we want to bundle the language with Simba/SRL, then we will need an interpreted language.


Why's that? Did you ever play around with CBAS?

Still reading the last two pages, sorry if I'm re-questioning.

Wizzup?

2010-04-13 04:18:52

From: Smartzkid
Why's that? Did you ever play around with CBAS?

Still reading the last two pages, sorry if I'm re-questioning.


Hmm… Unless you want to distribute MinGW or FPC in their entirety with Simba?When machine code crashes, it goes down hard, especially if you allow pointers and such. If you stay interpreted it will be much easier to develop in, IMO.

From: Rasta Magician
I've pretty much stayed out of this thread so far…

Python looks like crap. Then again, I can't really read it, so that might be why.

As to Python > Pascal script, I can easily believe that, but here's my question:

How easy is it to learn python for someone who has never scripted/programmed in their lives?


Has already been answered, IMO.

From: Rasta Magician
Do keep in mind that most people who come here are young teenagers who have never seen a line of code before.

We want something easy for them to start with and be on their way.


I don't disagree with supporting python more openly (how about startingbyadding a python forum..?)


Yes, but the age doesn't matter to Pascal or Python.
Python forum sounds like a good idea!

From: Rasta Magician
But before anything… We have a lot of knowledge, tutorials, experience and scripts in PS. With python……….. some of us have knowledge and experience. The whole 'learning base' would have to be built before we even consider switching to python, otherwise any new people coming in here would have to find their learning resources elsewhere. Now don't go and send me a link to some python manual. We need the tutorials on here.


I'm sure those will follow gradually… :)

Simba?
From: Rasta Magician

The only real disadvantage I see from the switch is the loss of knowledge and knowledge base. I'd be against the move until there are enough resources in SRL for the community to actually learn it. And again - these are people who have never seen a line of code in their life. PS is pretty much English and therefore extremely easy to learn.

~RM


Python is also pretty much english…
Point taken. Tutorials are required, although I do believe the Python docs are better a better tutorial than ones that will be posted here. (Presumably)

Ejjman

2010-04-13 11:05:07

Rasta: I think any language is hard when you don't know anything. We would really have to see what happens through practice with this. Of course Wizzup will say they are similar since he knows both, so we need a test subject (young, never-before-seen-coding lines) to be able to test that.


Wizzup, whats the py-MML wrappers you keep talking about making? I haven't seen you post what it is.

Boreas

2010-04-13 11:07:39

From: Wizzup?
Tutorials are required, although I do believe the Python docs are better a better tutorial than ones that will be posted here. (Presumably)


Yes we can skip the loops/arrays/etc tutorials and just point to the python docs, but there still needs to be equivalents of the creating-scripts-using-pascal-based-SRL tutorials.

Wizzup?

2010-04-13 11:25:28

From: Boreas
Yes we can skip the loops/arrays/etc tutorials and just point to the python docs, but there still needs to be equivalents of the creating-scripts-using-pascal-based-SRL tutorials.


Sure.

Ejjman: Py-MML is the python binding for MML, the library that Simba uses.

Nava2

2010-04-13 12:57:28

Wouldn't Insight have to be rewritten/modified significantly?

Smartzkid

2010-04-13 21:52:11

Wizz, fair enough. Of course, we do have debuggers, etc, but yeah, it isn't worth it.

Is Py-MML available? I'd like to try it out.

Wizzup?

2010-04-14 03:34:34

From: Smartzkid
Wizz, fair enough. Of course, we do have debuggers, etc, but yeah, it isn't worth it.

Is Py-MML available? I'd like to try it out.


Well, whenever I add something I just add it to the repos (see below), currently there's just a mouse class. I'll work on it more in a bit, but currently the focus around Simba is more the first public release + Developer docs.

http://git.villavu.com/?p=simba.git -> tree -> Projects -> MMLLib -> pymml.

Note that the actual py-mml code doesn't really reflect how scripts would look like in Python, as py-mml is mainly under the hood code with some nasty memory sharing between libmml <-> python. Plus, writing an OOP wrapper around non OOP stuff usually doesn't look too nice.

mml.py contains a small example of usages, although it (the mouse class) can be used in various ways. Some are rather funny, and I doubt they will be used a lot. (Read: m[(Mouse.Pos, Mouse.Right)] = ((300,300), True))
But m.getPos() and m.setPos() is perhaps more familiar.

Smartzkid

2010-04-14 11:55:41

Thanks.

IMHO this entire discussion is moot until Py-MML is complete.

Nava2

2010-04-14 12:15:50

From: Smartzkid
Thanks.

IMHO this entire discussion is moot until Py-MML is complete.


I agree, the amount of speculative arguments is attrocious. This needs more formal information and some more data with regards to actual applications. The language debate is obvious, but the application isn't so.

If IceFire has one thing right, it's the application of OOP into RS scripting *may* be an unecessary addition. every other arguement sucks.

I would say a smart thong wud be to, as Smartzkid has suggested, wait until py-MML is to a point where an RS script could be written is a *must*.

Town

2010-04-14 16:36:38

From: Nava2
thong


Regardless of the rest of the content in your post, I agree.

Smartzkid

2010-04-14 16:46:27


Nava2

2010-04-14 18:04:41

iPod fail …

Smartzkid

2010-04-18 16:12:59

http://en.wikibooks.org/wiki/Non-Programmer%27s_Tutorial_for_Python_2.6