Loading...
  OR  Zero-K Name:    Password:   

Widget Philosophy

59 posts, 2830 views
Post comment
Filter:    Player:  
Page of 3 (59 records)
sort
13 years ago
In making of my 2 widgets, and planning of a few more, I came across... well, let's just call it an ethical issue.
I know the game engine accepts custom widgets and this is hard to control but I would like to ask if there is some sort of unspoken "do not go here" zone for widget creation.
A point beyond which widgets are not meant to go. So to speak.

Saktoth said:
"Zero-K is all about open development. If you can make a widget that plays the game better than a player, go ahead. If it breaks the game, its the game that needs fixing. "

Ok, so I know what Saktoth thinks then.

But how about this?

I am going through LuaSyncRead and looking at the functions. If some of them work the way I think they do, I can detect incoming projectiles.

With some calculation mirroring the engine's projectile movement code, I can make constructors drop a HLT in the way between them and the projectile then cancel it 1 frame later...
nanowalling widget

Or how about this.

If I ever end up being able to target empty space (currently does not work), I could make turrets/units fire back to the earliest known spot a sniper shot came from if it is within los.
Give it to snipers and...
countersnipers widget


Can you continue to support these kind of widgets?
I don't mind having a go at them, but the nano-walling widget idea seems to push the boundaries of cheesiness to me.
+0 / -0


13 years ago
We already have widgets that literally control your raiders and skirmishers for you almost completely.

Pros use the nanowalling trick fairly often, making a widget so nubs can have access to it (ie. by making it easier to use) is not a terrible dreadful thing imo. Some people have really bad micro they could use the help :P

The gunship orbiting micro can also be done by a player with a lot of micro... (I actually haven't tried it yet, but I'm quite eager to test it out ;) so its not really adding anything "breaking" I would say.
+0 / -0
13 years ago
nanowalling widget:
if you manage to make this work, it could be prevented by making projectiles pass through nanoframes until they are 10% complete.
Though looking how cons have to turn and unfold and all that I am not sure it would even work so good for indiviual projectiles.

targeting empty space:
i think that got forbidden for this very reason. someone had already made a widget that makes the commander dgun fighter planes.
+0 / -0


13 years ago
I was unaware that the projectile stuff was visible to widgets but if you do some kind of nifty stuff with projectiles go ahead.

"if you manage to make this work, it could be prevented by making projectiles pass through nanoframes until they are 10% complete."
Do you know how to do this? I suppose setCollisionVolumeData would work although someone would have to replace every non-custom collision volume for it to work. I suppose if someone made a nanowalling widget we'd have to put in the effort to fix the game, maybe instead you could write the anti-nanowalling gadget to reduce the work all round ;p.

Knorke is right about targetting empty space. Most commands are snapped to the position of the ground.
+0 / -0
13 years ago
Well, currently, position of ground doesn't work.

I just thought of another reason why empty space should not work. You can make HLTs overshoot their max range that way. >.>
+0 / -0
13 years ago
yes, pretty sure it would work using setCollisionVolumeData.
Dont know what you mean by "replace every non-custom collision volume for it to work."? Afaik the default hitspheres set in Upspring can be changed by Lua just like custom defined volumes.
store the units original colvolume, then make it very small/underground and later reset to the original colvolume.
There is also Spring.SetUnitBlocking but I think that only applies to pathing.

but imo it is "not worth fixing" as I see it as an addition to autoskirmish and not as cheat.
I dont really like the idea of autoskirmish, but it is there and if you allow this I feel you can have to allow that too.
+0 / -0
13 years ago
Most Op thing I can imgaine in BA control-fps raketeer t2(rocket bot) then shot rockets through all map. In fps you can do that, but it is not very accurate but stilll after few shots you can hit windmills :)
+0 / -0


13 years ago
It's been seen as a broken game mechanic for a while, noone can be bothered to fix it yet as it isn't a problem.

I don't see how it is related to autoskirmish, this isn't saying a widget is a cheat. Instead it is changing the game so that behaviour isn't even possible.
+0 / -0
13 years ago
Ok, the point is moot on the nano-wall widget.

Spring.GetProjectilesInRectangle()
doesn't work.

when you try to use that, you get this error:
attempt to call field 'GetProjectilesInRectangle' (a nil value))

If you try to localize the widget, it's just nil. (and not a function, trying to call it as a function will generate an upvalue error)

So nope, it was too much to hope for, I can't detect projectiles.
+0 / -0
Skasi
13 years ago
Ah yep nanos are game breakers. They are like, totally broken. Nanos should neither block shots nor uncloak units like they do now. They probably should at higher build levels though. That'd require lots of pondering.
+0 / -0

13 years ago
Ahhh! Knorke found our secret forums.

Like Google Frog said, it has been long on the table to find a way to prevent nano-blocking. If you make a widget it will probably speed development on a fix. So unfortunately it would ultimately be useless.

Although I would probably go use it in BA then. :D
+0 / -0
Skasi
13 years ago
jseah, I'd rather have you fix the "bug" of nanos blocking shots than a widget to abuse it. It really does need widgets automating some things, but this here is something ZK is not even supposed to have.

If you can't be bothered with solving this issue, then just keep going. :D
+0 / -0
13 years ago
Well, like I said, I can't do it. Detecting projectiles doesn't work.

It kinda sucks. Nanowalling widget isn't quite as interesting as a countersniping widget. And I'm sure that one would be more useful.

Any idea where I can find Spring.GetProjectilesInRectangle() in the Spring code? Maybe I can fix it. =P
+0 / -0
13 years ago
https://github.com/spring/spring/blob/master/rts/Lua/LuaSyncedRead.cpp#L2429
did you try if it works in a gadget?
+0 / -0
13 years ago
isint something like countersniping already here?

I mean before my eyes my sniper was shot which was in front of HLT.
+0 / -0
13 years ago
That's just units firing back when they get shot. This happens whether their attacker is cloaked or not.

The countersniper widget would have detected the appearance of a sniper projectile that originated at a point within LOS. Then command any nearby units that have reloaded and ready to fire to shoot that position.

Of course, I'm still busy with improving the AA widget. So this won't happen any time soon or at all.
+0 / -0
13 years ago
The philosophy of widget is sharing. If you made a nano-wall widget and not share it: then it is called cheating! Please share this 'cheating' widget in public places k?
+0 / -0
13 years ago
... and widget that use too much CPU is also cheating... because poor people can't afford it. Don;t make oppressive widget!
+0 / -0
13 years ago
Of course, I intend to give away the widgets I write. Good thigns are meant to be shared after all.


The AA widget can be said to be using too much CPU though. And it works much better when you have a good internet connection. (if you use hold fire, your ping must be <300ms or it functions worse than not using it)

Unfortunately, I can't solve those problems. I have already tried to optimize the code, writing a two-way reference array so I don't have to check the list all the time.
Thing is, detecting if targets are in range is going to be slow no matter what I do. I also never studied computer science formally so my estimates on how well my algorithms work is not accurate.


That doesn't mean I shouldn't write it. I'll write the widget and problems can be dealt with as they arise.

What can be automated, should be.
+0 / -0


13 years ago
Asking Spring where units are repetitively will also be a source of slowness.
+0 / -0
Page of 3 (59 records)