Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Forge: check if smelt an ore fails or not
Author Message
Rizz
Master
**

Posts: 396
Likes Given: 21
Likes Received: 14 in 9 posts
Joined: Oct 2012
Reputation: 0



Post: #1
Forge: check if smelt an ore fails or not
How can I make a check to know if I get a success when I try to smelt an ore inot a ingot?
09-08-2015 02:28 AM
Find all posts by this user Like Post Quote this message in a reply
escribano
Journeyman
*

Posts: 170
Likes Given: 16
Likes Received: 32 in 23 posts
Joined: Nov 2012
Reputation: 2

Dragon Shard

Post: #2
RE: Forge: check if smelt an ore fails or not
Rizz, i really don't know if sphere by default do this...
I've re-script the entire craft system (packets, skillmenus, improvements, etc..) to adapt it to my shard, in my script i can handle that by default.


What im sure you can do is re-script the "smelting system", just override the typedef t_ore and create your custom smelting system on the @DClick trigger Smile

1) Inside the trigger @DClick, look for a t_forge closer to the player
2) See if ores is inside the backpack (if you want to block players smelting ore from ground)
3) Decide if you want to smell ore-by-ore or the entire amount
4) Face the player to the forge and trigger the animation and sound of smelting
5) You can do some aditional effects on the forge if you want
6) Make the if/else that will handle if the player have smelted right or failed.
7) Trigger an function that will "consume" the ores and give back the player the amount of ingots (it the player smelts right)
8) The system also need to give to the player skill sometimes, you can use the skillgain function to do that
9) Show the desired sysmessages or notices (some people like notices, i dunno why)

Seems hard.. but it's not Smile

UltimaPHP - OpenSource Ultima Online Server v0.1-pre-alpha under development, we need help!
(This post was last modified: 09-08-2015 05:21 AM by escribano.)
09-08-2015 05:15 AM
Find all posts by this user Like Post Quote this message in a reply
Rizz
Master
**

Posts: 396
Likes Given: 21
Likes Received: 14 in 9 posts
Joined: Oct 2012
Reputation: 0



Post: #3
RE: Forge: check if smelt an ore fails or not
Ahahahah I knew it XD
Bcuz for now I didn't re-write all the smelting system, I just put some code to improve it but I noticed a bug when you fail at smelting.
Hope I could use the ACTDIFF somewhere XD
(This post was last modified: 09-08-2015 12:49 PM by Rizz.)
09-08-2015 12:44 PM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)