Page 3 of 4

Re: did you know...

Posted: 16 Aug 2013, 11:05
by spaii
BTW, is there a way to display markers in editor ?

i'd test a lot of possibilities with no success...

Re: did you know...

Posted: 16 Aug 2013, 21:41
by steeffeen
what i was hoping to get via my suggestion regarding discarding the throw event is the possibility of altering the throwing of items

lets say a player picked up 3 different throwable items
then it would be great if the script could modify which/when the items get thrown

i guess it's possible by setting the .Throwable property of each item
so being able to Discard a throw event is probably not necessary

it would be weird anyways because what should happen then? should the player then shoot a rocket when the throw event gets discarded? should just nothing happen? it's not very clean

so if the script doesn't want an item to get thrown it should set .Throwable = False after the player picked it up
i couldn't test it yet but i guess it's possible and therefore enough for me :thumbsup:

Re: did you know...

Posted: 16 Aug 2013, 21:54
by phil13hebert
Wow, these are great information :o
Btw, I love your speedball mode Steeffeen, TitiShu, etc. :D

Re: did you know...

Posted: 19 Aug 2013, 18:42
by xbx
steeffeen wrote:
xbx wrote:landmarktag="{{{BlockPoles[0].Id}}}" (or any CSmLandmark)
unfortunately this doesn't work, the marker doesn't appear anywhere
i also tried blockid and landmarkid
ooops, my mistake... I just stumbled upon it reading the code, but I didn't test it myself...
Ready more carefully, landmarktag is actually supposed to be the Tag of the landmark (such as "Goal")

alas, it only displays the marker on one of the landmark with the tag, if there are multiple ones.
so it has to be fixed to at least use the order for instance. (Or the blockId as I expected it to work) to be really usefull....

// Edit: could you please explain what CSmObject::MachineState is used for?
not really. I guess it's some test a coworker did that he forgot to cleanup..
I think it will be used to make objects with multiple states, such as broken/ open door or such.

Re: did you know...

Posted: 19 Aug 2013, 18:45
by steeffeen
thanks for the response
xbx wrote:(Or the blockId as I expected it to work) to be really usefull....
yeah please the id! only tag and order would make it useless!
xbx wrote:not really. I guess it's some test a coworker did that he forgot to cleanup..
I think it will be used to make objects with multiple states, such as broken/ open door or such.
alright, sounds good :)

Re: did you know...

Posted: 20 Aug 2013, 22:01
by steeffeen
xbx wrote:objectid="#124124124" (any CSmObject)
it works pretty well but i have noticed a bug..

lets say:
- there is a marker on the only object ingame -> objectid="#1337" manialinkframeid="x"
- there are two more markers with pos="0 8 15" and pos="15 8 0" manialinkframeid="y/z"

now a player picks up the object and the marker follows the players/object :thumbsup:
BUT in my script it happens that the whole marker <-> frame assignment gets screwed up when the player that has carried the ball right before the end of the round leaves the game

in my use case:
- object.setplayer()
- player with object+marker captures the goal
- round end
- markerlayer.visible = false
- player leaves
- round begin
- object.setposition()
- markerlayer.visible = true
- all markers are screwed!

the messed up markers look always the same:
- objectid marker is completely gone
- the pos marker are visible but fixed on the screen, map pos seems to be screen pos now

the object is working fine, just all the markers are bugged
when the player rejoins the marker are fine again

i was able to fix it by setting object.setunspawned() at the end of the round so it's good for now but the behavior is just weird

it doesn't happen on every map but i have a specfic map on which it's happening all the time (without the work-around)
so i'm able to reproduce it in case you need further information :)

regards

Re: did you know...

Posted: 26 Aug 2013, 00:57
by alividerci
XBX wrote:Or
CODE: SELECT ALL

G_BallObject.Throwable = False;
G_BallObject.SetPositionAndVel(Player.Postion + offset, Player.AimDirection * throwspeed);


using say CSmModeEvent::EType::OnActionEvent,
with Event.ActionSlot == CSmModeEvent::EActionSlots::Activable1
(that is when the player presses '1' on the keyboard.)
what about of buttons on keyboard?

Re: did you know...

Posted: 26 Aug 2013, 21:45
by spaii
xbx wrote:to make the object hittable by bullets..
Tested, nice !! :thumbsup:
http://www.youtube.com/watch?v=1RCq1fGSnbU

Re: did you know...

Posted: 26 Aug 2013, 21:53
by Rots
spaii wrote:
xbx wrote:to make the object hittable by bullets..
Tested, nice !! :thumbsup:
http://www.youtube.com/watch?v=1RCq1fGSnbU
God, I just have too many ideas of what I could do with that! :o Great work !

Re: did you know...

Posted: 26 Aug 2013, 21:56
by spaii
Rots wrote:God, I just have too many ideas of what I could do with that! :o Great work !
lol me too, for now there is no event when an item touch another item, but i can imagine a big snooker :)