[Src]->Magic Weapons

Codes already submitted by people of the forums.
diuuude
Outpost bitch
Posts: 592
Joined: Wed Dec 28, 2005 11:57 pm

Post by diuuude »

Current version : <span style='color:red'>1.1.0</span>

I used a new special attribute for the magic weapons, as the critical, ancient, poisionning or righteous weapons. The new weapon's class is now "Magic". I added 16 different Spell Effects (from Fire-Strike to Earth-Shock-Wave) and 15 damage levels (from 7% to 105%).

How does it work ?
You just have to attack an ennemy with the magic weapon, the HG will calculate the % of damage added to the regular weapon's damages and show the spell effect. It works with one handed and two handed weapons. <span style='color:red'>Magic weapon will decrease your MPs each time you attack. If your HPs are too low, the weapon will use regular attack, without the magic damage added and spell effect.</span>

How can i calculate the item attribute for these magic weapons ?
Use the tool provided with the code... it's an ugly console application but i didn't have time to code anything better for now, and atleast it works !

How do i get Magic Weapons ?
<span style='color:red'>Drops updated ! Simply kill monsters and they'll drop magic weapons !!</span> You can also summon magic weapons with a GM char.


Some ScreenShots :
- <a href='http://upload.technohell.net/uploads/589ffab22a.jpg' target='_blank'>http://upload.technohell.net/uploads/589ffab22a.jpg</a>
- <a href='http://upload.technohell.net/uploads/8468714644.jpg' target='_blank'>http://upload.technohell.net/uploads/8468714644.jpg</a>
- <a href='http://upload.technohell.net/uploads/c153f7f6ab.jpg' target='_blank'>http://upload.technohell.net/uploads/c153f7f6ab.jpg</a>


Links to Download the Files :
- <a href='http://upload.technohell.net/uploads/e45edb466d.zip' target='_blank'>All in one Package, including : Server and Client Side HTML Installation Guide, Screenshots and Magic Weapons Attributes Calculator.</a>
<a href='http://www.technohell.net' target='_blank'><b><span style='color:red'>>>> Helbreath Ressources Website Here <<<</span></b></a><br>C++ Sources, Tools, Server Files, Help on Forum, C++ Snippets, Toplist... Updated often, come visit us !
Treax2
Loyal fan
Posts: 281
Joined: Fri Mar 04, 2005 5:05 pm
Location: Estonia
Contact:

Post by Treax2 »

Nice ... So The Helbreath is finaly changing ... Thank Juu ... Now i can watch there the client and hg contact and develope some New Things ...
joeri
Member
Posts: 126
Joined: Sat Mar 04, 2006 1:19 am

Post by joeri »

thank you diuuude :P
visit a cool site <a href='http://technohell.net' target='_blank'>here</a><br><br><img src='http://i5.photobucket.com/albums/y184/J ... hnoFan.jpg' border='0' alt='user posted image' /><br><img src='http://i5.photobucket.com/albums/y184/Joeri696/240.jpg' border='0' alt='user posted image' /><br><img src='http://i5.photobucket.com/albums/y184/Joeri696/255.jpg' border='0' alt='user posted image' /><br><img src='http://i5.photobucket.com/albums/y184/Joeri696/326.jpg' border='0' alt='user posted image' /><br><br>Diuuude fan :D<br>Go Diuuude Go :D
juggalo2
Spamtastic
Posts: 1144
Joined: Sun Jul 17, 2005 5:28 pm

Post by juggalo2 »

diude good job again keep it up ::P . im finaly gonan go and get my sources from my budys coimp since i put them on befor i reformat my hardrive :P
<img src='http://lifeplaysu420.com/unknow/nightsign.png' border='0' alt='user posted image' /><br>~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~<br>Wanna make money for surfing the net sing up at <br><a href='http://www.cashfiesta.com/php/join.php? ... yprivitera' target='_blank'>cash fiesta</a><br>its all free hey why ntot make money while fucking around on the computer<br><br><br>~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
locobans
Outpost Junkie
Posts: 2264
Joined: Tue Jul 13, 2004 3:51 am
Location: Behind You
Contact:

Post by locobans »

Possible suggestions to implement to the code.

1. Add some requirements to it, mostly thought of INT requirement. If weapon dropped has magic attribute automatically servers add xx int requirement.

2. Add some mana costs per hit. If weapon dropped has magic attribute automatically servers takes xx mana points per hit depending on the magic attribute percent.

Like if percent is 7% then each hit will take off 2 mana points. If percent is 14% each hit will take off 4 mana points and so on.

These modifications in my opinion will make these new attribute not that powerful.

But again is just my opinion, maybe diuuude will find it cool to add and would add it, or any other person...and maybe I'll add it myself and come back here when have it working.

Anyways thanks for the code.
QUOTE (ADDKiD @ Dec 1 2006, 4:01 PM) <br>You guys make me laugh alot, half the shit I say, is bullshit...<br><br><img src='http://img485.imageshack.us/img485/492/banssig1ng.gif' border='0' alt='user posted image' /><br><br><b>I see no changes at all, wake up in the morning and ask myself...<br>Is life worth living? Should I blast myself?</b><br><br><b><a href='http://2paclegacy.com' target='_blank'>2PacLegacy.com</a></b>
diuuude
Outpost bitch
Posts: 592
Joined: Wed Dec 28, 2005 11:57 pm

Post by diuuude »

locobans wrote: Possible suggestions to implement to the code.

1. Add some requirements to it, mostly thought of INT requirement. If weapon dropped has magic attribute automatically servers add xx int requirement.

2. Add some mana costs per hit. If weapon dropped has magic attribute automatically servers takes xx mana points per hit depending on the magic attribute percent.

Like if percent is 7% then each hit will take off 2 mana points. If percent is 14% each hit will take off 4 mana points and so on.

These modifications in my opinion will make these new attribute not that powerful.

But again is just my opinion, maybe diuuude will find it cool to add and would add it, or any other person...and maybe I'll add it myself and come back here when have it working.

Anyways thanks for the code.
Currently working on these 2 features...

It'll be working and released soon. :)

Any other idea ?
<a href='http://www.technohell.net' target='_blank'><b><span style='color:red'>>>> Helbreath Ressources Website Here <<<</span></b></a><br>C++ Sources, Tools, Server Files, Help on Forum, C++ Snippets, Toplist... Updated often, come visit us !
joeri
Member
Posts: 126
Joined: Sat Mar 04, 2006 1:19 am

Post by joeri »

diuuude wrote:
locobans wrote: Possible suggestions to implement to the code.

1. Add some requirements to it, mostly thought of INT requirement. If weapon dropped has magic attribute automatically servers add xx int requirement.

2. Add some mana costs per hit. If weapon dropped has magic attribute automatically servers takes xx mana points per hit depending on the magic attribute percent.

Like if percent is 7% then each hit will take off 2 mana points. If percent is 14% each hit will take off 4 mana points and so on.

These modifications in my opinion will make these new attribute not that powerful.

But again is just my opinion, maybe diuuude will find it cool to add and would add it, or any other person...and maybe I'll add it myself and come back here when have it working.

Anyways thanks for the code.
Currently working on these 2 features...

It'll be working and released soon. :)

Any other idea ?
Nice Id's loco

Im looking forward to the release :)
And thx diuuude for putting alot of time in hb development.
visit a cool site <a href='http://technohell.net' target='_blank'>here</a><br><br><img src='http://i5.photobucket.com/albums/y184/J ... hnoFan.jpg' border='0' alt='user posted image' /><br><img src='http://i5.photobucket.com/albums/y184/Joeri696/240.jpg' border='0' alt='user posted image' /><br><img src='http://i5.photobucket.com/albums/y184/Joeri696/255.jpg' border='0' alt='user posted image' /><br><img src='http://i5.photobucket.com/albums/y184/Joeri696/326.jpg' border='0' alt='user posted image' /><br><br>Diuuude fan :D<br>Go Diuuude Go :D
locobans
Outpost Junkie
Posts: 2264
Joined: Tue Jul 13, 2004 3:51 am
Location: Behind You
Contact:

Post by locobans »

Another thing...would be good to add information how damage is actually calculated. As I check I think it goes this way...

Total Damage:
Normal Weapon Damage + % (magic percentage) of weapon damage + attacker's Mag/20

So I do 20 With a Great Sword.
I now get a GreatSword 42% energy strike
Have 80 mag points.

20 + 8.4 + 4
32.4
QUOTE (ADDKiD @ Dec 1 2006, 4:01 PM) <br>You guys make me laugh alot, half the shit I say, is bullshit...<br><br><img src='http://img485.imageshack.us/img485/492/banssig1ng.gif' border='0' alt='user posted image' /><br><br><b>I see no changes at all, wake up in the morning and ask myself...<br>Is life worth living? Should I blast myself?</b><br><br><b><a href='http://2paclegacy.com' target='_blank'>2PacLegacy.com</a></b>
Dax
&lt;3 bd long time
Posts: 785
Joined: Mon Apr 18, 2005 3:19 pm

Post by Dax »

Good job Diuuude. If you manage to complete Loco's ideas then I believe this will answer the problems of the "bmage".
Reppin' 127.0.0.1!!!<br><br><img src='http://img502.imageshack.us/img502/1348/sig4daxbn2.jpg' border='0' alt='user posted image' /><br><br>I contend that we are both atheists. I just believe in one fewer god than you do. <br>When you understand why you dismiss all the other possible gods, you will <br>understand why I dismiss yours.<br>~ <b>Stephen Roberts</b>
diuuude
Outpost bitch
Posts: 592
Joined: Wed Dec 28, 2005 11:57 pm

Post by diuuude »

Updated :

- Added MP cost per attack : MP are decreased each time you attack, Regular attack is used when you don't have enough MP to cast the magic attack. No damage bonus or spell effect.

- Improved Drops : Now the monsters will drop Magic items. You got best weapons when you kill strong monsters !

- Installation Guide HTML : Neat, light and tidy HTML pages for installation. Easier to read than the old txt Files !!
<a href='http://www.technohell.net' target='_blank'><b><span style='color:red'>>>> Helbreath Ressources Website Here <<<</span></b></a><br>C++ Sources, Tools, Server Files, Help on Forum, C++ Snippets, Toplist... Updated often, come visit us !
Drajwer
&lt;3 bd long time
Posts: 841
Joined: Fri Dec 10, 2004 3:24 pm

Post by Drajwer »

Magic item calculator is trojan izzit?

Btw. thanks for idea B)
<img src='http://img440.imageshack.us/img440/2627/15pt.jpg' border='0' alt='user posted image' /><br><br>HBPolska characters:<br><br>Hellios 150+ Aresden Hero Mage<br>TheBill 120 Aresden plrider<br>Kill_Me 100 Full-Hero plrider<br>Rockeater 110+ Aresden Plate Mage<br><br><a href='http://www.helbreath.org' target='_blank'>http://www.helbreath.org</a> come and play (250 ppl online)
diuuude
Outpost bitch
Posts: 592
Joined: Wed Dec 28, 2005 11:57 pm

Post by diuuude »

Drajwer wrote: Magic item calculator is trojan izzit?

Btw. thanks for idea B)
Trojan ?

Here is the complete source, show me where is the "trojan" code ;)

Code: Select all

int main(int argc, char* argv[])
{
	int iAttribute, iType1, iType2, iValue1, iValue2, i;
	char cTxt[50];

	iAttribute = iType1 = iType2 = iValue1 = iValue2 = 0;

	iType1 = 15;
	iType2 = 0;
	iValue1 = 0;
	iValue2 = 0;

	printf ("Available Spells : \n\n");
	printf ("  - Fire-Strike (1)          - Bloody-Shock-Wave (9)\n");
	printf ("  - Lightning (2)            - Mass-Ice-Strike (10)\n");
	printf ("  - Chill-Wind (3)           - Lightning-Strike (11)\n");
	printf ("  - Ice-Strike (4)           - Ice-Whirlwind (12)\n");
	printf ("  - Energy-Strike (5)        - Meteor-Strike (13)\n");
	printf ("  - Mass-Fire-Strike (6)     - Mass-Magic-Missile (14)\n");
	printf ("  - Mass-Chill-Wind (7)      - Blizzard (15)\n");
	printf ("  - Earthworn-Strike (8)     - Earth-Shock-Wave (16)\n\n");

	printf ("Enter the Spell ID: ");
	scanf ("%d",&iValue1);

	printf ("\n----------------------------------------------\nThe damage %% can be :");
	printf ("\n  7, 14, 21, 28, 35, 42, 49, 56, 63, 70, 77, 84, 91, 98, 105");

	printf ("\n\nSelect the Damage %%: ");
	scanf ("%d",&iValue2);

	iType1 = iType1 << 20;
	iType2 = iType2 << 12;
	iValue1 = iValue1 << 16;
	iValue2 = (iValue2 / 7) << 8;

	iAttribute = iAttribute | iType1 | iValue1 | iType2 | iValue2;

	itoa(iAttribute, cTxt, 10);

	printf("\n");
	printf("\n-------------------------------------------------\n");
	printf ("Special Item Number: ");
	printf(cTxt);
	printf("\n-------------------------------------------------\n");

	scanf ("%d",&i);

	return 0;
}
<a href='http://www.technohell.net' target='_blank'><b><span style='color:red'>>>> Helbreath Ressources Website Here <<<</span></b></a><br>C++ Sources, Tools, Server Files, Help on Forum, C++ Snippets, Toplist... Updated often, come visit us !
locobans
Outpost Junkie
Posts: 2264
Joined: Tue Jul 13, 2004 3:51 am
Location: Behind You
Contact:

Post by locobans »

Thx a lot diuude.

Tonight I will add it to my server, test it and feedback you. :)

Bug?

<span style='color:red'>Step 4 : In function NpcDeadItemGenerator</span>

Find :
else if ((iResult >= 9700) && (iResult <= 10000)) {
dwType = 9;
cColor = 8;
}
pItem->m_cItemColor = cColor;
Replace it with :
else if ((iResult >= 9700) && (iResult <= 10000)) {
dwType = 9;
cColor = 8;
}
// Magic Weapons - Drops Improvement
else if ((iResult >= 10001) && (iResult <= 10500)) {
dwType = 15; // Magic
cColor = 10; // Black Color
}
// End of Magic Weapons     
pItem->m_cItemColor = cColor;
Right where the iDice starts we have this...
    if (pItem->m_sItemEffectType == DEF_ITEMEFFECTTYPE_ATTACK) {
    iResult = iDice(1,10000);
It should be set to iDice(1,10500)

C yas :)
QUOTE (ADDKiD @ Dec 1 2006, 4:01 PM) <br>You guys make me laugh alot, half the shit I say, is bullshit...<br><br><img src='http://img485.imageshack.us/img485/492/banssig1ng.gif' border='0' alt='user posted image' /><br><br><b>I see no changes at all, wake up in the morning and ask myself...<br>Is life worth living? Should I blast myself?</b><br><br><b><a href='http://2paclegacy.com' target='_blank'>2PacLegacy.com</a></b>
diuuude
Outpost bitch
Posts: 592
Joined: Wed Dec 28, 2005 11:57 pm

Post by diuuude »

hey loco, when you'll have added it to your server, tell me what you think about the html files, is better than the old txts or not ?
<a href='http://www.technohell.net' target='_blank'><b><span style='color:red'>>>> Helbreath Ressources Website Here <<<</span></b></a><br>C++ Sources, Tools, Server Files, Help on Forum, C++ Snippets, Toplist... Updated often, come visit us !
locobans
Outpost Junkie
Posts: 2264
Joined: Tue Jul 13, 2004 3:51 am
Location: Behind You
Contact:

Post by locobans »

diuuude wrote: hey loco, when you'll have added it to your server, tell me what you think about the html files, is better than the old txts or not ?
Hell yeah lolz looks like the instructions files of scrips for IPB forums and phpBB forums and so other boards :D

*cough* professional look *cough*
QUOTE (ADDKiD @ Dec 1 2006, 4:01 PM) <br>You guys make me laugh alot, half the shit I say, is bullshit...<br><br><img src='http://img485.imageshack.us/img485/492/banssig1ng.gif' border='0' alt='user posted image' /><br><br><b>I see no changes at all, wake up in the morning and ask myself...<br>Is life worth living? Should I blast myself?</b><br><br><b><a href='http://2paclegacy.com' target='_blank'>2PacLegacy.com</a></b>
Post Reply