[Lua Function] Request to change the "Explode" function in Hedgewars Lua API

3 replies [Last post]
UltiMaxKom
UltiMaxKom's picture
User offline. Last seen 4 years 10 weeks ago. Offline
Joined: 2016-06-26
Posts: 381

Well, I have managed to ask this in hyper-silly way, which have no power to attract you lol. That's why I'm here wanted to request it in the proper way. But let's take a look from my previous message

U's Old Request Msg allegedly wrote:

MELP

Wait a minute...
What is this post anyway?
I'm not really sure now, if this has a purpose at all
I mean, I place it in general section of the forum, rite?
Hmmm...
Oh! I remember! (duh...)
Melp!
Actually, I'm here wanted to request a small modification of Hedgewars Lua API (shout into the realm of the devs)
Well, there's a Lua function I've asked to devs in IRC a dizzyllion years ago
I asked a function to instantly erase land in desired point and area (circle shaped)
WITHOUT ANY SFX AND GFX

>1> Because yes, we could erase a patch of land easily by spawning bomb/etc that explode and destroy lands
BUT that method give us uncontrollable (not in the literal sense) result with including GFX and SFX output
I mean, IT IS working to erase land, but also mean to 'we do by choice' adding unwanted GFX and SFX in the process
Not mentioning the active gear damage it could cause...

>2> Or using method #2? By spawning sprite then erase it? Well, that's really no flexible
And me personally wouldn't use it as I think it's quite inefficient and heavy resource-wasting method
IT IS working too, but it may convolute the original purpose, having functions overhead, and may glitch too
Ok, actually the main reason is the phrase "Cut me some slack"

>3> Add explosive gear, then erase the visual gear, while muting sound effect (specific sound type) in the insta?
This would work too, but as I wanted it to be clean and efficient; this one might too convoluted as well
Too many resources to be used for this one, functions overhead, a single sound channel silence, and one more biggest thing:
It WILL damage object in the radius of the explosion, obviously(?)

So yeah, you see the 'thing' I requested
And then poof! Wuzzy do it for me :O (by the name of Hedgewars god: many thanks to him)
After long, mindful speech I launch into dear devs, I apparently successful to request the independent land-erasing function!
Melp, it's worth it, amrite!?

BUT
For the sake of 'why I write too much textwall' here
Actually, I requesting to... um...
Uh, C-Change the function name, please xD
It's "Explode(x, y, radius[, options])" right? (imagining a dev wandering around and reading this post)
Well, that's kinda 'not a good name' imho
As I wanted to add my own library function called 'Explode' too x)
Also, it's too general and misleads to call it "Explode" just because it explodes destroying land without GFX n SFX n without doing gear damage
And as for my opinion, it shouldn't be called "Explode", it's too general(reshout) (feels like it doing gear damage too, sounds like: EXPLODE! KAPOOW!)

Hmmm...
What the best name for it? Hum hum...
I think... hum hum it's best to be named
"Eland" - 'Erase Land', or
"Flush" - Flush Land, or
"Deland" - Delete/Destroy Land, or
"Corrode" - It eats land, ahem, or
"Erasel" - It's simple, another form of 'Erase Land'
or... well, I've run out of suggestion though =/
YOU COULD REPLY DOWN GIVING YOUR SUGGESTION TOO!

Okay, to be honest...
I kinda haven't try Explode(param) function, yet
But Wuzzy already tell me how it goes =)
PS: Haven't tried it yet because its name, it could screw up my future plan, kinda =/


And yeah, I believe it's a little clear already, that I request a rename for the 'Explode' function (well, the title already said this =_=).

I hope devs have a portion of their time for this request, thank you very much in advance ^^

╟───NW──────┼──────N╢

╓──────────────────╖ ╓──────────────────╖
⠀HP: ██████████ 1E9/1E91E9/1E9 ██████████ :MP
╙──────────────────╜ ╙──────────────────╜

Wuzzy
Wuzzy's picture
User offline. Last seen 4 days 14 hours ago. Offline
Joined: 2012-06-20
Posts: 1301

Such a long text for a request to change the name of the Explode function. Big Grin

The Explode function is quite useful indeed, it can make an explosion, remove land, push and damage gears around (as if caught in an explosion) and more. Note that all the particular effects are related to how explosions work in Hedgewars, so I think the name is good enough, but I haven't thought of a better one.

Since this function has already been released in a release (0.9.24), renaming this function now is kind of a big deal. It's probably not going to happen.

And the name “ExplodeOrRemoveLandOrOnlyDamageGearsLikeAnExplosionOrJustDoSoundsOrOther” would have been too long. Wink Smiley

Hi, I am a Hedgewars developer. Smile

UltiMaxKom
UltiMaxKom's picture
User offline. Last seen 4 years 10 weeks ago. Offline
Joined: 2016-06-26
Posts: 381

Wuzzy allegedly wrote:

[...]

I think I've realized that it's way long for such request, ahem xD
Let's forget about that lol

Also yeah, I believe this function Hella Good and useful for us little creators (haven't tried it). But that makes me wonder why devs didn't add it before I request it, I mean such function should be essential even for devs (or is it only me?). Been years and nobody wanted this kind of function? It's already v0.9.24.1 tho! I feel all alone now =|

Isn't 0.9.25 are coming not so soon? I mean there's enough time to derping around in the forum (not me *cough*)! And it's a big deal? Idk that there are already many scripts using this function (in the engine). Though there's not many scriptor I know (I made that word around), and afaik people who still active doing scripting is, um, uh... UltiMaxKom(the ugly guy), KoBeWi(RPG project), Anarchron(upcoming project), Wuzzy(handsome guy), nemo(I'm not sure), sheepluva(more unsure), unCORr(more and more unsure), Vatten(I believe), Tiotimolina(put more belief here), KIRA(mb?), and some other I don't know =/ -> Note that they may haven't used this function (e.g: Me).
ALSO If the name changed, they could simply 'Replace' that name (sounds easy enough for me, I've changed many many function/var name with no big problem generalizing it). So I'm not so sure the reason that's being improbable for the next release =(
PS: As if it absolutely can't be changed like, at all then I'll need to get another proper name for my future 'Explode' function (I've used Implosion though, damn. I must use matching name tho =*). Hmmmmmmmmmm...

'And the name “ExplodeOrRemoveLandOrOnlyDamageGearsLikeAnExplosionOrJustDoSoundsOrOther” would have been too long. /innocentface/'
[size=17]THANKS FOR MAKING A PART OF ME DIE INSIDE XDDD[/size]

(I use all CAPS + Bold + Italic + Font size#17 so people think that I'm 12 years old... (also note this is my real grammar, non-intentional tho))

Ok ok, I'll get my head wrap for this issue xO
I'll get another name for my function x)
if you may please help me find one xD
AND AGAIN, thanks @Wuzzy for adding the function x]
It's been a great honor able to wrote this reply =} (wut?)

╟───NW──────┼──────N╢

╓──────────────────╖ ╓──────────────────╖
⠀HP: ██████████ 1E9/1E91E9/1E9 ██████████ :MP
╙──────────────────╜ ╙──────────────────╜

Wuzzy
Wuzzy's picture
User offline. Last seen 4 days 14 hours ago. Offline
Joined: 2012-06-20
Posts: 1301

Quote:
But that makes me wonder why devs didn't add it before I request it, I mean such function should be essential even for devs (or is it only me?). Been years and nobody wanted this kind of function?

Yeah, you are absolutely right, it's really silly this function has not been added earlier, it's such an obvious feature.

Before Explode was a thing, explosions were still possible, but only with a trick. For instance, the Sniper Rifle Training is many years old, it explodes the land by spawning dynamite. I think this is quite fun.

Quote:
ALSO If the name changed, they could simply 'Replace' that name (sounds easy enough for me, I've changed many many function/var name with no big problem generalizing it). So I'm not so sure the reason that's being improbable for the next release =(
PS: As if it absolutely can't be changed like, at all then I'll need to get another proper name for my future 'Explode' function (I've used Implosion though, damn. I must use matching name tho =*). Hmmmmmmmmmm...

Well, as we both don't even have better names in mind, this point is moot anyway.

Hi, I am a Hedgewars developer. Smile

Copyright © 2004-2023 Hedgewars Project. All rights reserved. [ contact ]