SRL Archive - First Scripts

First Script - Powerminer


Method

2007-09-02 20:29:38

Hey all,

I've been reading up on scripting for the past week or two and have finally created my first script - an Al Kharid powerminer. From what I can see from testing, the mining works decently and the dropping works perfect until the last row. I'm not sure how to get around this. I've tried to use DTMs to solve the problem but I've probably done something wrong with those. There are randoms in the script, but I'm not sure how well they will work as I haven't encountered any so far. Any help / tips / advice on fixing the dropping procedure as well as being able to detect and avoid gas would be greatly appreciated. Thanks! :)

Wilio

2007-09-02 23:45:24

Not bad.
Only:

There is:

const
NumLoads = 5; //How many loads to do before switching players.
Ore1 = 2832988; //Set these colors
Ore2 = 1778490; //Set these colors
Ore3 = 2569557; //Set these colors
and then there is:
procedure DeclarePlayers;
begin
orecolor := 0;
orecolor1:= 0;
orecolor2 := 0;
orecolor3 := 0;

Explain.

Method

2007-09-02 23:55:45

From: Wilio
Not bad.
Only:

There is:

const
NumLoads = 5; //How many loads to do before switching players.
Ore1 = 2832988; //Set these colors
Ore2 = 1778490; //Set these colors
Ore3 = 2569557; //Set these colors
and then there is:
procedure DeclarePlayers;
begin
orecolor := 0;
orecolor1:= 0;
orecolor2 := 0;
orecolor3 := 0;

Explain.


I received errors when I included SRL/SRL/Skill/Mining.scar and that solved it. I'm not sure why I need them there, but I guess I do. I just tried it again and I'm having issues switching back from dropping to mining again. Could the problem lie within not being able to finish dropping all 27 ores?

Wilio

2007-09-03 00:06:44

You don't need to include mining.Scar. Since your script doesn't use it.

mop

2007-09-03 00:08:23

Worked fine, Mined clay, Ran away from mugger, solved MOM box

Method

2007-09-03 00:16:44

From: Wilio
You don't need to include mining.Scar. Since your script doesn't use it.


I was planning on adding Gas features, so I had included it in there prematurely I guess.

From: mop
Worked fine, Mined clay, Ran away from mugger, solved MOM box


Awesome! Did the dropping work out all right for you? I'm having issues with Iron.

mop

2007-09-03 00:20:28

I didnt get round to a full invo as it was taking to long with 1 mining, It just randomly started logging me out after mining 1 ore though? Any ideas whats wrong there

Method

2007-09-03 00:23:11

I'm not sure why that would happen, sorry. It might have something to do with the Randoms procedure if you clicked away from the game while the script was running. Other than that, I don't know.

harent

2007-09-03 06:28:40

Mine freezes for awhile after trying to drop then it logs out :(
Mining works fine though

mihkel50

2007-09-03 07:22:48

Mine got stuck =\

Method

2007-09-03 12:11:18

Right, the dropping is the script killer. Does anyone have ideas how I can fix that?

tomd741

2007-09-03 12:25:35

your pass is in the script… ive pmed u and changed it 4 u so no one can hack it lols

Method

2007-09-03 12:31:28

Thanks for that. Apparently someone had already changed it, but I've now changed it again to something different.