• Log in or sign up for an account here: https://www.sythe.org/login

Simple HP Calculator That is very helpful with form

9pyro9mage9

Active Member

$5 USD Donor
Joined
Apr 3, 2007
Sythe Gold
0
Messages
241
i made this in my spare time. Its a calculator that when you type in how much attack or strength exp you will get when you reach your goal it will tell you how much hp exp you will get. Also dont say this is in the wrong section because its for rs and its a scar script. Credits go to [email protected] for the help of creating the form. If you use it plz reply.

///////////////////////
/////Hp Calculator/////
///////////////////////
/////By 9pyro9mage9////
///////////////////////
/////Figures out /////
/////how much hp /////
/////exp you will /////
/////get from str /////
/////or att exp /////
/////that you type/////
/////in above. /////
///////////////////////

var
frmDesign : TForm;
Label1: TLabel;
Edit1, Edit2: TEdit;
Button1: TButton;

procedure CalculateNow(Sender: TObject);
var
exp: Integer;
hp: Extended;
begin
try
exp:= StrToInt(Edit1.Text);
hp:= exp / 3.0;
Edit2.Text:= FloatToStr(hp);
except
end
end;

procedure InitForm;
begin
frmDesign:= CreateForm;
frmDesign.Left:= 250;
frmDesign.Top:= 114;
frmDesign.BorderIcons:= [biSystemMenu, biMinimize];
frmDesign.BorderStyle:= bsSingle;
frmDesign.Caption:= 'HpCalculator';
frmDesign.ClientHeight:= 145;
frmDesign.ClientWidth:= 154;
frmDesign.Color:= clBtnFace;
frmDesign.Font.Color:= clWindowText;
frmDesign.Font.Height:= -11;
frmDesign.Font.Name:= 'MS Sans Serif';
frmDesign.Font.Style:= [];
frmDesign.Visible:= False;
frmDesign.PixelsPerInch:= 96;
Label1:= TLabel.Create(frmDesign);
Label1.Parent:= frmDesign;
Label1.Left:= 53;
Label1.Top:= 15;
Label1.Width:= 47;
Label1.Height:= 13;
Label1.Caption:= 'Type your';
Edit1:= TEdit.Create(frmDesign);
Edit1.Parent:= frmDesign;
Edit1.Left:= 16;
Edit1.Top:= 35;
Edit1.Width:= 121;
Edit1.Height:= 21;
Edit1.TabOrder:= 8;
Edit1.Text:= 'Exp';
Button1:= TButton.Create(frmDesign);
Button1.Parent:= frmDesign;
Button1.OnClick:= @CalculateNow;
Button1.Left:= 38;
Button1.Top:= 64;
Button1.Width:= 75;
Button1.Height:= 25;
Button1.Caption:= 'Calculate';
Button1.TabOrder:= 9;
Edit2:= TEdit.Create(frmDesign);
Edit2.Parent:= frmDesign;
Edit2.Left:= 16;
Edit2.Top:= 99;
Edit2.Width:= 121;
Edit2.Height:= 21;
Edit2.TabOrder:= 10;
Edit2.Text:= 'HpExp';
end;

procedure SafeInitForm;
var
v: TVariantArray;
begin
SetArrayLength(v, 0);
ThreadSafeCall('InitForm', v);
end;

procedure ShowFormModal;
begin
frmDesign.ShowModal;
end;

procedure SafeShowFormModal;
var
v: TVariantArray;
begin
SetArrayLength(v, 0);
ThreadSafeCall('ShowFormModal', v);
end;

begin
SafeInitForm;
SafeShowFormModal;
FreeForm(frmDesign);
end.

//////////////////////////////////////////////////////////////////////////////////////////////////
///////////////Credits to [email protected] for helping me with the form///////////////////////
//////////////////////////////////////////////////////////////////////////////////////////////////

hope you like it :D
 
Cool script pyro. Tried it out, works good and simple to use ;).
 
Nice, tested it and worked:)
 
realy nice it worked perfect :D
 
Nice...you should make one for range (non cannon..duh!)also...
 
it doesnt work can somewonhelp?
 
wow great script!
 
just so everyone knows I'm done making scripts so i won't take any requests :D
 
pretty nice, i tested and its good and easy to use
 
Nice script, looks good checking to see if it works now.
 
Runescape Gamblingrunescape gambling
Back
Top