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.
Here you can find answered ScriptAPI topics.
-
-
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
- 16368 Views
-
Last post by tilt56
Mon Nov 23, 2020 11:42 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
- 28505 Views
-
Last post by admin
Sun Feb 28, 2016 2:08 pm
-
-
List of effect names?
Replies: 4
by
android7 » Sun Sep 10, 2017 6:53 pm
First post
Is there any list of effect names, the Game.PlayEffect ones?
I tried using F11 to track effects, but that only tells me about ones failed to execute, or don't exist.
Last post
Since they are strings, quotation marks are a must.
- 4 Replies
- 3379 Views
-
Last post by JakSparro98
Mon Sep 11, 2017 2:12 am
-
-
delete corpses & gibs after few seconds
Replies: 10
by
The_JOKER » Thu Aug 17, 2017 11:26 am
First post
since corpses and gibs are making the map buggy,
is it able to delete after few seconds with script?
Last post
If you want to only clear gibs you need to copy the script code I posted previously.
I split the script in two threads because I was no idea how Joker wanted the script to work, the complete script was supposed to respawn two teams, and is this:
const int RespawnSeconds = 15;
const int...
- 10 Replies
- 5949 Views
-
Last post by JakSparro98
Fri Sep 01, 2017 12:27 am
-
-
Disable Friendly Fire
Replies: 1
by
The_JOKER » Fri Aug 18, 2017 2:39 am
First post
On D-Day map, they keep shooting teammates, lots of players dying by same team.
I'm not sure if it is possible with scripts, but It would be great if it is possible
Last post
Since bullet handling isn't available on the current SFD version we cannot know who fired that bullet and so preventing friendly fire.
Another way could be my AI project, it uses raycast for avoiding to shoot enemy behind a wall and might recognize an ally in his trajectory and so stop shooting,...
- 1 Replies
- 1911 Views
-
Last post by JakSparro98
Fri Aug 18, 2017 1:31 pm
-
-
New "Thread"
Replies: 10
by
kirill240 » Tue Jun 27, 2017 10:45 pm
First post
Hey guys.
Very long time I wrote DM. When the player died, I created a timer, so he was resurrected after a certain period of time. It's pretty convenient.
1) And now I have a question, how do I better organize several threads, through timers or use the Thread class?
2) There is one more problem...
Last post
Like in Unity 3d the APIs are not thread-safe, but this doesn't mean you cannot perform actions that doesn't require object references, you can even process a whole path for an entity requiring pathfinding in a separate thread, but all the information needed have to be passed at the moment the...
- 10 Replies
- 5578 Views
-
Last post by JakSparro98
Thu Aug 17, 2017 1:41 pm
-
-
What is the difference between "ID" and "Id"
Replies: 4
by
jamisco » Sat Jun 24, 2017 5:07 am
First post
There are methods that allow you to get single or multiple objects by their ID
IObject Gunner_ID = Game.GetSingleObjectByCustomID( The_Gunner );
//or
IObject Gunner_ID = Game.GetSingleObjectByCustomId( The_Gunner );
IObject Gunner_ID = Game.GetObjectsByCustomID( The_Gunner );
//or
IObject...
Last post
I'm glad this two-month old thread helped you with your issue.
Solved, locked.
- 4 Replies
- 3007 Views
-
Last post by KliPeH
Wed Aug 16, 2017 9:59 pm
-
-
Jittery Movement using SetLinearVelocity
Replies: 4
by
ClockworkDice » Mon Jul 24, 2017 1:11 am
First post
Hi, so I've spent a while creating a hoverboard script today, and it works fine in the map editor. The problem is that when I host an actual game, even if I'm the only person in the server, the movement of the hoverboards is super jittery. I can only expect this effect to become worse if other...
Last post
Yea, having the same problem with many scripts with calling some method very much on shprt time. OnUpdate things update faster in the map editor, even if there's as many frames when hosting.
- 4 Replies
- 3078 Views
-
Last post by Motto73
Wed Aug 16, 2017 12:59 pm
-
-
need a script to respawn
Replies: 4
by
The_JOKER » Mon Aug 14, 2017 8:52 am
First post
I need a script to respawn in 15 second.
* I Only need script that respawn! don't give me death counter or any other gamemodes!*
I'm trying to make objective map that end a game with script. so its not death match.
and I need to move respawn point later so make it able to spawn on player spawn...
Last post
Looks like working great! Thank you for the help!
- 4 Replies
- 3540 Views
-
Last post by The_JOKER
Wed Aug 16, 2017 2:35 am
-
-
Wizards Mod
Replies: 3
by
emporerpineapple » Sat Jun 03, 2017 4:45 am
First post
I tried to used the wizards mod only for it to tell me there was an error and the script was going to be disabled. I was wondering if anyone could help me? Is there an updated version or did i do something wrong?
Last post
Here you go.
Moved thread to the Script API section.
- 3 Replies
- 2861 Views
-
Last post by KliPeH
Thu Aug 10, 2017 8:55 pm
-
-
How to make player teleporter and weapon spawner
Replies: 1
by
RamboCreativity » Tue Aug 08, 2017 3:20 am
First post
How do I make an area trigger that when yo enter you teleport somewhere else.
Also can I make a spawnweapontrigger spawn weapons that are dynamic, it only spawns static weapons and I'm trying to have a knife fall from a vent.
Any help would be great.
Last post
Paste this script into your map :
public void Teleport(TriggerArgs arg){
IPlayer ply = (IPlayer)arg.Sender;
IObject obj = Game.GetSingleObjectByCustomID( obj );
Vector2 pos = obj.GetWorldPosition();
ply.SetWorldPosition(pos);
}
And then create an AreaTriggger with script method Teleport and...
- 1 Replies
- 1851 Views
-
Last post by Hoang Marcel
Tue Aug 08, 2017 4:20 am
-
-
A way to skip parameters in method
Replies: 4
by
jamisco » Tue Jul 18, 2017 10:55 pm
First post
take the method .. Player.AddCommand(new PlayerCommand(CommandType, TargetbjectID, delayTime))
say i want to input just commandtype and the delay time, how would i skip the TargetObjectID?
Last post
The PlayerCommand has several constructor overloads. Use the most appropriate one. Sending in the wrong parameters won't do anything if it can't be applicable.
/*
// Example use:
IPlayer player = Game.CreatePlayer(Vector2.Zero);
player.AddCommand(new...
- 4 Replies
- 3343 Views
-
Last post by Gurt
Thu Aug 03, 2017 4:10 pm
-
-
Airstrike script design.
Replies: 4
by
ClockworkDice » Sun Jul 23, 2017 4:55 pm
First post
Hello, so I'm relatively new to scripting (I tried it once a while ago but I didn't know C# at the time so I didn't get very far) and I spent a while yesterday coming up with a script that allows players to call in an airstrike. In it's current form you press walk to throw out a beacon (crumpled...
Last post
Sure
Unless you dont wont people using in their server while its in dev stage,i say go for it
- 4 Replies
- 2948 Views
-
Last post by _Batman_Shadow_
Tue Jul 25, 2017 10:07 pm
-
-
Math Functions
Replies: 5
by
ClockworkDice » Sun Jul 23, 2017 9:02 pm
First post
I want to use trigonometry functions in my scripts, is there any way to do that? Thanks.
Last post
Nope. Usually when something is resolved we lock it. So... Locked...
- 5 Replies
- 3482 Views
-
Last post by TheOriginalCj
Tue Jul 25, 2017 7:13 am
-
-
Spawning broken spotlights
Replies: 2
by
ClockworkDice » Sat Jul 22, 2017 11:58 pm
First post
Hello. The question is pretty much in the title, how do I spawn those spotlights in the state they are in after being shot? I can only figure out how to spawn normal, unbroken ones.
Currently I'm spawning Spotlight00A , which is not broken.
Last post
Hey, thanks for that
- 2 Replies
- 2198 Views
-
Last post by ClockworkDice
Sun Jul 23, 2017 3:11 am
-
-
How do I detect 1 Player not all of them?
Replies: 2
by
TaiHuiDo » Fri Jul 14, 2017 9:58 pm
First post
I need help with detecting 1 player not like Game.GetPlayers(); I need to understand how UniquieID works. Please help fast.
Last post
LOVE U MAN!
- 2 Replies
- 2083 Views
-
Last post by TaiHuiDo
Mon Jul 17, 2017 9:22 pm
-
-
Problem wihen using void methods inside methods :D
Replies: 1
by
jamisco » Fri Jul 14, 2017 5:29 pm
First post
Why do i get an error when i compile code when i do some thing like this? Normally this should work, atleast it works in visual studio.
public void OnStartup()
{
void Life()
{
Game.ShowPopupMessage( life );
}
Life();
}
I get this error code
picture of error message
Whats causing...
Last post
Local functions are only supported in C#7. You're limited to features in C#4 (or maybe C#5 - I don't remember exactly) in SFD.
- 1 Replies
- 1676 Views
-
Last post by Gurt
Fri Jul 14, 2017 6:49 pm
-
-
How to detect if a player is shooting/firing
Replies: 1
by
jamisco » Mon Jul 10, 2017 9:33 pm
First post
the script API allows for one to detect whether a player IsManualAiming or IsHipFiring , but it doesn't allow for us to detect whether a player is directly firing. For example, a player can be Aiming but not firing and in some/most situations the hipFire property is sort of redundant because...
Last post
The IPlayerStatistics class can record a lot of player stats.
Statistics in the IPlayer class returns an IPlayerStatistics object, so you can use TotalShotsFired from the returned object to read if and how much a player have shot.
- 1 Replies
- 1815 Views
-
Last post by JakSparro98
Tue Jul 11, 2017 3:48 pm
-
-
How to make a command repeat
Replies: 7
by
jamisco » Fri Jun 30, 2017 8:36 pm
First post
so I tried doing something like this
while (player.isDead != true)
{
player.AddCommand(new PlayerCommand(PlayerCommandType.AttackOnce));
}
the game will crash because off infinite loop, how do you guys recommend I go about this?
Last post
I perfectly know this, but I only want to demonstrate the power of the script API, that can even make entirely code-written CPU-controlled players (it's also a challenge to prove to myself how far can I go deeper in the code).
Futhermore I didn't started this project because I think my version...
- 7 Replies
- 4345 Views
-
Last post by JakSparro98
Fri Jul 07, 2017 5:38 pm
-
-
Projectile names?
Replies: 4
by
Scraper » Mon Jun 19, 2017 1:44 pm
First post
I am working on a map that is FULL of scripting, and ofc, it contains a shooting script. Now,the problem starts.
I know the name of most projectiles, but is there a list of projectile names?
I am having trouble finding projectile names for GRENADE LAUNCHER, FLAREGUN, and SAWEDOFFSHOTGUN.
Does...
Last post
Oh my bad. I mistook projectile with throwings, only throwings are IObjects and can be recognized.
- 4 Replies
- 3318 Views
-
Last post by UnluckyNinja
Sun Jul 02, 2017 3:03 pm
-
-
Object references not set to an instance of an object
Replies: 11
by
jamisco » Thu Jun 29, 2017 1:55 am
First post
I decided to create a new post since the other one was getting out of its original subject
I have the following script, , but when I run the game, I get this error, but the script does get compiled with any errors
Script Error
Error in method 'ActivateTheGunner(CreateTriggerArgs)' in map script....
Last post
sent you a PM
- 11 Replies
- 6366 Views
-
Last post by jamisco
Thu Jun 29, 2017 6:47 pm
-
-
Script error cant find method ..."Method Name"
Replies: 8
by
jamisco » Sun Jun 25, 2017 2:41 am
First post
So I have a methed called
public void ActivateTheGunner()
{
//Activating DA Gunner
}
but when I run my game and
I'm using a script trigger object in map editor to trigger the method, it says this error
Script Error
Can't find method 'ActivateTheGunner()' in map script. Expecting:
public...
Last post
Due to the change in problem, I created a new post, which can be found here
- 8 Replies
- 5096 Views
-
Last post by jamisco
Tue Jun 27, 2017 8:28 pm
-
-
What is a good replacement for SetBotType=tutorialA?
Replies: 1
by
Scraper » Sun Jun 18, 2017 10:30 pm
First post
I am working on a map where some CPU's will attack you, and you have to defend(not like a zombie map, but familiar).
Since there is no script that enables me to do this anymore, and it is boring making over 1000 PlayerCommandTriggers, does someone know what is a good replacement for...
Last post
There's no replacement or other bot types in the current versions. You will have to wait for future versions of the game.
- 1 Replies
- 1685 Views
-
Last post by Gurt
Mon Jun 19, 2017 8:56 pm
-
-
Was/can this game be developed using windows form?
Replies: 2
by
jamisco » Sat Jun 17, 2017 1:44 am
First post
I'm just wondering, I know it might sound stupid but I'm just too curious if a game like Super fighters deluxe can be made using windows forms. If not, what in SFD makes it not viable for windows form.
Last post
Yeah. We're only using windows forms for the map editor and through some creative process we render the graphics backbuffer to a picturebox on the form. We're also using other third-party libraries Lidgren.Network, NAudio and a Box2D .NET/XNA port.
- 2 Replies
- 1929 Views
-
Last post by Gurt
Sat Jun 17, 2017 7:31 pm
-
-
script request for disable grab ?
Replies: 4
by
AnimeciDuracell » Wed Jun 07, 2017 11:48 pm
First post
anybody have script for disable grab ??
Last post
I do speak Russian, and I was part of the Octothorp team in the past. Language or nationality are not as large of a barrier as you make them out to be. If you're fit to moderate or own something, it's only fair for you to do just that. Incidentally, I have owner rights over SFDMaps but I don't...
- 4 Replies
- 3300 Views
-
Last post by KliPeH
Fri Jun 09, 2017 8:24 pm
-
-
Script that ends the game after ALL of the players are dead.
Replies: 2
by
Scraper » Fri Jun 02, 2017 11:10 am
First post
Can someone please help me? I am making a map that should be played in 2+ players, but I want the game to end after ALL the players are dead, not after only one player is alive.
What I mean was, is there any script to PREVENT Gameover if there is only one player remaining?
Last post
You can prevent gameover only if you change the map type to custom , then the script will handle the gameover and the showed text.
This could be the script you wanted, I've not considered bots as players in this though:
Events.UpdateCallback m_updateEvent = null;
public void OnStartup() {...
- 2 Replies
- 2262 Views
-
Last post by JakSparro98
Wed Jun 07, 2017 3:58 pm
-
-
Script Request: end the game when team 2(Bot) is eliminated
Replies: 4
by
The_JOKER » Sun Jun 04, 2017 3:22 am
First post
I need a full script that check if team 2(or Bot) is eliminated and end the game, when triggered by script trigger or area trigger
need that script to make wave surviving game
Also, I need script that end the game when all players dead(except bot)
Last post
Thank you, you helped me a lot making my first surviving map!
I will add you at the Credits on gameover ;)
- 4 Replies
- 3007 Views
-
Last post by The_JOKER
Mon Jun 05, 2017 4:09 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