Dear forum users! In compliance with the new European GDPR regulations, we'd just like to inform you that if you have an account, your email address is stored in our database. We do not share your information with third parties, and your email address and password are encrypted for security reasons.
New to the forum?
Say hello in this topic! Also make sure to read
the rules.
Share questions, scripts and tutorials related to the ScriptAPI in SFD.
-
-
The official Discord channel
Replies: 3
by
Hjarpe » Mon Nov 23, 2020 7:42 pm » in
General
First post
Attention superfighters!
Step right up, come on in, and join the super-official MythoLogic Interactive Discord server!
There are topics for Superfighters Deluxe, map-making, bug reports and feedback, excellent memes, as well as upcoming games like Filcher and Barbarian Odyssey.
Link:
It's like...
Last post
Woah, very nice! So many people have been asking around for this and now it finally exists.
- 3 Replies
- 18306 Views
-
Last post by tilt56
Mon Nov 23, 2020 11:42 pm
-
-
Debugging a script for SFD in Visual Studio
Replies: 3
by
Gurt » Mon Nov 13, 2017 6:44 pm
First post
If you have Visual Studio installed you can debug scripts written in Superfighters Deluxe directly through the IDE with breakpoints.
This is done by pointing to the Visual Studio devenv.exe in you config.ini for SFD with DEVENV as key and full path to the devenv.exe as value. Example:...
Last post
ok...
- 3 Replies
- 4973 Views
-
Last post by Venom
Wed Nov 15, 2017 11:05 am
-
-
ScriptAPI changes
Replies: 25
by
Gurt » Thu Mar 03, 2016 5:51 pm
First post
The ScriptAPI as of version v.1.3.0 of the game is what we consider completed. There're no more planned features.
Last post
Able to send chat messages to everyone or individual users will come in the v.1.1.0 update.
///
/// Shows a chat message to all users.
///
/// Message to show. Max 400 characters.
public abstract void ShowChatMessage(string message);
///
/// Shows a chat message to all users.
///...
- 25 Replies
- 22147 Views
-
Last post by Gurt
Wed Jan 30, 2019 10:38 pm
-
-
Forum rules
by
admin » Sun Feb 28, 2016 2:08 pm » in
General
Posting in any part of the forum will require you to follow these rules.
Breaking any of these rules will get you a warning, which will be recorded, or get your account locked depending on the severity of the post.
1) Do not post any abusive, obscene, vulgar, slanderous, hateful, threatening,...
- 0 Replies
- 30819 Views
-
Last post by admin
Sun Feb 28, 2016 2:08 pm
-
-
Improving your code
Replies: 9
by
ShutDownMan » Mon Mar 06, 2017 3:11 am
First post
Hello people,
I'm here now to show you guys one way to improve your SFD projects...
I've made a mini-program some time ago, in python, just for me. The program was simple, it welded up the text of files inside a folder (and all sub-folders) so I could separate my code into different files. It was...
Last post
I'll dm you the executable..
- 9 Replies
- 9385 Views
-
Last post by Odex64
Wed Nov 18, 2020 11:27 am
-
-
Unofficial Coroutine class for ScriptAPI
Replies: 1
by
JakSparro98 » Fri Aug 25, 2017 3:08 pm
First post
Hi all, I'm back with other goodies for the SFD scriptAPI world.
Back when I was writing my AI script, hoping to complete it before Gurt introduced his own, just to prove to him the power of his same script engine, I decided to write a class to let me and other scripters to write in simple manner...
Last post
I know this is an old topic, but I found that very useful. Thanks JakSparro, as always! :D
- 1 Replies
- 3491 Views
-
Last post by Odex64
Tue May 19, 2020 9:39 am
-
-
About bot logic in SFD
Replies: 2
by
Gurt » Sun Sep 02, 2018 2:39 pm
First post
With a carefully crafted path grid where you promise the bots where they can navigate and how they should navigate you can make the bots operational in your map.
In a series of topics I will try to explain some of the systems in SFD you need to be aware of in order to create your own path grid and...
Last post
I never got around to it due to lack of time and there wasn't enough interest in the topic itself. So I kinda let it be and let users inspect our custom maps instead how we designed the path grid there. If you have anything specific you want to know more about I could try to explain that in a bit...
- 2 Replies
- 4126 Views
-
Last post by Gurt
Sat Apr 25, 2020 11:26 am
-
-
Developing a script for SFD in Visual Studio
Replies: 10
by
Gurt » Tue Feb 14, 2017 8:27 pm
First post
If you want a full IDE with intellisense for larger scripts I suggest you do the following:
1: Download and install Microsoft Visual Studio Community.
2: Create a new C# console project.
3: Add a new reference and browse to the SFD.GameScriptInterface.dll file and select it in the SFD installation...
Last post
Tnx dude 😘
- 10 Replies
- 11699 Views
-
Last post by Islem mahmoud
Tue Nov 07, 2017 4:13 pm
-
-
What Is The Speed of Velocity?
Replies: 2
by
Danger Ross » Tue Sep 05, 2023 1:31 am
First post
The question I'm trying to answer is how many pixels/units will an object travel per second if its velocity is one(1) in some direction. I tried to do some research about Box2D but it's leaving me confused and I suspect that the actual values are specific to the game that uses the engine. The...
Last post
impressive :shock:
- 2 Replies
- 4340 Views
-
Last post by angel365
Mon Jul 01, 2024 3:25 pm
-
-
Converting WeaponItem to WeaponItem object
Replies: 8
by
phantom » Tue Nov 07, 2023 2:12 pm
First post
Edit to save your time: I need IObjectWeaponItem equivalent to WeaponItem I have.
So I am trying to make a mutant script in which I don't want it to equip any weapon.
Well take a look at this you will understand:
Events.PlayerWeaponAddedActionCallback.Start((IPlayer player,...
Last post
There is.
- 8 Replies
- 4605 Views
-
Last post by Odex64
Tue Jan 02, 2024 3:09 pm
-
-
Script problem Co-op
Replies: 1
by
JojofansWhen » Fri Sep 22, 2023 7:48 am
First post
Hello. My friend and i play sfd on occasion and we use scripts on local match but how do we modify each player with scripts for example my friend wants to have jetpack script activated but i want Grappling Hook activated. How do we do that? And is there a way to keep stats in next match when using...
Last post
I have one very simple version of the JetPack script by ClockworkDice , and that works via any player walking like this:
foreach(IPlayer ply in Game.GetPlayers()){
if(ply.IsWalking){
ply.SetLinearVelocity(ply.GetLinearVelocity() + new Vector2(0,3));
}
}
The absolute easiest way would be to...
- 1 Replies
- 2739 Views
-
Last post by Mighty Spirit the 2
Wed Oct 11, 2023 10:35 pm
-
-
PlayerPortraits spawned with scripting show up with correct IProfile in Map Editor, but with a random one outside of it
Replies: 2
by
MCS » Sat Dec 24, 2022 2:07 pm
First post
I have a simple script that creates a PlayerPortrait, and gives it a PlayerProfileInfo (by getting the appropriate IObjectPlayerProfileInfo from the map). This works fine in the editor, but if I start a game with this map, the portraits are randomized.
Things I've tried:
If I manually set the...
Last post
Technically it should work just fine if you're hosting an offline game too. Many things don't work due to synchronization issues I guess; in fact when hosting a server your PC behaves as a server AND client
But yeah, bugs like that were annoying when I used to script.
- 2 Replies
- 2691 Views
-
Last post by Odex64
Sun Dec 25, 2022 9:20 am
-
-
- 0 Replies
- 2677 Views
-
Last post by Mighty Spirit the 2
Sun Dec 11, 2022 3:58 am
-
-
[Guide] Removing the "error" block w. Script
by
Mighty Spirit the 2 » Fri Aug 26, 2022 11:34 pm
How to remove error block via script
This is a guide on how to detect and remove this thing:
Basically this happens if you try to spawn something into the game that doesn't exist or it does not recognize. This virtually only happens if you utilize scripts. I am working on a script that is...
- 0 Replies
- 2614 Views
-
Last post by Mighty Spirit the 2
Fri Aug 26, 2022 11:34 pm
-
-
Possible for Script to read what scripts are active?
by
Mighty Spirit the 2 » Sun Aug 21, 2022 11:34 pm
This is a question, because i know you can read via Script a Maps.Name (so script can activate on that spesific map or disabled).
So say i was someone had a script for an older version of the game (using outdated ScriptAPI). Then he makes a new script with the updated Steam ScriptAPI, kind off a...
- 0 Replies
- 2378 Views
-
Last post by Mighty Spirit the 2
Sun Aug 21, 2022 11:34 pm
-
-
Integration Tests for SFD scripts and maps
by
Juansero29 » Sun Mar 28, 2021 4:37 pm
Since some of you know, I'm actively supporting and developing features for the Hardcore server, which includes a multiple of maps all using the same base script. I have refactored a lot of the code running in this maps but my goal is to have a really reliable code, that can be tested and will...
- 0 Replies
- 3420 Views
-
Last post by Juansero29
Sun Mar 28, 2021 4:37 pm
-
-
Be able to insert the script text into a '*.sfdm' file from command line
Replies: 8
by
Juansero29 » Sun Mar 14, 2021 4:56 pm
First post
I'm starting to get some contributions for the script used in my server on GitHub. I would like to setup a pipeline in which when a change is done in the master branch of my repository, it could inject the text (a String) in the script into an existing .sfdm file stored in a server.
This would be...
Last post
Thanks a lot Gurt, may head was in pain trying to figure out those bytes. I'll give that a try this afternoon!
EDIT: Okay so if this may be interesting for anyone else out there: I could use simply a BinaryWriter with a memory stream and get the expected result in form of a byte array like this:...
- 8 Replies
- 7419 Views
-
Last post by Juansero29
Wed Mar 24, 2021 9:37 am
-
-
Custom Bot Target AI Script (How?)
Replies: 2
by
Proxmin-O » Thu Mar 18, 2021 11:04 am
First post
I can't figure it out how to put SetTargetAI and GetTargetAI script ( Medic Cabinet and Ammo stash for example) in my map, im making a remastered Tf2 Map (and others) that i made last year.
Thing that i want to make it work.
-When Bot ran out of Ammo and or needs some Health, it goes where the...
Last post
seems i overthinking alot heeheheh, thank you again :)
- 2 Replies
- 3227 Views
-
Last post by Proxmin-O
Fri Mar 19, 2021 5:41 am
-
-
Player outfit problem
Replies: 1
by
Astolfo » Thu Feb 04, 2021 4:31 pm
First post
I have a script that changes the player's clothing, but it is not suitable for the female gender.
public void h(TriggerArgs args)
{
if (args.Sender is IPlayer)
{
IPlayer plr = (IPlayer)args.Sender;
IProfile profile = plr.GetProfile();
profile.ChestUnder = new IProfileClothingItem( Shirt ,...
Last post
Female items are often named with the suffix _fem . You can see this in the Data/Items folder within the game's content.
- 1 Replies
- 2812 Views
-
Last post by Gurt
Thu Mar 18, 2021 6:45 pm
-
-
about musictrigger
Replies: 2
by
Astolfo » Wed Feb 24, 2021 9:29 pm
First post
How do I set a track in the trigger settings? ScriptAPI does not say anything about this.
Last post
If I get inspiration again to work on SFD I might just get around that /* TODO: Implement. */ in the MusicTrigger to complete it some day. If you're making a custom map you can always prepare all the music triggers manually in the editor you need and then trigger them through the map script code.
- 2 Replies
- 3145 Views
-
Last post by Gurt
Thu Mar 18, 2021 6:38 pm
-
-
(Script Problem) Working with multiple players at once
Replies: 4
by
Diamond TH » Mon Mar 15, 2021 6:57 am
First post
So, I was making a script that allows any player with a katana kill a player instantly, in a cool way, like in a movie. The problem that I have is that my script doesn't want to work with multiple kills in a short time, because if I hit another player while other haven't died yet, the script...
Last post
It's working perfectly now! Thank you very much!
- 4 Replies
- 3710 Views
-
Last post by Diamond TH
Mon Mar 15, 2021 5:12 pm
-
-
how to set weather to rain?
Replies: 2
by
Astolfo » Tue Feb 23, 2021 12:11 am
First post
i know about SetWeatherType, but idk what i need to write in value..
Last post
I didn't think it was that easy. I was just trying to do it without WeatherType in parenthesis. Thanks!
- 2 Replies
- 2957 Views
-
Last post by Astolfo
Wed Feb 24, 2021 4:00 pm
-
-
Why does PlaySound have a worldPosition argument?
Replies: 3
by
Ol1vver » Fri Jan 22, 2021 3:02 pm
First post
It doesn't affect anything from what I can see as a normal player.
Last post
In case we ever wanted to implement pan for sounds from outside the camera. We never did so that's just a left over. It doesn't really do anything.
- 3 Replies
- 3405 Views
-
Last post by Gurt
Fri Jan 22, 2021 5:09 pm
-
-
how to get a player gender?
Replies: 3
by
Astolfo » Sun Jan 17, 2021 2:10 pm
First post
I need to make a script that determines the gender of the player and then executes the command. For example, if the player's gender is male, then he executes a command, if female, then executes another command.
Last post
Or use the Gender property:
if (ply.GetProfile().Gender == Gender.Female)
{
// Female
} else {
// Male
}
- 3 Replies
- 4423 Views
-
Last post by Gurt
Sun Jan 17, 2021 11:06 pm
-
-
How to set all weapon types to be the same
Replies: 2
by
HelpMeIAmSerious » Fri Sep 18, 2020 8:48 pm
First post
Hello! I'm pretty unexperienced with C#, so I'm not sure how to make a script that lets me set all weapon types to be the same. In short, I want to make it so that people can only hold one weapon at a time and this weapon will be assigned to the same inventory spot. Here's what I have below....
Last post
Thank you very much! Sorry for the late response.
- 2 Replies
- 3488 Views
-
Last post by HelpMeIAmSerious
Fri Oct 16, 2020 8:48 pm
-
-
A script that shows statictis of the players
Replies: 6
by
DaxOttsel » Sun May 17, 2020 12:59 am
First post
One time someone showed me a script that when you press tab it would show like an average between player kills and deaths. It was pretty cool and usefull because I want to organize a tournament. Do you guys know where I could find that script? Thanks.
Last post
Also, having a crack version of the game is super common here in Argentina. Pretty much nobody pays for games here xD But I will pay for the game later because the game is so awesome that I do want to support the developers.
It is true that the entry barrier for many games is away from many, many...
- 6 Replies
- 5532 Views
-
Last post by okarowarrior
Fri Jul 31, 2020 6:41 am
-
-
How to when to use a specific command to activate a trigger automatically
Replies: 1
by
Kevi » Sun Jun 14, 2020 1:56 am
First post
:( I couldn't do that, if a player used a specific command to activate a specific trigger, can you help me?
Last post
public void OnStartup()
{
Events.UserMessageCallback.Start(Commands);
}
public void Commands(UserMessageCallbackArgs cmds)
{
if (cmds.IsCommand && cmds.User.IsModerator)
{
switch (cmds.Command)
{
case EXPLOSION : //NAME OF THE COMMAND
((IObjectTrigger) Game.GetSingleObjectByCustomId( exp...
- 1 Replies
- 2585 Views
-
Last post by Odex64
Sun Jun 14, 2020 12:01 pm
-
-
How to change PlayerModifierInfo using a certain difficulty
Replies: 1
by
dsafxP » Fri May 29, 2020 1:25 am
First post
So, I'm doing a campaign and i'm trying to do a script that changes a PlayerModifierInfo when you use a certain difficulty, is there any guides to do this? there are many and i'm not able to find a guide that explains how to do this. Thanks in advance.
Last post
It's pretty easy changing Bots' modifiers depending on the campaign difficulty. Here's the script:
public void SetModifiers(string id, string modifier)
{
foreach(IObjectPlayerSpawnTrigger bot in Game.GetObjectsByCustomId(id))
bot.SetModifierInfo((IObjectPlayerModifierInfo)...
- 1 Replies
- 2755 Views
-
Last post by Odex64
Fri May 29, 2020 1:15 pm
-
-
Add radius and damage modifier params for IGame.TriggerExplosion()
by
NearHuscarl » Sat Apr 18, 2020 1:58 pm
Right now you can only spawn an explosion with default damage and radius which is pretty op in many situations. Having the ability to customize the explosion would make it more useful. For example, to create melee weapon that explode on the last swing but with smaller explosion or create a big...
- 0 Replies
- 2696 Views
-
Last post by NearHuscarl
Sat Apr 18, 2020 1:58 pm
Forum permissions
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum